Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a strip-suffix: key to melange update struct to indicate strippin… #405

Merged
merged 1 commit into from
Apr 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/UPDATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ update:
shared: false # indicate that an update to this package requires an epoch bump of downstream dependencies, e.g. golang, java
github: # alternative today is `release_monitor:`
identifier: sigstore/cosign # Mandatory, org/repo for github
strip-prefix: v # Optional, if the version obtained from the update service contains a prefix which needs to be stripped when updating the melange package
strip-prefix: v # Optional, if the version obtained from the update service contains a prefix which should be ignored
strip-suffix: ignore_me # Optional, if the version obtained from the update service contains a suffix which should be ignored
use-tag: true # Optional, override the default of using a GitHub release to identify related tag to fetch. Not all projects use GitHub releases but just use tags
tag-filter: foo # Optional, filter to apply when searching tags on a GitHub repository, some repos maintain a mixture of tags for different major versions for example
```
3 changes: 2 additions & 1 deletion pkg/build/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,8 @@ type ReleaseMonitor struct {
// GitHubMonitor indicates using the GitHub API
type GitHubMonitor struct {
Identifier string `yaml:"identifier"` // org/repo for GitHub
StripPrefix string `yaml:"strip-prefix,omitempty"` // if the version in GitHub contains a prefix which needs to be stripped when updating the melange package
StripPrefix string `yaml:"strip-prefix,omitempty"` // if the version in GitHub contains a prefix which should be ignored
StripSuffix string `yaml:"strip-suffix,omitempty"` // if the version in GitHub contains a suffix which should be ignored
TagFilter string `yaml:"tag-filter,omitempty"` // filter to apply when searching tags on a GitHub repository
UseTags bool `yaml:"use-tag,omitempty"` // override the default of using a GitHub release to identify related tag to fetch. Not all projects use GitHub releases but just use tags
}
Expand Down