mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
Timew: Added dispatch to the 'help' command
This commit is contained in:
parent
e507dee0e5
commit
ac2c0dded4
1 changed files with 12 additions and 0 deletions
|
@ -26,6 +26,8 @@
|
||||||
|
|
||||||
#include <cmake.h>
|
#include <cmake.h>
|
||||||
#include <Grammar.h>
|
#include <Grammar.h>
|
||||||
|
#include <common.h>
|
||||||
|
#include <commands.h>
|
||||||
#include <LR0.h>
|
#include <LR0.h>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <new>
|
#include <new>
|
||||||
|
@ -85,6 +87,16 @@ int main (int argc, const char** argv)
|
||||||
// TODO Parse rules.
|
// TODO Parse rules.
|
||||||
|
|
||||||
// TODO Dispatch to commands.
|
// TODO Dispatch to commands.
|
||||||
|
if (argc > 1)
|
||||||
|
{
|
||||||
|
// TODO argv[1] is a command.
|
||||||
|
if (closeEnough ("help", argv[1], 2))
|
||||||
|
CmdHelp ();
|
||||||
|
}
|
||||||
|
else if (argc == 1)
|
||||||
|
{
|
||||||
|
// TODO Default command
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
catch (const std::string& error)
|
catch (const std::string& error)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue