We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7c3ba80 commit bed4ddaCopy full SHA for bed4dda
2 files changed
cmd/root.go
@@ -45,7 +45,8 @@ func init() {
45
rootCmd.AddCommand(&lastSeenCmd)
46
}
47
48
-func Execute() {
+func Execute(version string) {
49
+ rootCmd.Version = version
50
if err := rootCmd.Execute(); err != nil {
51
os.Exit(1)
52
main.go
@@ -2,6 +2,8 @@ package main
2
3
import "github.com/dsh2dsh/check_syncthing/cmd"
4
5
+var version string
6
+
7
func main() {
- cmd.Execute()
8
+ cmd.Execute(version)
9
0 commit comments