Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
ysmood committed Apr 16, 2023
1 parent 836b6d9 commit a182331
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 3 deletions.
15 changes: 15 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
run:
skip-dirs-use-default: false

linters:
enable:
- gofmt
- gocyclo
- misspell
- bodyclose

gocyclo:
min-complexity: 15

issues:
exclude-use-default: false
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ func main() {
return
}

os.Setenv(USE_NODE_SHELL, "true")
os.Setenv(PATH, strings.Join([]string{binPath, getEnvWithoutOtherUseNode()}, string(os.PathListSeparator)))
utils.E(os.Setenv(USE_NODE_SHELL, "true"))
utils.E(os.Setenv(PATH, strings.Join([]string{binPath, getEnvWithoutOtherUseNode()}, string(os.PathListSeparator))))

bin, err := Shell()
utils.E(err)
Expand Down
2 changes: 1 addition & 1 deletion pkg/node/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func GetNodePath(required string, logger fetchup.Logger) string {
return nodePath
}

os.RemoveAll(nodePath)
_ = os.RemoveAll(nodePath)

fu := fetchup.New(nodePath, n.URLs()...)

Expand Down

0 comments on commit a182331

Please sign in to comment.