24 lines
419 B
Go
24 lines
419 B
Go
|
package main
|
||
|
|
||
|
import (
|
||
|
"fmt"
|
||
|
"os"
|
||
|
)
|
||
|
|
||
|
var version = "v0.1.0"
|
||
|
|
||
|
func main() {
|
||
|
if len(os.Args) < 2 {
|
||
|
fmt.Println("provide a command")
|
||
|
os.Exit(1)
|
||
|
} else if os.Args[1] == "upgrade" {
|
||
|
fmt.Print("Trying Upgrade... ")
|
||
|
fmt.Println("Error not implemented")
|
||
|
} else if os.Args[1] == "version" {
|
||
|
fmt.Print("Version ")
|
||
|
fmt.Println(version)
|
||
|
} else {
|
||
|
fmt.Println("provide a valid command (version or upgrade)")
|
||
|
}
|
||
|
}
|