INNER CODE UNIT · Go

main

cri-o/cri-o · scripts/version_bump.go:13

func main() {
	var bumpType string

	var versionFile string

	var specFile string

	// Define command-line flags for bump type and version file
	flag.StringVar(&bumpType, "bump", "", "Version bump type: major, minor, or patch")
	flag.StringVar(&versionFile, "f", "../internal/version/version.go", "Path to the version file")
	flag.StringVar(&specFile, "spec", "../contrib/test/ci/cri-o.spec", "Path to the spec file")
	flag.Parse()

	// Read the current version from the version.go file
	currentVersion, err := getCurrentVersion(versionFile)
	if err != nil {
		fmt.Printf("Error reading current version: %q\n", err)
		os.Exit(1)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…