Merge pull request #2839 from RyanDwyer/swaylock-version

Fix swaylock version string
This commit is contained in:
Drew DeVault 2018-10-15 21:30:53 +02:00 committed by GitHub
commit 4e4b922d79
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -634,13 +634,9 @@ static int parse_options(int argc, char **argv, struct swaylock_state *state,
} }
break; break;
case 'v': case 'v':
#if defined SWAY_GIT_VERSION && defined SWAY_GIT_BRANCH && defined SWAY_VERSION_DATE fprintf(stdout, "swaylock version " SWAY_VERSION "\n");
fprintf(stdout, "swaylock version %s (%s, branch \"%s\")\n", exit(EXIT_SUCCESS);
SWAY_GIT_VERSION, SWAY_VERSION_DATE, SWAY_GIT_BRANCH); break;
#else
fprintf(stdout, "version unknown\n");
#endif
return 1;
case LO_BS_HL_COLOR: case LO_BS_HL_COLOR:
if (state) { if (state) {
state->args.colors.bs_highlight = parse_color(optarg); state->args.colors.bs_highlight = parse_color(optarg);