cli: put the project's version on the first line with no args.
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Mon, 25 Sep 2017 19:44:47 +0000 (15:44 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Mon, 25 Sep 2017 19:44:47 +0000 (15:44 -0400)
This is to ensure backward compatibility with Babeltrace 1.x, especially
for the LTTng analyses project which check the Babeltrace's version this
way because of a missing --version option.

Reported-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
cli/babeltrace-cfg-cli-args.c

index ad83e4c3254592e96d180648300192508c912950..293b0fe44654eb7b1995b1fd22f144109f9ea9aa 100644 (file)
@@ -4842,6 +4842,8 @@ struct bt_config *bt_config_cli_args_create(int argc, const char *argv[],
        }
 
        if (argc <= 1) {
+               print_version();
+               puts("");
                print_gen_usage(stdout);
                goto end;
        }
This page took 0.028197 seconds and 5 git commands to generate.