tenox7 / ttyplot

a realtime plotting utility for terminal/console with data input from stdin
Apache License 2.0
956 stars 42 forks source link

Store the version string in a single place #181

Open edgar-bonet opened 1 month ago

edgar-bonet commented 1 month ago

As shown by the recent version bumps (1.6.4 and 1.6.5), incrementing the version number is error prone. This is because this version number is stored in two different files (ttyplot.c and recordings/expected.txt), and these have to be kept manually in sync.

This pull request creates a single source of truth for the version string, which is the Makefile. The file expected.txt has been replaced by a template containing the string @VERSION@, which the CI workflow replaces by the actual version string. The script get_back_in_sync.sh does the reverse replacement.