From 4d7ff0fa38617080c0e1c563b2bd370f9f07f77e Mon Sep 17 00:00:00 2001 From: Joel Noyce Barnham Date: Sun, 20 Jan 2019 19:31:15 +0000 Subject: [PATCH] Remove unused VersionPrerelease and adopt bumpversion --- .bumpversion.cfg | 8 ++++++++ cmd/xenstore/commands.go | 2 ++ cmd/xenstore/version.go | 5 ----- 3 files changed, 10 insertions(+), 5 deletions(-) create mode 100644 .bumpversion.cfg diff --git a/.bumpversion.cfg b/.bumpversion.cfg new file mode 100644 index 0000000..47238f3 --- /dev/null +++ b/.bumpversion.cfg @@ -0,0 +1,8 @@ +[bumpversion] +current_version = 0.1.0 +commit = True +tag = True + +[bumpversion:file:cmd/xenstore/version.go] +search = const Version = "{current_version}" +replace = const Version = "{new_version}" diff --git a/cmd/xenstore/commands.go b/cmd/xenstore/commands.go index 75fd311..b20d58b 100644 --- a/cmd/xenstore/commands.go +++ b/cmd/xenstore/commands.go @@ -158,6 +158,8 @@ func InfoCommand(ctx *cli.Context) error { fmt.Println("Socket Path:", xenstore.UnixSocketPath()) fmt.Println("XenBus Path:", xenstore.XenBusPath()) fmt.Println("ControlDomain:", xenstore.ControlDomain()) + fmt.Println() fmt.Println("Version:", Version) + fmt.Println("GitCommit:", GitCommit) return nil } diff --git a/cmd/xenstore/version.go b/cmd/xenstore/version.go index b0a906a..7d3c26b 100644 --- a/cmd/xenstore/version.go +++ b/cmd/xenstore/version.go @@ -5,8 +5,3 @@ var GitCommit string // The main version number that is being run at the moment. const Version = "0.1.0" - -// A pre-release marker for the version. If this is "" (empty string) -// then it means that it is a final release. Otherwise, this is a pre-release -// such as "dev" (in development), "beta", "rc1", etc. -const VersionPrerelease = "dev"