Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- If you get tired of typing public class... and then the main method in vim
- then here is your solution. This also includes a skeleton for class documentation (author and version) that is compliant with Javadoc guidelines.
- autocmd BufNewFile *.java
- \ exe "normal O/**\r*\r* @author: \r* @version: \r* \r*/\r\rpublic class " . expand('%:t:r') . "\r public static void main(String[] args){\r\r }\r}\<Esc>1G"
- Just insert it into your '.vimrc' and that's it! The next time you create a brand new Java file with 'vim *.java' you
- will see a template.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement