Skip to content

Commit

Permalink
refactor(misc): fix some small lint issues (#95)
Browse files Browse the repository at this point in the history
  • Loading branch information
jlucktay authored Jul 16, 2020
1 parent 4445c8e commit e9badbf
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion pkg/cli/editor.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"strings"
)

// DefaultEditor is nano because I prefer it. :D
// DefaultEditor is nano because I prefer it.
const DefaultEditor = "nano"

// PreferredEditorResolver is a function that returns an editor that the user prefers to use, such as the configured
Expand Down
4 changes: 2 additions & 2 deletions pkg/cmd/cancel/cancel.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/spf13/cobra"
)

// cancelCmd represents the cancel command
// NewCommand returns the cancel command.
func NewCommand() *cobra.Command {
c := &cobra.Command{
Use: "cancel",
Expand All @@ -17,7 +17,7 @@ func NewCommand() *cobra.Command {
Cobra is a CLI library for Go that empowers applications.
This application is a tool to generate the needed files
to quickly create a Cobra application.`,
Run: func(cmd *cobra.Command, args []string) {
Run: func(cmd *cobra.Command, _ []string) {
fmt.Printf("'%s' called - not yet implemented!\n", cmd.CalledAs())
},
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/cmd/init/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ func NewCommand() *cobra.Command {
Long: `Runs Terraform with values derived from configured settings to initialise the
current stack directory, using the Azure storage account for the remote state
backend.`,
Run: func(cmd *cobra.Command, args []string) {
Run: func(_ *cobra.Command, _ []string) {
common.InitStack()
},
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/cmd/issue/issue.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ The above command would create a new issue in the configured GitHub org/repo
titled "My issue title" with body text entered and saved through the user's
default editor, denoted by the EDITOR environment variable.`,

Run: func(cmd *cobra.Command, args []string) {
Run: func(cmd *cobra.Command, _ []string) {
title, errTitle := cmd.Flags().GetString("title")
if errTitle != nil {
panic(errTitle)
Expand Down
4 changes: 2 additions & 2 deletions pkg/common/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func run(cmd *exec.Cmd) {
chPrint := make(chan string)
scanOut := bufio.NewScanner(stdout)

//nolint:gomnd // This wait group covers the single goroutine started immediately below
// This wait group covers the single goroutine started immediately below
wg.Add(1)

go func() {
Expand All @@ -44,7 +44,7 @@ func run(cmd *exec.Cmd) {

scanErr := bufio.NewScanner(stderr)

//nolint:gomnd // This wait group covers the single goroutine started immediately below
// This wait group covers the single goroutine started immediately below
wg.Add(1)

go func() {
Expand Down

0 comments on commit e9badbf

Please sign in to comment.