Commit Graph

5 Commits (3b1d288d1e79d07ae51628b5ed6847c497af4990)

Author SHA1 Message Date
BodgeMaster 82d611b984 lib/cli: various fixes
- argumentWaitingForValue was never reset after the value had been retrieved
- made it so the ArgumentsParser constructor can accept const char**
- correct usage of substr() and actually use the correct position in the first place
- fix a typo where I tried to dereference `this` with `-` instead of `->`
2022-07-15 11:21:18 +02:00
BodgeMaster f5b0b74f94 lib/cli: remove useless arguments from getters, remove useless getter getProgramName (made the string public instead) 2022-07-15 09:11:39 +02:00
BodgeMaster a1223ea4b9 Minor improvements and fixes.
test/nbt_helpers: add a headline to output
Build system: remove comma from array that I added bc I thought it was correct sytax, it wasn't
lib/cli: change argument order of PositionalArgument constructor to fit in with Flag and UnpositionalArgument
lib/cli: properly define what is private and what is public in the ArgumentsParser class
2022-07-15 08:54:09 +02:00
BodgeMaster 390087fc35 lib/cli: finish initial implementation
This should be all functionality that is needed for now.
The next step is building unit tests to check that everything works correctly.

Who am I kidding? There will most certainly be bugs in there given that this
code has been typed out without ever being run.
2022-07-14 04:57:48 +02:00
BodgeMaster 91f3dfaa5e lib/cli: Add a library for command line arguments parsing
This has the parser itself already implemented, all other functionality is still
missing. So are tests.

Yes, I’m making my own getopt. Let me.
2022-07-14 03:13:48 +02:00