0
0
mirror of https://github.com/thegeeklab/git-sv.git synced 2024-11-24 11:10:39 +00:00

refactor: change start and end descriptions

issue: #7
This commit is contained in:
Beatriz Vieira 2021-01-25 18:01:35 -03:00
parent 3652c52478
commit 741962bd23

View File

@ -43,25 +43,25 @@ func main() {
Name: "commit-log", Name: "commit-log",
Aliases: []string{"cl"}, Aliases: []string{"cl"},
Usage: "list all commit logs according to range as jsons", Usage: "list all commit logs according to range as jsons",
Description: "when flag range is \"tag\" and start is empty, last tag created will be used instead", Description: "The range filter is used based on git log filters, check https://git-scm.com/docs/git-log for more info. When flag range is \"tag\" and start is empty, last tag created will be used instead. When flag range is \"date\", if \"end\" is YYYY-MM-DD the range will be inclusive.",
Action: commitLogHandler(git, semverProcessor), Action: commitLogHandler(git, semverProcessor),
Flags: []cli.Flag{ Flags: []cli.Flag{
&cli.StringFlag{Name: "t", Aliases: []string{"tag"}, Usage: "get commit log from a specific tag"}, &cli.StringFlag{Name: "t", Aliases: []string{"tag"}, Usage: "get commit log from a specific tag"},
&cli.StringFlag{Name: "r", Aliases: []string{"range"}, Usage: "type of range of commits, use: tag, date or hash", Value: string(sv.TagRange)}, &cli.StringFlag{Name: "r", Aliases: []string{"range"}, Usage: "type of range of commits, use: tag, date or hash", Value: string(sv.TagRange)},
&cli.StringFlag{Name: "s", Aliases: []string{"start"}, Usage: "start range"}, &cli.StringFlag{Name: "s", Aliases: []string{"start"}, Usage: "start range of git log revision range, if date, the value is used on since flag instead"},
&cli.StringFlag{Name: "e", Aliases: []string{"end"}, Usage: "end range"}, &cli.StringFlag{Name: "e", Aliases: []string{"end"}, Usage: "end range of git log revision range, if date, the value is used on until flag instead"},
}, },
}, },
{ {
Name: "commit-notes", Name: "commit-notes",
Aliases: []string{"cn"}, Aliases: []string{"cn"},
Usage: "generate a commit notes according to range", Usage: "generate a commit notes according to range",
Description: "when flag range is \"tag\" and start is empty, last tag created will be used instead", Description: "The range filter is used based on git log filters, check https://git-scm.com/docs/git-log for more info. When flag range is \"tag\" and start is empty, last tag created will be used instead. When flag range is \"date\", if \"end\" is YYYY-MM-DD the range will be inclusive.",
Action: commitNotesHandler(git, releasenotesProcessor, outputFormatter), Action: commitNotesHandler(git, releasenotesProcessor, outputFormatter),
Flags: []cli.Flag{ Flags: []cli.Flag{
&cli.StringFlag{Name: "r", Aliases: []string{"range"}, Usage: "type of range of commits, use: tag, date or hash", Required: true}, &cli.StringFlag{Name: "r", Aliases: []string{"range"}, Usage: "type of range of commits, use: tag, date or hash", Required: true},
&cli.StringFlag{Name: "s", Aliases: []string{"start"}, Usage: "start range"}, &cli.StringFlag{Name: "s", Aliases: []string{"start"}, Usage: "start range of git log revision range, if date, the value is used on since flag instead"},
&cli.StringFlag{Name: "e", Aliases: []string{"end"}, Usage: "end range"}, &cli.StringFlag{Name: "e", Aliases: []string{"end"}, Usage: "end range of git log revision range, if date, the value is used on until flag instead"},
}, },
}, },
{ {