ナチョキャブ、それは素晴らしい答えでした-そして私をとても助けてくれました。少し違うバージョンを自分で作成しました
〜/ Library / Application Support / Sublime Text 2 / Packages / User / datetimestamp.py:
import datetime, getpass
import sublime, sublime_plugin
class AddDateTimeStampCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("insert_snippet", { "contents": "%s" % datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S") } )
class AddDateStampCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("insert_snippet", { "contents": "%s" % datetime.datetime.now().strftime("%Y-%m-%d") } )
class AddTimeStampCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("insert_snippet", { "contents": "%s" % datetime.datetime.now().strftime("%H:%M:%S") } )
環境設定>キーバインディング-ユーザー:
{"keys": ["super+alt+ctrl+d"], "command": "add_date_time_stamp" },
{"keys": ["super+alt+d"], "command": "add_date_stamp" },
{"keys": ["super+alt+t"], "command": "add_time_stamp" }
私はあなたの助けなしにはこれを行うことができなかっただろう!私は今グーグルを約1時間精査し、ついにあなたの答えに恵まれました!本当にありがとう!