template / files / .goreleaser.yaml
.goreleaser.yaml
| 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 | before: |
| 5 | hooks: |
| 6 | # You may remove this if you don't use go modules. |
| 7 | - go mod tidy |
| 8 | builds: |
| 9 | - main: ./cmd/template/ |
| 10 | env: |
| 11 | - CGO_ENABLED=0 |
| 12 | goos: |
| 13 | - linux |
| 14 | - windows |
| 15 | - darwin |
| 16 | ldflags: |
| 17 | - -w -s -X main.Version={{.Version}} |
| 18 | checksum: |
| 19 | name_template: 'checksums.txt' |
| 20 | snapshot: |
| 21 | version_template: "{{ incpatch .Version }}-next" |
| 22 | changelog: |
| 23 | sort: asc |
| 24 | filters: |
| 25 | exclude: |
| 26 | - '^docs:' |
| 27 | - '^test:' |
| 28 | # from https://goreleaser.com/customization/homebrew/ |
| 29 | # for https://gitlab.com/PavelSafronov/template |
| 30 | brews: |
| 31 | - |
| 32 | # Name template of the recipe |
| 33 | # Default to project name |
| 34 | name: template |
| 35 | |
| 36 | # GitHub/GitLab repository to push the formula to |
| 37 | repository: |
| 38 | # Repository owner template. (templateable) |
| 39 | owner: PavelSafronov |
| 40 | |
| 41 | # Repository name. (templateable) |
| 42 | name: template |
| 43 | |
| 44 | # Optionally a branch can be provided. (templateable) |
| 45 | # |
| 46 | # Defaults to the default repository branch. |
| 47 | branch: main |
| 48 | |
| 49 | # Template for the url which is determined by the given Token (github, |
| 50 | # gitlab or gitea) |
| 51 | # |
| 52 | # Default depends on the client. |
| 53 | # https://gitlab.com/PavelSafronov/template/-/releases/v0.1.17/downloads/template_0.1.17_Linux_i386.tar.gz |
| 54 | url_template: "https://gitlab.com/PavelSafronov/template/-/releases/{{ .Tag }}/downloads/{{ .ArtifactName }}" |
| 55 | |
| 56 | # Git author used to commit to the repository. |
| 57 | # Defaults are shown. |
| 58 | commit_author: |
| 59 | name: Pavel Safronov |
| 60 | email: pavel.safronov@gmail.com |
| 61 | |
| 62 | # The project name and current git tag are used in the format string. |
| 63 | commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}" |
| 64 | |
| 65 | # Folder inside the repository to put the formula. |
| 66 | # Default is the root folder. |
| 67 | directory: HomebrewFormula |
| 68 | |
| 69 | # Caveats for the user of your binary. |
| 70 | # Default is empty. |
| 71 | caveats: "How to use this binary: https://gitlab.com/PavelSafronov/template/-/blob/main/README.md" |
| 72 | |
| 73 | # Your app's homepage. |
| 74 | # Default is empty. |
| 75 | homepage: "https://gitlab.com/PavelSafronov/template" |
| 76 | |
| 77 | # Template of your app's description. |
| 78 | # Default is empty. |
| 79 | description: "This CLI creates files and folders with generated templated names and content." |
| 80 | |
| 81 | # SPDX identifier of your app's license. |
| 82 | # Default is empty. |
| 83 | license: "MIT" |
| 84 | |
| 85 | # So you can `brew test` your formula. |
| 86 | # Default is empty. |
| 87 | test: | |
| 88 | system "#{bin}/template --version" |
| 89 | |
| 90 | # Custom post_install script for brew. |
| 91 | # Could be used to do any additional work after the "install" script |
| 92 | # Default is empty. |
| 93 | post_install: | |
| 94 | system "#{bin}/template init" |