Skip to content
Commits on Jul 22, 2009
  1. Remove rest_ from options

    committed Jul 22, 2009
Commits on Jul 20, 2009
  1. Fixed naming conflict

    committed Jul 20, 2009
Commits on Jul 19, 2009
  1. Fixed test cases to accept extra arguments and to excuse the usage in…

    …formation printed after the error
    committed Jul 19, 2009
  2. Made rest_ optional in the function declaration.

    blurb will react properly if docstring does not exist
    committed Jul 19, 2009
  3. Added rest_ to store remaining arguments as a tuple.

    args if filtered to remove entries already present in required_args and
    those that are options. Everything else is put in options['rest_']
    
    Right now it is required that rest_ be defined in the function.
    committed Jul 19, 2009
  4. Changed formatting of error/usage methods.

    The first line of the docstring is now used as a short description for
    subcommands.
    Changed argument check to > so that extra arguments don't cause
    errors.
    committed Jul 19, 2009
Commits on Jul 15, 2009
  1. Added header and subcommand separator.

    I didn't really like the , separation much.
    Header is printed before the list of commands.
    
    You should set both of these by calls to
    optfunc.header = 'My really cool app'
    committed Jul 15, 2009
Commits on May 29, 2009
  1. Added support for stdout and stderr special arguments and documented …

    …them
    Simon Willison committed May 29, 2009
  2. Documented the new optfunc.main(func) idiom, which uses a tricksy sta…

    …ck introspection to detect if __name__ == '__main__' for you
    Simon Willison committed May 29, 2009
  3. clarified stdin code a bit

    Simon Willison committed May 29, 2009
  4. Added support for special stdin argument

    Simon Willison committed May 29, 2009
  5. optfunc.main() - like optfunc.run(), but it peeks at the stack and us…

    …es it to decide if __name__ == '__main__', saving you from having to type that idiom yourself
    Simon Willison committed May 29, 2009
Commits on May 28, 2009
  1. Added BSD license

    Simon Willison committed May 29, 2009
  2. Merge commit 'rybesh/master'

    Simon Willison committed May 29, 2009
  3. @rybesh
  4. TODO: Subcommands need to interact with --help better

    Simon Willison committed May 28, 2009
  5. Added support for subcommands - just pass a list of functions to optf…

    …unc.run e.g. optfunc.run([one, two, three])
    Simon Willison committed May 28, 2009
  6. @rybesh

    Get custom names working.

    rybesh committed May 28, 2009
  7. @rybesh
  8. @rybesh
  9. @rybesh
  10. Added TODO based on neat idea from @nasrat - pass multiple functions …

    …to the run() command and have the first command line argument select which function gets executed.
    Simon Willison committed May 28, 2009
  11. Added documentation of how arguments are treated, and how option name…

    …s are derived from function parameter names
    Simon Willison committed May 28, 2009
  12. Impoved command line output example in readme

    Simon Willison committed May 28, 2009
  13. Added shebang line to demo scripts

    Simon Willison committed May 28, 2009
  14. Added documentation of @arghelp and @notstrict to the readme

    Simon Willison committed May 28, 2009
  15. TODO: support for *args, but probably not **kwargs

    Simon Willison committed May 28, 2009
  16. Fixed a typo in a comment

    Simon Willison committed May 28, 2009
  17. Removed a TODO (argument help text is done)

    Simon Willison committed May 28, 2009
  18. Added a demo command line script based on http://github.com/simonw/ge…

    …ocoders which demonstrates the new @notstrict and @arghelp decorators
    Simon Willison committed May 28, 2009
  19. Added @arghelp and @notstrict decorators, plus tests

    Simon Willison committed May 28, 2009
  20. TODO: allow function to be a generator

    Simon Willison committed May 28, 2009
  21. Renamed example.py to demo.py

    Simon Willison committed May 28, 2009
Something went wrong with that request. Please try again.