Commit Graph

32 Commits (master)

Author SHA1 Message Date
Denis Knauf c946a093f7 aliases are strings only or nil. more examples. 2022-01-30 14:18:20 +01:00
Denis Knauf 09b467f7bd defined_in for determine already defined commands/aliases. 2022-01-30 01:41:54 +01:00
Denis Knauf 8fe78bb406 CMD-options: OptionParser#on support "--abc STR". implemented for CMD#opt, too. 2021-12-31 15:17:46 +01:00
Denis Knauf ba922fe52c warnings/exception because of already used aliases more verbose. 2021-12-31 15:13:40 +01:00
Denis Knauf a630da465a bump 0.5.5 2021-12-31 13:56:59 +01:00
Denis Knauf 616989e96a ruby3: Opt.new: optional default - CMD.opt needs support. 2021-12-31 13:55:27 +01:00
Denis Knauf a00149ce6a ruby2.5: @os removed - OptionParser does not expect any **options, so we need not it. 2021-12-31 13:47:54 +01:00
Denis Knauf 7078305256 print exception for tests (if occur or -v) 2021-12-09 14:16:08 +01:00
Denis Knauf ec025652c9 noshortaliases fixed (meaning swapped) 2021-12-09 14:04:27 +01:00
Denis Knauf 7be062c1db min: false for no shorts. noshortaliases only for Sub-commands 2021-12-09 13:28:46 +01:00
Denis Knauf 2c654f2941 noshortaliases. warn or raise if alias already exists 2021-12-09 13:17:13 +01:00
Denis Knauf 6254349aa9 tests implemented. do not overwrite cmds by aliases. `call *a, **o` behaviour differs 2.5 <=> 2.7 2021-12-09 13:02:12 +01:00
Denis Knauf e83a7b4361 v0.5.4 2021-12-08 23:57:23 +01:00
Denis Knauf 3cc205cb02 ruby-2.5-support fix. usage with rest-arguments.
ruby-2.5 does not support `String#split() {|t|}`.  splits are replaced
by `String#split().each {|t|}`.

Usage supports printing rest-arguments.  It uses the name with three dots:

  command [<argname> ...]

Sub-commands has a generic `<command> ...` or `[<command> ...]`.
The last will be used if a nil-aliases exists.
2021-12-08 23:52:05 +01:00
Denis Knauf 6e253b8b11 0.5.3 2021-12-08 00:17:57 +01:00
Denis Knauf d2158e08ea Usage of short options without `=` 2021-12-08 00:17:37 +01:00
Denis Knauf ffd24c02f8 0.5.2 2021-12-08 00:10:18 +01:00
Denis Knauf 10061b1918 Missing argument(s) errors fixed. CMD: Methods -> Variables. 2021-12-08 00:08:47 +01:00
Denis Knauf 41940d3f10 0.5.1 2021-12-07 23:51:19 +01:00
Denis Knauf d8ecfaeb86 Merge branch 'master' of git.denkn.at:deac/dencli 2021-12-07 23:50:48 +01:00
Denis Knauf df15912e7a Sub#commands|CMD#commands should yield(name,self).
assert_type for debugging.  Commented out.
2021-12-07 23:48:28 +01:00
Denis Knauf eb61dcbc38 bump 0.5.0 2021-11-30 23:09:50 +01:00
Denis Knauf 09c4c46d25 help_full for printing recursive all available commands. support for --[no-]opt. 2021-11-30 23:09:06 +01:00
Denis Knauf d3930c00bc opts-mething redesign. completion improved. example: args-command for demonstrate arguments and options. 2021-11-30 15:23:05 +01:00
Denis Knauf 5b5b620601 version 0.3.2. calling uses kvar-splats. 2021-09-06 18:34:31 +02:00
Denis Knauf ac5e852692 bump 0.3.1 2021-01-03 16:29:05 +01:00
Denis Knauf fa5fbf8f6f options instead of arguments. arguments checking against arity if lambda. help improved. 2021-01-03 16:28:12 +01:00
Denis Knauf 27ca6faf31 desc renamed to description. arguments implemented (first dirty try) 2021-01-03 13:42:00 +01:00
Denis Knauf cae3692008 Fixing Exceptions and Exception-Handling 2020-12-28 00:29:54 +01:00
Denis Knauf ad6f53bab3 file-seperated classes. interactive CLI. 2020-12-27 23:00:53 +01:00
Denis Knauf ec3a936b36 example added. bugfixes. .gitignore 2020-12-13 17:06:00 +01:00
Denis Knauf fb9a9898ee init 2020-12-13 15:54:09 +01:00