Browse Source

DEV: help output added

master
Christos Houtouridis 1 year ago
parent
commit
cfb52ee609
2 changed files with 14 additions and 3 deletions
  1. +1
    -1
      .gitignore
  2. +13
    -2
      src/main.c

+ 1
- 1
.gitignore View File

@@ -4,4 +4,4 @@ Doc/*

*Debug
*Release
*bin

+ 13
- 2
src/main.c View File

@@ -74,7 +74,16 @@ int parse_args (settings_t *s, int argc, char const *argv[]) {
case 's': s->sendTimeout.tv_sec = atoi (optarg); break;
case 'w': s->me = atoi (optarg); break;
case 't': s->trackTime = true; break;
case 'h': printf ("This will be the help text\n"); break;
case 'h':
printf ("Syntax:\nrtes_final [-t] [-v num] [-i num] [-p num] [-s num] [-w num]\n\n");
printf ("-v, --outlevel num: Change the verbosity of the program, num can be 0, 1 or 2\n");
printf ("-i, --interval sec: Set the interval of the seeker in [sec]\n");
printf ("-p, --pingtimeout sec: Set the ping timeout in [sec]\n");
printf ("-s, --sendtimeout sec: Set the connect/send timeout in [sec]\n");
printf ("-w, --who AEM: Select the AEM of the device\n");
printf ("-t, --tracktime: Enables time tracking in statistics\n");
printf ("-h, --help: Print this and exit\n");
exit(1);
case ':':
default:
case '?':
@@ -86,7 +95,9 @@ int parse_args (settings_t *s, int argc, char const *argv[]) {
return 0;
}
/*!
* Main function
*/
int main (int argc, char const *argv[]) {
// get command line arguments


Loading…
Cancel
Save