summaryrefslogtreecommitdiff
path: root/argv.go
blob: 6d4b85f3bd249be8baa02c36d55b9d5053e218e6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package main

/*
	this parses the command line arguements
*/

var argv args

type args struct {
	Recursive bool `arg:"--recursive"  default:"false"   help:"clean every repo found in go/src or go.work"`
	Auto      bool `arg:"--auto"                         help:"don't approve via STDIN"`
}

func (args) Version() string {
	return "go-clean " + VERSION + "    Built on " + BUILDTIME
}

func (a args) Description() string {
	return `
go-clean will try to verify your go.* files are using the newest package versions

* Recreate go.* with 'go mod init' and 'go mod tidy'
* Check that the most recent master branch versions are used
* Try to trim go.sum of non-existent entries
`
}