Skip to content

Instantly share code, notes, and snippets.

@yuugit
Created July 26, 2013 02:36
Show Gist options
  • Save yuugit/6085647 to your computer and use it in GitHub Desktop.
Save yuugit/6085647 to your computer and use it in GitHub Desktop.
a python template for auto-insert
# -*- coding: utf-8 -*-
def main():
(options, args) = parse_options()
def parse_options():
import optparse
parser = optparse.OptionParser()
parser.add_option("--foo", type = "str", default = "FOO", help = "fooooooo!",
dest = "foo")
parser.add_option("--bar", type = "int", default = 83, help = "83",
dest = "bar")
return parser.parse_args()
if __name__ == '__main__':
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment