mirror of
https://github.com/goreleaser/goreleaser.git
synced 2025-01-30 04:50:45 +02:00
docs: update
This commit is contained in:
parent
1d2868b40f
commit
88b63048b1
@ -20,6 +20,17 @@ brews:
|
||||
# Templates: allowed
|
||||
name: myproject
|
||||
|
||||
# Alternative names for the current recipe.
|
||||
#
|
||||
# Useful if you want to publish a versioned formula as well, so users can
|
||||
# more easily downgrade.
|
||||
#
|
||||
# Since: v1.20 (pro)
|
||||
# Templates: allowed
|
||||
alternative_names:
|
||||
- myproject@{{ .Version }}
|
||||
- myproject@{{ .Major }}
|
||||
|
||||
# IDs of the archives to use.
|
||||
# Empty means all IDs.
|
||||
ids:
|
||||
@ -216,6 +227,34 @@ from one software to another.
|
||||
Our suggestion is to create a `my-app-head.rb` file on your tap following
|
||||
[homebrew's documentation](https://docs.brew.sh/Formula-Cookbook#unstable-versions-head).
|
||||
|
||||
## Versioned formulas
|
||||
|
||||
!!! success "GoReleaser Pro"
|
||||
|
||||
This requires [GoReleaser Pro](/pro/).
|
||||
|
||||
GoReleaser can also create a versioned formula.
|
||||
For instance, you might want to make keep previous minor versions available to
|
||||
your users, so they easily downgrade and/or keep using an older version.
|
||||
|
||||
To do that, use `alternative_names`:
|
||||
|
||||
```yaml
|
||||
# .goreleaser.yaml
|
||||
brews:
|
||||
- name: foo
|
||||
alternative_names:
|
||||
- "foo@{{ .Major }}.{{ .Minor }}"
|
||||
# other fields
|
||||
```
|
||||
|
||||
So, if you tag `v1.2.3`, GoReleaser will create and push `foo.rb` and
|
||||
`foo@1.2.rb`.
|
||||
|
||||
Later on, you can tag `v1.3.0`, and then GoReleaser will create and push both
|
||||
`foo.rb` (thus overriding the previous version) and `foo@1.3.rb`.
|
||||
Your users can then `brew install foo@1.2` to keep using the previous version.
|
||||
|
||||
## GitHub Actions
|
||||
|
||||
To publish a formula from one repository to another using GitHub Actions, you cannot use the default action token.
|
||||
|
@ -123,7 +123,7 @@ release:
|
||||
#
|
||||
# Templates: allowed
|
||||
footer: |
|
||||
## Thanks!
|
||||
## Thanks
|
||||
|
||||
Those were the changes on {{ .Tag }}!
|
||||
|
||||
|
6
www/docs/static/schema-pro.json
generated
vendored
6
www/docs/static/schema-pro.json
generated
vendored
@ -1342,6 +1342,12 @@
|
||||
},
|
||||
"service": {
|
||||
"type": "string"
|
||||
},
|
||||
"alternative_names": {
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"type": "array"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
|
Loading…
x
Reference in New Issue
Block a user