Consistent punctuation in command usages (#5139)

* Fix spelling and grammatical errors in command docs
* Add periods for consistency across the long command descriptions
* Format imports
This commit is contained in:
Kevin Lee 2022-01-31 02:56:12 -08:00 committed by GitHub
parent a5dddbc1bf
commit 0d143ca89c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 15 additions and 15 deletions

View file

@ -55,7 +55,7 @@ var configOptions = []ConfigOption{
},
{
Key: "http_unix_socket",
Description: "the path to a unix socket through which to make HTTP connection",
Description: "the path to a Unix socket through which to make an HTTP connection",
DefaultValue: "",
},
{

View file

@ -46,7 +46,7 @@ func NewCmdRefresh(f *cmdutil.Factory, runF func(*RefreshOptions) error) *cobra.
Use: "refresh",
Args: cobra.ExactArgs(0),
Short: "Refresh stored authentication credentials",
Long: heredoc.Doc(`Expand or fix the permission scopes for stored credentials
Long: heredoc.Doc(`Expand or fix the permission scopes for stored credentials.
The --scopes flag accepts a comma separated list of scopes you want your gh credentials to have. If
absent, this command ensures that gh has access to a minimum set of scopes.

View file

@ -33,7 +33,7 @@ func NewCmdExtension(f *cmdutil.Factory) *cobra.Command {
An extension cannot override any of the core gh commands.
See the list of available extensions at <https://github.com/topics/gh-extension>
See the list of available extensions at <https://github.com/topics/gh-extension>.
`, "`"),
Aliases: []string{"extensions"},
}
@ -82,7 +82,7 @@ func NewCmdExtension(f *cmdutil.Factory) *cobra.Command {
To install an extension in development from the current directory, use "." as the
value of the repository argument.
See the list of available extensions at <https://github.com/topics/gh-extension>
See the list of available extensions at <https://github.com/topics/gh-extension>.
`),
Example: heredoc.Doc(`
$ gh extension install owner/gh-extension

View file

@ -11,7 +11,7 @@ func NewCmdGPGKey(f *cmdutil.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "gpg-key <command>",
Short: "Manage GPG keys",
Long: "Manage GPG keys registered with your GitHub account",
Long: "Manage GPG keys registered with your GitHub account.",
}
cmd.AddCommand(cmdList.NewCmdList(f, nil))

View file

@ -20,7 +20,7 @@ func NewCmdIssue(f *cmdutil.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "issue <command>",
Short: "Manage issues",
Long: `Work with GitHub issues`,
Long: `Work with GitHub issues.`,
Example: heredoc.Doc(`
$ gh issue list
$ gh issue create --label bug

View file

@ -24,7 +24,7 @@ func NewCmdPR(f *cmdutil.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "pr <command>",
Short: "Manage pull requests",
Long: "Work with GitHub pull requests",
Long: "Work with GitHub pull requests.",
Example: heredoc.Doc(`
$ gh pr checkout 353
$ gh pr create --fill

View file

@ -31,7 +31,7 @@ func NewCmdReady(f *cmdutil.Factory, runF func(*ReadyOptions) error) *cobra.Comm
Use: "ready [<number> | <url> | <branch>]",
Short: "Mark a pull request as ready for review",
Long: heredoc.Doc(`
Mark a pull request as ready for review
Mark a pull request as ready for review.
Without an argument, the pull request that belongs to the current branch
is marked as ready.

View file

@ -2,11 +2,11 @@ package rename
import (
"fmt"
"github.com/cli/cli/v2/api"
"net/http"
"github.com/AlecAivazis/survey/v2"
"github.com/MakeNowJust/heredoc"
"github.com/cli/cli/v2/api"
"github.com/cli/cli/v2/context"
"github.com/cli/cli/v2/git"
"github.com/cli/cli/v2/internal/config"
@ -41,7 +41,7 @@ func NewCmdRename(f *cmdutil.Factory, runf func(*RenameOptions) error) *cobra.Co
cmd := &cobra.Command{
Use: "rename [<new-name>]",
Short: "Rename a repository",
Long: heredoc.Doc(`Rename a GitHub repository
Long: heredoc.Doc(`Rename a GitHub repository.
By default, this renames the current repository; otherwise renames the specified repository.`),
Args: cobra.MaximumNArgs(1),

View file

@ -23,7 +23,7 @@ func NewCmdRepo(f *cmdutil.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "repo <command>",
Short: "Create, clone, fork, and view repositories",
Long: `Work with GitHub repositories`,
Long: `Work with GitHub repositories.`,
Example: heredoc.Doc(`
$ gh repo create
$ gh repo clone cli/cli

View file

@ -44,7 +44,7 @@ func NewCmdSync(f *cmdutil.Factory, runF func(*SyncOptions) error) *cobra.Comman
Long: heredoc.Docf(`
Sync destination repository from source repository. Syncing uses the main branch
of the source repository to update the matching branch on the destination
repository so they are equal. A fast forward update will be used execept when the
repository so they are equal. A fast forward update will be used except when the
%[1]s--force%[1]s flag is specified, then the two branches will
by synced using a hard reset.

View file

@ -11,7 +11,7 @@ var HelpTopics = map[string]map[string]string{
"short": "Information about using gh with MinTTY",
"long": heredoc.Doc(`
MinTTY is the terminal emulator that comes by default with Git
for Windows. It has known issues with gh's ability to prompt a
for Windows. It has known issues with gh's ability to prompt a
user for input.
There are a few workarounds to make gh work with MinTTY:

View file

@ -11,7 +11,7 @@ func NewCmdSSHKey(f *cmdutil.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "ssh-key <command>",
Short: "Manage SSH keys",
Long: "Manage SSH keys registered with your GitHub account",
Long: "Manage SSH keys registered with your GitHub account.",
}
cmd.AddCommand(cmdList.NewCmdList(f, nil))

View file

@ -51,7 +51,7 @@ func NewCmdRun(f *cmdutil.Factory, runF func(*RunOptions) error) *cobra.Command
Long: heredoc.Doc(`
Create a workflow_dispatch event for a given workflow.
This command will trigger GitHub Actions to run a given workflow file. The given workflow file must
This command will trigger GitHub Actions to run a given workflow file. The given workflow file must
support a workflow_dispatch 'on' trigger in order to be run in this way.
If the workflow file supports inputs, they can be specified in a few ways: