Jason Gerard DeRose
138305b365
Added an example CLI-specific env command
2008-10-28 02:23:13 -06:00
Jason Gerard DeRose
316bd855d5
Added util.configure_logging() function; API.bootstrap() now calls util.configure_logging()
2008-10-28 01:39:02 -06:00
Jason Gerard DeRose
83d6c95e46
API.load_plugins() no longer takes dry_run=False kwarg and instead checks in env.mode == 'unit_test' to decide whether to load the plugins; it also only loads ipa_server.plugins in env.in_server is True
2008-10-27 23:39:43 -06:00
Jason Gerard DeRose
6e456cc749
More CLI cleanup, got all basics working again
2008-10-27 23:30:55 -06:00
Jason Gerard DeRose
9b1e3f5946
More docstrings, functionality, and unit tests for improved CLI class
2008-10-27 19:21:49 -06:00
Jason Gerard DeRose
e6254026fe
Implemented basic CLI.bootstrap(); added corresponding unit tests
2008-10-27 15:19:49 -06:00
Jason Gerard DeRose
17fd9cc431
Started cleanup work on CLI class, added unit tests for CLI.parse_globals()
2008-10-27 14:49:34 -06:00
Jason Gerard DeRose
10026284db
Started cleanup work on CLI class, added unit tests for CLI.parse_globals()
2008-10-27 14:48:02 -06:00
Rob Crittenden
06a82bf4b6
Fix ipa command running in server_context=True
...
Make the LDAP host and port environment variables
More changes so that commands have a shell return value
lite-xmlrpc no longer hardcodes the kerberos credentials cache location
2008-10-23 11:00:50 -04:00
Rob Crittenden
f189b02996
Return a value to the shell that called ipa
2008-10-22 17:52:32 -04:00
Rob Crittenden
bc5edcf893
Gracefully handle keyboard interrupts (^C)
2008-10-21 14:42:13 -04:00
Rob Crittenden
6b998ed479
Make boolean options work like standard OptionParser booleans
2008-10-21 09:32:48 -04:00
Jason Gerard DeRose
ac0a019605
Reworked 'plugins' command to use output_for_cli()
2008-10-20 18:57:03 -06:00
Jason Gerard DeRose
721982870e
Removed generic Command.output_for_cli() method; CLI.run_interactive() now only calls output_for_cli() if it has been implemented
2008-10-17 21:05:03 -06:00
Martin Nagy
3a80297b04
Reworking Environment, moved it to config.py
2008-10-17 23:11:51 +02:00
Jason Gerard DeRose
1480224724
Started roughing out user_add() using api.Backend.ldap; added Command.output_for_cli() to take care of formatting print output
2008-10-14 01:45:30 -06:00
Jason Gerard DeRose
22669f1fc2
CLI.run_interactive() now uses Param.cli_name instead of Param.name for prompts and errors
2008-10-13 22:00:18 -06:00
Jason Gerard DeRose
b6dcd183a6
CLI now maps Param.cli_name to Param.name
2008-10-13 20:31:10 -06:00
Martin Nagy
4a1c4a3fe3
Implement argument parsing for the CLI
2008-10-08 00:07:44 +02:00
Martin Nagy
4a68c719f0
Implement config file reading
2008-10-08 00:07:44 +02:00
Martin Nagy
149429f305
Environment is now subclassed from object, rather then dict. Added tests for Environment and config.py
2008-10-02 17:22:41 -06:00
Martin Nagy
afdc721038
Add support for environment variables, change tests accordingly
2008-09-29 17:45:14 -06:00
Jason Gerard DeRose
eaf15d5a52
327: Improved formatting on show-api cli command
2008-09-24 05:35:40 +00:00
Jason Gerard DeRose
f3ac709922
326: Made output of plugins cli command nicer
2008-09-24 05:03:10 +00:00
Jason Gerard DeRose
3e70c3b56b
325: API.finalize() now creates instance attribtue 'plugins', which is a tuple of PluginInfo objects; renamed show_plugins cli command to namespaces; added new cli command plugins
2008-09-24 04:44:52 +00:00
Jason Gerard DeRose
3bf2da5714
324: Removed 'smart_option_order' from Command.__public__; cli commands help, console, and show_plugins now override Command.run() instead of Command.__call__()
2008-09-24 03:10:35 +00:00
Jason Gerard DeRose
4e8ff5c656
318: Renamed all references to 'public' module to 'frontend'
2008-09-24 00:01:29 +00:00
Jason Gerard DeRose
2d83614006
305: Ported cli.py to changes in public.py
2008-09-21 19:00:41 +00:00
Jason Gerard DeRose
23e251a605
288: CLI now uses Command.group_args() to check for required arguments
2008-09-10 23:33:36 +00:00
Jason Gerard DeRose
687f603562
284: Removed depreciated Command.Option property; removed corresponding unit tests; updated affected code
2008-09-10 15:31:34 +00:00
Jason Gerard DeRose
8062075f84
279: Fixed cli and public.Method re new Command.args attribute
2008-09-10 02:02:26 +00:00
Jason Gerard DeRose
0215bc8009
276: Option.__init__(): doc is now 3rd kwarg instead of 2nd positional arg; updated unit tests and other affected code
2008-09-10 00:21:40 +00:00
Jason Gerard DeRose
21a0bab79e
272: Add a quick positional arg experiment
2008-09-09 01:41:15 +00:00
Jason Gerard DeRose
cb9c442708
270: show-plugins now only shows namespaces with at least one member
2008-09-08 21:44:53 +00:00
Jason Gerard DeRose
03fd184e8e
269: Renamed print_api command to show_plugins
2008-09-08 21:42:48 +00:00
Jason Gerard DeRose
e74713a076
267: Finished builtin CLI api command
2008-09-08 21:37:02 +00:00
Jason Gerard DeRose
641403278e
266: Started work on new cli.print_api Command
2008-09-04 18:35:04 +00:00
Jason Gerard DeRose
22d9b8c078
265: Fixed small formatting error with use of CLI.print_commands()
2008-09-04 09:27:28 +00:00
Jason Gerard DeRose
553b0c596d
264: Cleaned up docstrings on all example plugins
2008-09-04 09:22:18 +00:00
Jason Gerard DeRose
6b9ba734e1
263: CLI.print_commands() now seperates Command subclasses from Application subclasses
2008-09-04 09:04:35 +00:00
Jason Gerard DeRose
6f95249d52
261: More work on demo using Option.__call__() for interactive input
2008-09-04 08:33:41 +00:00
Jason Gerard DeRose
915486dadc
260: Option.normalize() now does same conversion for multivalue as Option.convert() does
2008-09-04 08:16:12 +00:00
Jason Gerard DeRose
71d36aa6a0
258: Added some experimental features for interactively prompting for values
2008-09-04 07:18:26 +00:00
Jason Gerard DeRose
01b73e6910
257: Improved help command, now parsing options with optparse
2008-09-04 06:33:57 +00:00
Jason Gerard DeRose
b16deabdff
256: Fixed cli.help plugin so it looks up commands in CLI instead of API
2008-09-04 05:18:14 +00:00
Jason Gerard DeRose
ab81ca56fd
255: CLI help, console commands now subclass from public.Application; other tweeking to make CLI utilize Application
2008-09-04 04:39:01 +00:00
Jason Gerard DeRose
330c17730c
201: Added new cli command 'console' that starts a custom interactive Python console
2008-08-27 00:25:33 +00:00
Jason Gerard DeRose
b0ec8fe551
182: Renamed plublic.cmd base class to Command
2008-08-15 19:49:04 +00:00
Jason Gerard DeRose
ba8d32a110
150: NameSpace.__iter__() now iterates through the names, not the members; added NameSpace.__call__() method which iterates through the members; NameSpace no longer requires members to be Proxy instances; updated unit tests and affected code; cleaned up NameSpace docstrings and switch to epydoc param docstrings
2008-08-14 05:46:20 +00:00
Jason Gerard DeRose
d95133b66f
149: CLI.run() now does an arg.decode('utf-8') for args in sys.argv so that non-ascii characters work
2008-08-14 01:09:11 +00:00