Open neilChenXie opened 7 years ago
ctrl+c
doesn't work
I use "Packages -> Vim Mode -> Settings -> Use Clipboard As Default Register" and just use the standard Vi copy/paste commands to copy in/out of Atom. I would argue that this should be the default setting for Vim Mode.
configured init.coffee
to add a script:
atom.commands.add 'atom-workspace',
'custom:insert-timestamp': ->
offset = 8;
now = new Date(new Date().getTime() + offset * 3600 * 1000);
atom.workspace.getActiveTextEditor().insertText(now.toISOString().replace('T',' ').split('.')[0])
and then added a custom shortcut keymap.cson
for markdown:
'atom-text-editor':
'ctrl-alt-t': 'custom:insert-timestamp
init.coffee
textEditor = atom.workspace.getActiveTextEditor()
# cursorPosition = textEditor.getCursorBufferPosition()
# endColumn = textEditor.indentationForBufferRow(cursorPosition.row)
# if textEditor.getSoftTabs() then endColumn *= textEditor.getTabLength()
# endPosition = cursorPosition.translate([0, endColumn - cursorPosition.column])
# textEditor.selectToBufferPosition(endPosition)
textEditor.moveToBeginningOfLine();
textEditor.insertText(" ");
keymap.cson
'atom-text-editor':
'ctrl-alt-s': 'custom:insert-paragraphStart'
最好的一点,所有功能都能通过
ctrl+shift+p
的搜索获得;不用刻意被hot-key,搜的次数多了,自然就记住了。符合使用习惯。 #搜索引擎是未来