vim/snippets/python.snippets @ 5ddfd5a61ea1

Update with various crap from the past few weeks.
author Steve Losh <steve@stevelosh.com>
date Thu, 13 Jun 2013 10:44:08 -0400
parents db4d0e62bcdb
children (none)
snippet #!
	#!/usr/bin/env python
snippet from
	from ${1:sys} import ${2:*}
snippet while
	while ${1:True}:
		${2:pass}
snippet for
	for ${1:x} in ${2:xs}:
		${3:pass}
snippet def
	def ${1:function}(${2}):
		${3:pass}
snippet defs
	def ${1:method}(self${2}):
		${3:pass}
snippet lam
	lambda ${1:args}: ${2:action}
snippet ifmain
	if __name__ == '__main__':
		${1:main()}
snippet _
	__${1:init}__${2}
snippet ***
	*args, **kwargs
snippet af
	assert False, repr(${1})$2
snippet pdbt
	import pdb; pdb.set_trace()
snippet pp
	from pprint import pprint; pprint($1)$2