about summary refs log tree commit diff stats
path: root/src/version.h
diff options
context:
space:
mode:
authorStar Rauchenberger <fefferburbia@gmail.com>2024-04-20 12:36:22 -0400
committerStar Rauchenberger <fefferburbia@gmail.com>2024-04-20 12:36:22 -0400
commit5f7069d480022b115bee585724d41ff827f80f2f (patch)
treec4765205eccf73b4e7a1487fdec295968d98c276 /src/version.h
parentdc56f752bb33b4e779c5507dea03a6764d08fd0a (diff)
downloadlingo-ap-tracker-5f7069d480022b115bee585724d41ff827f80f2f.tar.gz
lingo-ap-tracker-5f7069d480022b115bee585724d41ff827f80f2f.tar.bz2
lingo-ap-tracker-5f7069d480022b115bee585724d41ff827f80f2f.zip
Replaced about box
Diffstat (limited to 'src/version.h')
-rw-r--r--src/version.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/version.h b/src/version.h index 8c567e9..7b9aebc 100644 --- a/src/version.h +++ b/src/version.h
@@ -1,7 +1,7 @@
1#ifndef VERSION_H_C757E53C 1#ifndef VERSION_H_C757E53C
2#define VERSION_H_C757E53C 2#define VERSION_H_C757E53C
3 3
4#include <iostream> 4#include <sstream>
5#include <regex> 5#include <regex>
6 6
7struct Version { 7struct Version {
@@ -23,6 +23,12 @@ struct Version {
23 } 23 }
24 } 24 }
25 25
26 std::string ToString() const {
27 std::ostringstream output;
28 output << "v" << major << "." << minor << "." << revision;
29 return output.str();
30 }
31
26 bool operator<(const Version& rhs) const { 32 bool operator<(const Version& rhs) const {
27 return (major < rhs.major) || 33 return (major < rhs.major) ||
28 (major == rhs.major && 34 (major == rhs.major &&
@@ -31,10 +37,6 @@ struct Version {
31 } 37 }
32}; 38};
33 39
34std::ostream& operator<<(std::ostream& out, const Version& ver) {
35 return out << "v" << ver.major << "." << ver.minor << "." << ver.revision;
36}
37
38constexpr const Version kTrackerVersion = Version(0, 8, 0); 40constexpr const Version kTrackerVersion = Version(0, 8, 0);
39 41
40#endif /* end of include guard: VERSION_H_C757E53C */ \ No newline at end of file 42#endif /* end of include guard: VERSION_H_C757E53C */ \ No newline at end of file