Skip to content

Instantly share code, notes, and snippets.

@j-faria
Created March 3, 2014 13:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save j-faria/9324663 to your computer and use it in GitHub Desktop.
Save j-faria/9324663 to your computer and use it in GitHub Desktop.
import sys
def fun():
print 'fun'
def test():
print 'test'
if __name__ == "__main__":
if len(sys.argv) > 1 and sys.argv[1] == 'test':
test()
else:
fun()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment