knack

Knack - A Python command line interface framework

MIT License

Downloads
9.9M
Stars
348
Committers
46

Bot releases are hidden (Show)

knack - knack 0.5.4

Published by tjprescott over 5 years ago

This release

  • Allows the loading of text files using @filename syntax.
  • Adds the argument kwarg configured_default to support setting argument defaults via the config file's [defaults] section or an environment variable.
knack - knack v0.5.3

Published by tjprescott over 5 years ago

This release:

  • Removes an incorrect check when adding arguments.
knack - knack v0.5.2

Published by tjprescott over 5 years ago

Updates usages of yaml.load to use yaml.safe_load.

knack - knack v0.5.1

Published by tjprescott almost 6 years ago

Fix issue with some scenarios (no args and --version)

knack - knack v0.5.0

Published by tjprescott almost 6 years ago

  • Adds support for positional arguments with the .positional helper method on ArgumentsContext.
  • Removes the necessity for the type field in help.py. This information can be inferred from the class, so specifying it causes unnecessary crashes.
  • Adds support for examining the result of a command after a call to invoke. The raw object, error (if any) an exit code are accessible.
  • Adds support for accessing the command instance from inside custom commands by putting the special argument cmd in the signature.
  • Fixes an issue with the default config directory. It use to be .cli and is now based on the CLI name.
  • Fixes regression in knack 0.4.5 in behavior when cli_name --verbose/debug is used. Displays the welcome message as intended.
  • Adds ability to specify line width for help text display.
knack - knack v0.4.5

Published by tjprescott almost 6 years ago

Preserves logging verbosity and output format on the namespace for use by validators.

knack - 0.4.4

Published by tjprescott about 6 years ago

Adds ability to set config file name.
Fixes bug with argument deprecations.

knack - 0.4.3

Published by tjprescott about 6 years ago

Fixes issue where values were sometimes ignored when using deprecated options regardless of which option was given.

knack - 0.4.2

Published by yugangw-msft about 6 years ago

Bug fixes:
[output]: disable number parse on table mode PR #88

knack - 0.4.1

Published by tjprescott over 6 years ago

Version 0.4.0 introduced deprecation to Knack. This release fixes a bug related to that.

  • Ensures that the action kwarg is only set if the item is deprecated. Previously it would set it to "None" which would then override a pre-existing action like store_true.

Version 0.4.0 also added the concept of the command group table to the CommandsLoader class. This release corrects an issue related to that:

  • The command group table would only be filled by calls to create CommandGroup classes. This resulted in some gaps in the command group table.
knack - 0.4.0

Published by tjprescott over 6 years ago

  • Add mechanism to deprecate commands, command groups, arguments and argument options.
  • Improve help display support for Unicode.

View commits since last release

knack - Release 0.3.3

Published by yugangw-msft over 6 years ago

  • expose a callback to let client side perform extra logics (#80)
  • output: don't skip false value on auto-tabulating (#83)

View commits since last release

knack - 0.3.2

Published by derekbekoe over 6 years ago

  • ArgumentsContext.ignore() should use hidden options_list (#76)
  • Consolidate exception handling (#66)

View commits since last release

knack - 0.3.1

Published by derekbekoe almost 7 years ago

  • Performance optimization - Delay import of platform and colorama (#47)
  • CLIError: Inherit from Exception directly (#65)
  • Explicitly state which packages to include (so exclude 'tests') (#68)

View commits since last release

knack -

Published by derekbekoe almost 7 years ago

knack -

Published by derekbekoe about 7 years ago

  • Support command level and argument level validators.
  • knack.commands.CLICommandsLoader now accepts a command_cls argument so you can provide your own CLICommand class.
  • logging: make determine_verbose_level private method.
  • Allow overriding of NAMED_ARGUMENTS
  • Only pass valid argparse kwargs to argparse.ArgumentParser.add_argument and ignore the rest
  • logging: make determine_verbose_level private method
  • Remove cli_command, register_cli_argument, register_extra_cli_argument as ways to register commands and arguments.

FULL CHANGELOG

knack -

Published by derekbekoe over 7 years ago

  • Add more types of command and argument loaders.
  • Add tests.

FULL CHANGELOG

knack -

Published by derekbekoe over 7 years ago

Initial release.