I wrote a simple python template in ~/.vim/template/pythontmp.txt,
and use
$> autocmd bufnewfile *.py :0r ~/.vim/template/pythontmp.txt
to load the template when i create a new python script.
The problem is that i’d like to add creation time to the comment of the document.
How can I do this? Thanks!
You can use strftime function for this:
According to the documentation,
strftimeis not present on some systems. Seeman strftime(if you are on *nix) for details of format.