summaryrefslogtreecommitdiff
path: root/cmd/krino/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/krino/main.go')
-rw-r--r--cmd/krino/main.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmd/krino/main.go b/cmd/krino/main.go
index 6d1ef96..a8fab2d 100644
--- a/cmd/krino/main.go
+++ b/cmd/krino/main.go
@@ -52,6 +52,7 @@ Sort the files in the directories listed in krino.conf by their rules.
-c FILE use FILE instead of ~/.config/krino/krino.conf
--no-color never colour the output, as when NO_COLOR is set
-P, --no-pager print the plan straight out, never through the pager
+ --min-age D for this run, skip files modified less than D ago (0, 30m, 1d)
-h, --help show this help
--version print the version
`
@@ -60,6 +61,7 @@ Sort the files in the directories listed in krino.conf by their rules.
type globals struct {
yes, dry, verbose, json bool
noColor, noPager bool
+ minAge string // --min-age as given; "" when not
conf string
}
@@ -122,6 +124,7 @@ func flagSet(name string, g *globals) *flag.FlagSet {
fs.BoolVar(&g.noColor, "no-color", g.noColor, "")
fs.BoolVar(&g.noPager, "no-pager", g.noPager, "")
fs.BoolVar(&g.noPager, "P", g.noPager, "")
+ fs.StringVar(&g.minAge, "min-age", g.minAge, "")
return fs
}