CLIFramework icon indicating copy to clipboard operation
CLIFramework copied to clipboard

Update documentation on Wiki

Open c9s opened this issue 11 years ago • 3 comments
trafficstars

  • [ ] The Application.
  • [ ] Command options.
  • [x] Grouping commands.
  • [ ] Writing command classes.
  • [ ] Adding subcommands.
  • [ ] Logging the messages.
  • [ ] Command testing.
  • [ ] Prompter.
  • [ ] Chooser.
  • [ ] Corrector

c9s avatar Oct 05 '14 07:10 c9s

@c9s The CLIFramework is insanely powerful, but due to a lack of documentation I experienced it as almost unusable. It's a shame that this might turn people away. I took the time to go through the source files and read through the available methods myself and this package has been of great use in my attempt to create a web client console window for admins. In return, I'd like to contribute to the projects wiki pages and write up as much as I can. (I'd make a separate branch/commit on it using the dedicated wiki repo).

The question is, are you okay with this and could you not make any edits on the wiki until I come back with my changes?

Bertie2011 avatar Aug 27 '21 05:08 Bertie2011

@Bertie2011 sure! anything is welcomed! you can edit the wiki pages directly ;-)

c9s avatar Aug 27 '21 12:08 c9s

🎁 There you go, I expanded the wiki quite a bit :)

A few things left to do though:

  • Logger
    • in setLevel, the $indent parameter is useless and can be removed.
    • the $indent variable created in __call is not used in that method and can be removed.
  • Tables
    • The table cell formatters seem to be broken as they have the use NumberFormatter statement which cannot be found in my test project. Because I could not test the formatters, I did not include documentation about setting custom formatters. (Which has to be added still.)
      • I couldn't figure out from the code if I had to pass CurrencyFormatCell::class, new CurrencyFormatCell(...) or (new CurrencyFormatCell(...))->format (since it seemed to expect a callable)?
  • Progress
    • Progress Star seems to have been made for a very specific use case. It should be made more generic (with similar methods to Progress Bar) before being included in the wiki.
      • Also it extends from Progress Reporter interface, but does not seem to provide an update($finished, $total) method
    • Progress Bar Styles don't seem to be used and have therefore not been included in the wiki.
  • ActionLogger
    • The description parameter and fields are not being used and could be removed. If the API changes, the wiki should change too.

Also, please keep the wiki up to date from now on :sweat_smile:

Bertie2011 avatar Aug 29 '21 12:08 Bertie2011