annotate tests/packageA/packageA.py @ 35:122c56779f2b

add functionality to run post-install python scripts
author Jeff Hammel <jhammel@mozilla.com>
date Mon, 08 Aug 2011 18:08:49 -0700
parents 29b36a390857
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
6
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
1 #!/usr/bin/env python
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
2
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
3 """
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
4 packageA
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
5 """
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
6
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
7 import sys
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
8 from optparse import OptionParser
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
9
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
10 def main(args=sys.argv[1:]):
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
11
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
12 # parse command line arguments
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
13 usage = '%prog [options] ...'
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
14 parser = OptionParser(usage=usage, description=__doc__)
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
15 options, args = parser.parse_args(args)
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
16
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
17 if __name__ == '__main__':
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
18 main()
29b36a390857 add some bogus packages ill need for da test
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
19