|
| 1 | +# This is an example .goreleaser.yml file with some sensible defaults. |
| 2 | +# Make sure to check the documentation at https://goreleaser.com |
| 3 | +version: 2 |
| 4 | + |
| 5 | +before: |
| 6 | + hooks: |
| 7 | + - go mod tidy |
| 8 | + |
| 9 | +builds: |
| 10 | + - env: |
| 11 | + - CGO_ENABLED=1 |
| 12 | + goos: |
| 13 | + - linux |
| 14 | + - windows |
| 15 | + - darwin |
| 16 | + goarch: |
| 17 | + - amd64 |
| 18 | + - arm64 |
| 19 | + main: ./cmd/rapg/main.go |
| 20 | + ldflags: |
| 21 | + - -s -w |
| 22 | + |
| 23 | +archives: |
| 24 | + - format: tar.gz |
| 25 | + # this name template makes the OS and Arch compatible with the results of uname. |
| 26 | + name_template: >- |
| 27 | + {{ .ProjectName }}_ |
| 28 | + {{- title .Os }}_ |
| 29 | + {{- if eq .Arch "amd64" }}x86_64 |
| 30 | + {{- else if eq .Arch "386" }}i386 |
| 31 | + {{- else }}{{ .Arch }}{{ end }} |
| 32 | + {{- if .Arm }}v{{ .Arm }}{{ end }} |
| 33 | + # use zip for windows archives |
| 34 | + format_overrides: |
| 35 | + - goos: windows |
| 36 | + format: zip |
| 37 | + |
| 38 | +checksum: |
| 39 | + name_template: 'checksums.txt' |
| 40 | + |
| 41 | +snapshot: |
| 42 | + name_template: "{{ incpatch .Version }}-next" |
| 43 | + |
| 44 | +changelog: |
| 45 | + sort: asc |
| 46 | + filters: |
| 47 | + exclude: |
| 48 | + - '^docs:' |
| 49 | + - '^test:' |
| 50 | + |
| 51 | +brews: |
| 52 | + - |
| 53 | + name: rapg |
| 54 | + |
| 55 | + # GitHub/GitLab repository to push the formula to |
| 56 | + repository: |
| 57 | + owner: kanywst |
| 58 | + name: homebrew-tap |
| 59 | + token: "{{ .Env.TAP_GITHUB_TOKEN }}" |
| 60 | + |
| 61 | + # Template for the url which is determined by the given Token (github, gitlab or gitea) |
| 62 | + url_template: "https://github.com/kanywst/rapg/releases/download/{{ .Tag }}/{{ .ArtifactName }}" |
| 63 | + |
| 64 | + # Git author used to commit to the repository. |
| 65 | + # Defaults are shown. |
| 66 | + commit_author: |
| 67 | + name: goreleaserbot |
| 68 | + email: goreleaser@carlosbecker.com |
| 69 | + |
| 70 | + # The project name and current git tag are used in the format string. |
| 71 | + commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}" |
| 72 | + |
| 73 | + # Folder inside the repository to put the formula. |
| 74 | + # Default is the root folder. |
| 75 | + directory: Formula |
| 76 | + |
| 77 | + # Your app's homepage. |
| 78 | + # Default is empty. |
| 79 | + homepage: "https://github.com/kanywst/rapg" |
| 80 | + |
| 81 | + # Template of your app's description. |
| 82 | + # Default is empty. |
| 83 | + description: "The Developer-First Secret Manager." |
| 84 | + |
| 85 | + # SPDX identifier of your app's license. |
| 86 | + # Default is empty. |
| 87 | + license: "MIT" |
| 88 | + |
| 89 | + # Setting this will prevent goreleaser to actually try to commit the updated |
| 90 | + # formula - instead, the formula file will be stored on the dist folder only, |
| 91 | + # leaving the responsibility of publishing it to the user. |
| 92 | + # If set to auto, the release will not be published to the homebrew tap if |
| 93 | + # one of and Linux and macOS (darwin) builds are missing. |
| 94 | + skip_upload: auto # Upload requires a real TAP repo, skipping for this demo context. |
| 95 | + |
| 96 | + # So you can `brew test` your formula. |
| 97 | + # Default is empty. |
| 98 | + test: | |
| 99 | + system "#{bin}/rapg gen --help" |
| 100 | + |
| 101 | + # Custom install script for brew. |
| 102 | + # Default is 'bin.install "program"'. |
| 103 | + install: | |
| 104 | + bin.install "rapg" |
0 commit comments