Skip to content

Commit

Permalink
Fixed all the problem reported by varcheck (unused variables)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mattia Bertorello committed Aug 30, 2018
1 parent 4026483 commit c39c498
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 12 deletions.
2 changes: 0 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,4 @@ linters:
- lll
- maligned
- megacheck
- prealloc
- unparam
- varcheck
9 changes: 5 additions & 4 deletions commands/config/dump.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,11 @@ func initDumpCommand() *cobra.Command {
}
}

var dumpFlags struct {
_default bool // If false, ask questions to the user about setting configuration properties, otherwise use default configuration.
location string // The custom location of the file to create.
}
// This struct is unused
//var dumpFlags struct {
// _default bool // If false, ask questions to the user about setting configuration properties, otherwise use default configuration.
// location string // The custom location of the file to create.
//}

func runDumpCommand(cmd *cobra.Command, args []string) {
logrus.Info("Executing `arduino config dump`")
Expand Down
9 changes: 5 additions & 4 deletions commands/lib/uninstall.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,11 @@ import (
"github.com/spf13/cobra"
)

const (
versionAll string = "all"
versionLatest string = "latest"
)
// These const are unused
//const (
// versionAll string = "all"
// versionLatest string = "latest"
//)

func initUninstallCommand() *cobra.Command {
uninstallCommand := &cobra.Command{
Expand Down
2 changes: 0 additions & 2 deletions common/formatter/formatter.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ var defaultFormatter Formatter

var logger *logrus.Logger

var debug bool

func init() {
formatters = make(map[string]Formatter, 2)
AddCustomFormatter("text", &TextFormatter{})
Expand Down

0 comments on commit c39c498

Please sign in to comment.