Adding version command to console
This commit is contained in:
parent
d7dbadff25
commit
b85d2307e9
|
@ -858,6 +858,15 @@ static void onConsoleKeymapCommand(Console* console, const char* param)
|
|||
commandDone(console);
|
||||
}
|
||||
|
||||
static void onConsoleVersionCommand(Console* console, const char* param)
|
||||
{
|
||||
printBack(console, "\n");
|
||||
char msg[64] = {0};
|
||||
sprintf(msg, "%i.%i.%i", TIC_VERSION_MAJOR, TIC_VERSION_MINOR, TIC_VERSION_PATCH);
|
||||
consolePrint(console, msg, CONSOLE_BACK_TEXT_COLOR);
|
||||
commandDone(console);
|
||||
}
|
||||
|
||||
static void onConsoleConfigCommand(Console* console, const char* param)
|
||||
{
|
||||
if(param == NULL)
|
||||
|
@ -1832,6 +1841,7 @@ static const struct
|
|||
{"demo", NULL, "install demo carts", onConsoleInstallDemosCommand},
|
||||
{"config", NULL, "edit TIC config", onConsoleConfigCommand},
|
||||
{"keymap", NULL, "configure keyboard mapping", onConsoleKeymapCommand},
|
||||
{"version", NULL, "show the current version", onConsoleVersionCommand},
|
||||
{"surf", NULL, "open carts browser", onConsoleSurfCommand},
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue