Monday, 15 February 2010

java - Key-bindings for public static void main() and System.out.println() in Sublime Text 2 -



java - Key-bindings for public static void main() and System.out.println() in Sublime Text 2 -

i have gone coding java in emacs doing in sublime text 2. know how create key bindings such if type sop i'll system.out.println() , if type psvm i'll public static void main. i'm using sublime text 2 ubuntu.

thanks in advance!

you can utilize snippets.

tools/new snippet...:

<snippet> <content><![cdata[ system.out.println() ]]></content> <tabtrigger>sop</tabtrigger> <scope>source.java</scope> </snippet>

save file .sublime-snippet extension, in packages/user.

this way, in java source files, when type sop, followed tab, you'll need.

you can same psvm.

java sublimetext2

No comments:

Post a Comment