annotate version.go @ 84:70a33aa93055 draft

うーん Signed-off-by: Izuru Yakumo <yakumo.izuru@chaotic.ninja>
author yakumo.izuru
date Tue, 26 Mar 2024 02:33:51 +0000
parents 7b122b71fcfa
children 64cd79d367b5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
71
7819959ac6ca feat: move the blackfriday extension settings out of the render function, improve documentation
yakumo.izuru
parents: 55
diff changeset
1 // This is used for setting build-time variables
55
c6785950280e The fastest, period.
yakumo.izuru
parents: 49
diff changeset
2 package aya
49
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
3
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
4 import (
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
5 "fmt"
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
6 )
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
7
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
8 var (
79
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
9 // Variables set at build-time
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
10 Date string
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
11 Vendor string
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
12 Version string
49
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
13 )
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
14
79
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
15 // PrintVersion only displays the obvious
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
16 func PrintVersion() string {
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
17 return fmt.Sprintf("%s", Version)
49
88a7d4a1ff62 Add release script
prologic
parents:
diff changeset
18 }
79
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
19
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
20 // PrintFullVersion display the full version and build
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
21 func PrintFullVersion() string {
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
22 return fmt.Sprintf("%s, built at %s, on %s", Version, Date, Vendor)
7b122b71fcfa A good time to finally release a stable version
yakumo.izuru
parents: 78
diff changeset
23 }