From 6ce1c4bdcbbedbc632c10de250f11a6444ec58e1 Mon Sep 17 00:00:00 2001 From: stephen mcquay Date: Fri, 2 Mar 2018 23:23:18 -0800 Subject: [PATCH] Stub temporary pm version --- cmd/pm/main.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cmd/pm/main.go b/cmd/pm/main.go index 53ed5a0..99b27ab 100644 --- a/cmd/pm/main.go +++ b/cmd/pm/main.go @@ -13,6 +13,8 @@ import ( "mcquay.me/pm/pkg" ) +const Version = "dev" + const usage = `pm: simple, cross-platform system package manager subcommands: @@ -22,6 +24,7 @@ subcommands: package (pkg) -- create packages pull -- fetch all available packages from all configured remotes remote -- configure remote pmd servers + version (v) -- print version information ` const keyUsage = `pm keyring: interact with pm's OpenPGP keyring @@ -219,6 +222,8 @@ func main() { if err := db.ListAvailable(root, os.Stdout); err != nil { fatalf("pulling available packages: %v\n", err) } + case "version", "v": + fmt.Printf("pm: version %v\n", Version) default: fatalf("uknown subcommand %q\n\nusage: %v", cmd, usage) }