diff --git a/meson.build b/meson.build index a343af5..76a6944 100644 --- a/meson.build +++ b/meson.build @@ -3,7 +3,8 @@ project('diya-session-manager', version: '0.1.1', license: 'MIT', meson_version: '>=0.58.0', - default_options: ['c_std=gnu11', 'warning_level=3']) + default_options: ['c_std=gnu11', 'warning_level=3'] +) lib_so_version = '0' @@ -17,6 +18,7 @@ add_project_arguments( '-Wno-pedantic', '-Werror=implicit-function-declaration', '-Werror=return-type', + '-DVERSION="@0@"'.format(meson.project_version()) ], language: 'c') diff --git a/src/main.c b/src/main.c index a0aeadc..8152129 100644 --- a/src/main.c +++ b/src/main.c @@ -16,7 +16,11 @@ static gchar **g_shell_argv; static void help(const char* name) { + printf("diya-session-manager - a session manager for diya shells\n"); printf("Usage: %s [-c config_file]\n" ,name); +#ifdef VERSION + printf("Version: %s\n", VERSION); +#endif } static gboolean restart(gpointer d)