diff options
| author | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-09-02 08:44:13 +0300 |
|---|---|---|
| committer | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-09-02 08:44:13 +0300 |
| commit | 740efa6658c17158058f161b0230b7718b6bd051 (patch) | |
| tree | bab8e9c1e8e65dad2428e51a5fa3a410daba1acf /defaultCommands.c | |
| parent | f5e2da80d26c7ed8381cb31c2fde5aae67269952 (diff) | |
| download | you86-740efa6658c17158058f161b0230b7718b6bd051.tar you86-740efa6658c17158058f161b0230b7718b6bd051.tar.gz you86-740efa6658c17158058f161b0230b7718b6bd051.zip | |
(1) Added current implementations: shell input handling
Diffstat (limited to 'defaultCommands.c')
| -rw-r--r-- | defaultCommands.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/defaultCommands.c b/defaultCommands.c new file mode 100644 index 0000000..cd3442e --- /dev/null +++ b/defaultCommands.c @@ -0,0 +1,26 @@ +#include "commandHandler.h" +#include <stdio.h> + +void help(char *args) { + printf("This is the help message"); +} + +void about(char *args) { + printf("This is the about message"); +} + +void version(char *args) { + printf("This is the version message"); +} + +extern void registerHandler(char *name, F_EXECUTOR executor); + +void registerDefaultHandlers() { + registerHandler("help", &help); + registerHandler("h", &help); + registerHandler("?", &help); + registerHandler("about", &about); + registerHandler("a", &about); + registerHandler("version", &version); + registerHandler("v", &version); +} |
