diff --git a/README.md b/README.md index d9d0d08..a80cc46 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ import _ "github.com/bool64/dev" // Include development helpers to project. Add `Makefile` to your module with includes standard targets. ```Makefile -#GOLANGCI_LINT_VERSION := "v2.3.1" # Optional configuration to pinpoint golangci-lint version. +#GOLANGCI_LINT_VERSION := "v2.5.0" # Optional configuration to pinpoint golangci-lint version. # The head of Makefile determines location of dev-go to include standard targets. GO ?= go diff --git a/makefiles/base.mk b/makefiles/base.mk index deac7a6..2673221 100644 --- a/makefiles/base.mk +++ b/makefiles/base.mk @@ -1,4 +1,4 @@ -#GOLANGCI_LINT_VERSION := "v2.3.1" # Optional configuration to pinpoint golangci-lint version. +#GOLANGCI_LINT_VERSION := "v2.5.0" # Optional configuration to pinpoint golangci-lint version. # The head of Makefile determines location of dev-go to include standard targets. GO ?= go diff --git a/replace.sh b/replace.sh deleted file mode 100755 index c99f142..0000000 --- a/replace.sh +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env bash -set -e - -# Replace template with actual repo data. -url=$(git remote get-url origin) - -url_nopro=${url#*//} -url_noatsign=${url_nopro#*@} - -gh_repo=${url_noatsign#"github.com:"} -gh_repo=${gh_repo#"github.com/"} -gh_repo=${gh_repo%".git"} - -project_name=$(basename $gh_repo) - -echo "## Replacing all bool64/go-template references by $project_name" -find ./.github -type f -print0 | xargs -0 perl -i -pe "s|bool64/go-template|$gh_repo|g" -find ./.github -type f -print0 | xargs -0 perl -i -pe "s|go-template|$project_name|g" - diff --git a/scripts/.golangci.yml b/scripts/.golangci.yml index af4de1c..a399ba1 100644 --- a/scripts/.golangci.yml +++ b/scripts/.golangci.yml @@ -5,6 +5,7 @@ run: linters: default: all disable: + - noinlineerr - wsl_v5 - funcorder - copyloopvar @@ -44,6 +45,7 @@ linters: generated: lax rules: - linters: + - gosec - dupl - funlen - goconst diff --git a/scripts/lint.sh b/scripts/lint.sh index fbc19a3..2fe72d2 100755 --- a/scripts/lint.sh +++ b/scripts/lint.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash [ -z "$GO" ] && GO=go -[ -z "$GOLANGCI_LINT_VERSION" ] && GOLANGCI_LINT_VERSION="v2.3.1" +[ -z "$GOLANGCI_LINT_VERSION" ] && GOLANGCI_LINT_VERSION="v2.5.0" # detecting GOPATH and removing trailing "/" if any GOPATH="$(go env GOPATH)"