From a2fd0786e9f0b7113fb8ff9a620354736eea8c23 Mon Sep 17 00:00:00 2001 From: "stuart.warren" Date: Wed, 30 Dec 2020 00:29:21 +0000 Subject: [PATCH] create homebrew formula --- .github/workflows/release.yml | 1 + .goreleaser.yml | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9361c70..5805568 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,4 +23,5 @@ jobs: with: args: release env: + HOMEBREW_GITHUB_TOKEN: ${{ secrets.HOMEBREW_GITHUB_TOKEN }} GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} diff --git a/.goreleaser.yml b/.goreleaser.yml index f3345d5..cd3536d 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -22,6 +22,9 @@ archives: linux: Linux windows: Windows amd64: x86_64 + files: + - README.md + - LICENSE checksum: name_template: 'checksums.txt' snapshot: @@ -32,3 +35,22 @@ changelog: exclude: - '^docs:' - '^test:' + - Merge pull request + - Merge branch + - go mod tidy +brews: +- name: yamlfmt + tap: + owner: stuart-warren + name: homebrew-apps + token: "{{ .Env.HOMEBREW_GITHUB_TOKEN }}" + folder: Formula + homepage: https://github.com/stuart-warren/yamlfmt + description: based on gofmt, yamlfmt formats yaml files into a canonical format + license: BSD-3-clause + test: | + system "#{bin}/yamlfmt -help" + dependencies: + - name: go + install: |- + bin.install "yamlfmt"