add following line to ~/.vimrc
autocmd BufNewfile *.py silent! execute '0r! echo "\#\! /usr/bin/env python"'
EDITED: this one is more simpler
autocmd BufNewfile *.py call append(0,'#! /usr/bin/env python')
you can see the help by executing :help :autocmd
in vim,
or see http://learnvimscriptthehardway.stevelosh.com/chapters/12.html
Also append
's help is in :help append()
.