Skip to content

Commit 3e5c38a

Browse files
committed
[gincmd] Hide disabled --verbose flag from usage
The verbose flag is still disabled and not finalised, but it was still appearing in the usage line of commands. Related to 7593e12
1 parent b287296 commit 3e5c38a

9 files changed

+17
-9
lines changed

gincmd/commitcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,8 @@ func CommitCmd() *cobra.Command {
7474
description := "Record changes made in a local repository. This command must be called from within the local repository clone. Specific files or directories may be specified. All changes made to the files and directories that are specified will be recorded, including addition of new files, modifications and renaming of existing files, and file deletions.\n\nIf no arguments are specified, no changes are recorded."
7575
args := map[string]string{"<filenames>": "One or more directories or files to commit."}
7676
var cmd = &cobra.Command{
77-
Use: "commit [--json | --verbose] [--message message] [<filenames>]...",
77+
// Use: "commit [--json | --verbose] [--message message] [<filenames>]...",
78+
Use: "commit [--json] [--message message] [<filenames>]...",
7879
Short: "Record changes in local repository",
7980
Long: formatdesc(description, args),
8081
Args: cobra.ArbitraryArgs,

gincmd/downloadcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ func download(cmd *cobra.Command, args []string) {
4545
func DownloadCmd() *cobra.Command {
4646
description := "Downloads changes from the remote repository to the local clone. This will create new files that were added remotely, delete files that were removed, and update files that were changed.\n\nOptionally downloads the content of all files in the repository. If 'content' is not specified, new files will be empty placeholders. Content of individual files can later be retrieved using the 'get-content' command."
4747
var cmd = &cobra.Command{
48-
Use: "download [--json | --verbose] [--content]",
48+
// Use: "download [--json | --verbose] [--content]",
49+
Use: "download [--json] [--content]",
4950
Short: "Download all new information from a remote repository",
5051
Long: formatdesc(description, nil),
5152
Args: cobra.NoArgs,

gincmd/getcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ func GetCmd() *cobra.Command {
5656
"Get and initialise the repository named 'eegdata' owned by user 'peter'": "$ gin get peter/eegdata",
5757
}
5858
var cmd = &cobra.Command{
59-
Use: "get [--json | --verbose] <repopath>",
59+
// Use: "get [--json | --verbose] <repopath>",
60+
Use: "get [--json] <repopath>",
6061
Short: "Retrieve (clone) a repository from the remote server",
6162
Long: formatdesc(description, args),
6263
Example: formatexamples(examples),

gincmd/getcontentcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ func GetContentCmd() *cobra.Command {
3535
"<filenames>": "One or more directories or files to download.",
3636
}
3737
var cmd = &cobra.Command{
38-
Use: "get-content [--json | --verbose] [<filenames>]...",
38+
// Use: "get-content [--json | --verbose] [<filenames>]...",
39+
Use: "get-content [--json] [<filenames>]...",
3940
Short: "Download the content of files from a remote repository",
4041
Long: formatdesc(description, args),
4142
Args: cobra.ArbitraryArgs,

gincmd/lockcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ func LockCmd() *cobra.Command {
4242
"<filenames>": "One or more directories or files to lock.",
4343
}
4444
var cmd = &cobra.Command{
45-
Use: "lock [--json | --verbose] <filenames>...",
45+
// Use: "lock [--json | --verbose] <filenames>...",
46+
Use: "lock [--json] <filenames>...",
4647
Short: "Lock files",
4748
Long: formatdesc(description, args),
4849
Args: cobra.MinimumNArgs(1),

gincmd/removecontentcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@ func RemoveContentCmd() *cobra.Command {
4343
"<filenames>": "One or more directories or files to remove.",
4444
}
4545
var cmd = &cobra.Command{
46-
Use: "remove-content [--json | --verbose] [<filenames>]...",
46+
// Use: "remove-content [--json | --verbose] [<filenames>]...",
47+
Use: "remove-content [--json] [<filenames>]...",
4748
Short: "Remove the content of local files that have already been uploaded",
4849
Long: formatdesc(description, args),
4950
Args: cobra.ArbitraryArgs,

gincmd/synccmd.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ func sync(cmd *cobra.Command, args []string) {
3535
func SyncCmd() *cobra.Command {
3636
description := "Synchronises changes bidirectionally between remote repositories and the local clone. This will create new files that were added remotely, delete files that were removed, and update files that were changed.\n\nOptionally downloads and uploads the content of all files in the repository. If 'content' is not specified, new files will be empty placeholders. Content of individual files can later be retrieved using the 'get-content' command."
3737
var cmd = &cobra.Command{
38-
Use: "sync [--json | --verbose] [--content]",
38+
Use: "sync [--json] [--content]",
3939
Short: "Sync all new information bidirectionally between local and remote repositories",
4040
Long: formatdesc(description, nil),
4141
Args: cobra.NoArgs,

gincmd/unlockcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ func UnlockCmd() *cobra.Command {
5252
"<filenames>": "One or more directories or files to unlock.",
5353
}
5454
var cmd = &cobra.Command{
55-
Use: "unlock [--json | --verbose] <filenames>...",
55+
// Use: "unlock [--json | --verbose] <filenames>...",
56+
Use: "unlock [--json] <filenames>...",
5657
Short: "Unlock files for editing",
5758
Long: formatdesc(description, args),
5859
Args: cobra.MinimumNArgs(1),

gincmd/uploadcmd.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ If no arguments are specified, only changes to files already being tracked are u
6565
"Upload all '.zip' files to remotes named 'gin' and 'labdata'": "$ gin upload --to gin --to labdata *.zip\n or\n$ gin upload --to gin,labdata *.zip",
6666
}
6767
var cmd = &cobra.Command{
68-
Use: "upload [--json | --verbose] [--to <remote>] [<filenames>]...",
68+
// Use: "upload [--json | --verbose] [--to <remote>] [<filenames>]...",
69+
Use: "upload [--json] [--to <remote>] [<filenames>]...",
6970
Short: "Upload local changes to a remote repository",
7071
Long: formatdesc(description, args),
7172
Args: cobra.ArbitraryArgs,

0 commit comments

Comments
 (0)