This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pymongo | |
from pymongo import Connection | |
from bson.dbref import DBRef | |
from pymongo.database import Database | |
# connect | |
connection = Connection() | |
db = Database(connection, "things") | |
# clean up |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" auto add file header | |
autocmd BufNewFile *.py 0r /Users/jhenxu/.vim/vim_template/vim_header_for_python | |
autocmd BufNewFile *.py ks|call FileName()|'s | |
autocmd BufNewFile *.py ks|call CreatedTime()|'s | |
autocmd BufNewFile *.sh 0r /Users/jhenxu/.vim/vim_template/vim_header_for_sh | |
autocmd BufNewFile *.sh ks|call FileName()|'s | |
autocmd BufNewFile *.sh ks|call CreatedTime()|'s | |
fun FileName() |