Skip to content

Commit

Permalink
Rename git version to simply version
Browse files Browse the repository at this point in the history
  • Loading branch information
lundmar committed Nov 30, 2024
1 parent c49faa7 commit b8135ea
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 15 deletions.
3 changes: 0 additions & 3 deletions src/git-version.h.in

This file was deleted.

4 changes: 2 additions & 2 deletions src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include "git-version.h"
#include "version.h"
#include "config.h"
#include "options.h"
#include "configfile.h"
Expand Down Expand Up @@ -102,7 +102,7 @@ int main(int argc, char *argv[])
error_enter_session_mode();

/* Print launch hints */
tio_printf("tio %s", GIT_VERSION);
tio_printf("tio %s", VERSION);
if (interactive_mode)
{
tio_printf("Press ctrl-%c q to quit", option.prefix_key);
Expand Down
12 changes: 6 additions & 6 deletions src/meson.build
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Generate git version header
git_version_h = vcs_tag(command : ['git', 'describe', '--tags', '--always', '--dirty'],
input : 'git-version.h.in',
output :'git-version.h',
replace_string:'@GIT_VERSION@')
# Generate version header
version_h = vcs_tag(command : ['git', 'describe', '--tags', '--always', '--dirty'],
input : 'version.h.in',
output :'version.h',
replace_string:'@VERSION@')

config_h = configuration_data()
config_h.set('BAUDRATE_CASES', baudrate_cases)
Expand All @@ -27,7 +27,7 @@ tio_sources = [
'script.c',
'fs.c',
'readline.c',
git_version_h
version_h
]


Expand Down
4 changes: 2 additions & 2 deletions src/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include <regex.h>
#include <getopt.h>
#include <errno.h>
#include "git-version.h"
#include "version.h"
#include "config.h"
#include "misc.h"
#include "print.h"
Expand Down Expand Up @@ -1088,7 +1088,7 @@ void options_parse(int argc, char *argv[])
break;

case 'v':
printf("tio %s\n", GIT_VERSION);
printf("tio %s\n", VERSION);
exit(EXIT_SUCCESS);
break;

Expand Down
4 changes: 2 additions & 2 deletions src/tty.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#if defined(__linux__)
#include <linux/serial.h>
#endif
#include "git-version.h"
#include "version.h"
#include "config.h"
#include <stdarg.h>
#include <stdio.h>
Expand Down Expand Up @@ -1091,7 +1091,7 @@ void handle_command_sequence(char input_char, char *output_char, bool *forward)
break;

case KEY_V:
tio_printf("tio %s", GIT_VERSION);
tio_printf("tio %s", VERSION);
break;

case KEY_X:
Expand Down
3 changes: 3 additions & 0 deletions src/version.h.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#pragma once

#define VERSION "@VERSION@"

0 comments on commit b8135ea

Please sign in to comment.