use main.version rather than subpackage variables

This commit is contained in:
Matthew R. Kasun
2022-02-08 07:01:39 -05:00
parent acef10991b
commit 4ab924af3e
5 changed files with 30 additions and 14 deletions

View File

@@ -13,11 +13,14 @@ import (
"github.com/urfave/cli/v2"
)
var version = "dev"
func main() {
app := cli.NewApp()
app.Name = "Netclient CLI"
app.Usage = "Netmaker's netclient agent and CLI. Used to perform interactions with Netmaker server and set local WireGuard config."
app.Version = ncutils.Version
app.Version = version
ncutils.SetVersion(version)
cliFlags := cli_options.GetFlags(ncutils.GetHostname())
app.Commands = cli_options.GetCommands(cliFlags[:])