Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
package main
import (
func main() {
var version string
flag.StringVar(&version, "setVersion", "1.0.0", "") // parse the value of the flag setVersion to variable version
fmt.Println("version = ", version)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment