commit 4e4b922d794f4f27968275fa3e5b9245a80eede4
parent f6ad4908bc2f366ccbee18889ffe35c7ee436389
Author: Drew DeVault <sir@cmpwn.com>
Date: Mon, 15 Oct 2018 21:30:53 +0200
Merge pull request #2839 from RyanDwyer/swaylock-version
Fix swaylock version string
Diffstat:
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/swaylock/main.c b/swaylock/main.c
@@ -634,13 +634,9 @@ static int parse_options(int argc, char **argv, struct swaylock_state *state,
}
break;
case 'v':
-#if defined SWAY_GIT_VERSION && defined SWAY_GIT_BRANCH && defined SWAY_VERSION_DATE
- fprintf(stdout, "swaylock version %s (%s, branch \"%s\")\n",
- SWAY_GIT_VERSION, SWAY_VERSION_DATE, SWAY_GIT_BRANCH);
-#else
- fprintf(stdout, "version unknown\n");
-#endif
- return 1;
+ fprintf(stdout, "swaylock version " SWAY_VERSION "\n");
+ exit(EXIT_SUCCESS);
+ break;
case LO_BS_HL_COLOR:
if (state) {
state->args.colors.bs_highlight = parse_color(optarg);