Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.5.0" # Optional configuration to pinpoint golangci-lint version.
#GOLANGCI_LINT_VERSION := "v2.11.3" # Optional configuration to pinpoint golangci-lint version.

# The head of Makefile determines location of dev-go to include standard targets.
GO ?= go
Expand Down
2 changes: 1 addition & 1 deletion makefiles/base.mk
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#GOLANGCI_LINT_VERSION := "v2.5.0" # Optional configuration to pinpoint golangci-lint version.
#GOLANGCI_LINT_VERSION := "v2.11.3" # Optional configuration to pinpoint golangci-lint version.

# The head of Makefile determines location of dev-go to include standard targets.
GO ?= go
Expand Down
2 changes: 1 addition & 1 deletion scripts/lint.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash

[ -z "$GO" ] && GO=go
[ -z "$GOLANGCI_LINT_VERSION" ] && GOLANGCI_LINT_VERSION="v2.5.0"
[ -z "$GOLANGCI_LINT_VERSION" ] && GOLANGCI_LINT_VERSION="v2.11.3"

# detecting GOPATH and removing trailing "/" if any
GOPATH="$(go env GOPATH)"
Expand Down
23 changes: 2 additions & 21 deletions templates/github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,6 @@ jobs:
go-version: stable
- uses: actions/checkout@v4
- name: golangci-lint
uses: golangci/golangci-lint-action@v8.0.0
uses: golangci/golangci-lint-action@v9.2.0
with:
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
version: v2.4.0

# Optional: working directory, useful for monorepos
# working-directory: somedir

# Optional: golangci-lint command line arguments.
# args: --issues-exit-code=0

# Optional: show only new issues if it's a pull request. The default value is `false`.
# only-new-issues: true

# Optional: if set to true then the action will use pre-installed Go.
# skip-go-installation: true

# Optional: if set to true then the action don't cache or restore ~/go/pkg.
# skip-pkg-cache: true

# Optional: if set to true then the action don't cache or restore ~/.cache/go-build.
# skip-build-cache: true
version: v2.11.3
61 changes: 18 additions & 43 deletions templates/github/workflows/release-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ on:
release:
types:
- created

permissions:
contents: write # Required to upload assets

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GO_VERSION: stable
Expand All @@ -23,60 +27,31 @@ jobs:
- name: Build artifacts
run: |
make release-assets

- name: Upload linux_amd64.tar.gz
if: hashFiles('linux_amd64.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./linux_amd64.tar.gz
asset_name: linux_amd64.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" linux_amd64.tar.gz --clobber

- name: Upload linux_amd64_dbg.tar.gz
if: hashFiles('linux_amd64_dbg.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./linux_amd64_dbg.tar.gz
asset_name: linux_amd64_dbg.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" linux_amd64_dbg.tar.gz --clobber

- name: Upload linux_arm64.tar.gz
if: hashFiles('linux_arm64.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./linux_arm64.tar.gz
asset_name: linux_arm64.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" linux_arm64.tar.gz --clobber

- name: Upload linux_arm.tar.gz
if: hashFiles('linux_arm.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./linux_arm.tar.gz
asset_name: linux_arm.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" linux_arm.tar.gz --clobber

- name: Upload darwin_amd64.tar.gz
if: hashFiles('darwin_amd64.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./darwin_amd64.tar.gz
asset_name: darwin_amd64.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" darwin_amd64.tar.gz --clobber

- name: Upload darwin_arm64.tar.gz
if: hashFiles('darwin_arm64.tar.gz') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./darwin_arm64.tar.gz
asset_name: darwin_arm64.tar.gz
asset_content_type: application/tar+gzip
run: gh release upload "${{ github.event.release.tag_name }}" darwin_arm64.tar.gz --clobber

- name: Upload windows_amd64.zip
if: hashFiles('windows_amd64.zip') != ''
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./windows_amd64.zip
asset_name: windows_amd64.zip
asset_content_type: application/zip

run: gh release upload "${{ github.event.release.tag_name }}" windows_amd64.zip --clobber
Loading