Skip to content

Commit 3fcdae0

Browse files
committed
PGPRO-1205: Show PostgreSQL version via --version argument
1 parent a046e5f commit 3fcdae0

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/pg_probackup.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,14 @@ main(int argc, char *argv[])
224224
{
225225
if (argc == 2)
226226
{
227-
fprintf(stderr, "%s %s\n", PROGRAM_NAME, PROGRAM_VERSION);
227+
#ifdef PGPRO_VERSION
228+
fprintf(stderr, "%s %s (PostgresPro %s %s)\n",
229+
PROGRAM_NAME, PROGRAM_VERSION,
230+
PGPRO_VERSION, PGPRO_EDITION);
231+
#else
232+
fprintf(stderr, "%s %s (PostgreSQL %s)\n",
233+
PROGRAM_NAME, PROGRAM_VERSION, PG_VERSION);
234+
#endif
228235
exit(0);
229236
}
230237
else if (strcmp(argv[2], "--help") == 0)

0 commit comments

Comments
 (0)