diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 75c71fa..8e35356 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,7 +15,10 @@ jobs: - name: Set up Go uses: actions/setup-go@v4 with: - go-version: '1.20.6' + go-version: '1.20.4' + + - name: Fetch vendor + run: make vendor - name: Run GoReleaser uses: goreleaser/goreleaser-action@v4 diff --git a/.goreleaser.yml b/.goreleaser.yml new file mode 100644 index 0000000..99a92da --- /dev/null +++ b/.goreleaser.yml @@ -0,0 +1,63 @@ +build: + binary: jlv + main: ./cmd/jlv + goos: + - windows + - darwin + - linux + goarch: + - "386" + - amd64 + - arm + - arm64 + goarm: + - "6" + ignore: + - goos: darwin + goarch: "386" + env: + - CGO_ENABLED=0 + +gomod: + proxy: false + +archives: + - name_template: "{{.Binary}}_{{.Os}}_{{.Arch}}" + files: + - README.md + - LICENSE + format_overrides: + - goos: windows + format: zip + +release: + draft: false + +snapshot: + name_template: "{{.Tag}}" + +checksum: + name_template: "task_checksums.txt" + +nfpms: + - vendor: Task + homepage: https://github.com/hedhyw/jlv + maintainer: Maksym Kryvchun + description: JSON Log Viewer tool. + license: MIT + formats: + - deb + - rpm + file_name_template: "{{.ProjectName}}_{{.Os}}_{{.Arch}}" + +brews: + - name: jlv + description: JSON Log Viewer tool. + license: MIT + homepage: https://github.com/hedhyw/homebrews + tap: + owner: hedhyw + name: homebrew-main + test: system "#{bin}/jlv", "-help" + install: |- + bin.install "jlv"