aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-10-11 22:11:22 +0000
committerFuwn <[email protected]>2024-10-11 22:11:26 +0000
commit61beb1c0bdc524c9d029d22322ee369ad0a6e28c (patch)
tree679f82428b055c63f9b310adb4e77c8d3cd6a412
parentfeat(yae): remove remote tag restriction (diff)
downloadyae-61beb1c0bdc524c9d029d22322ee369ad0a6e28c.tar.xz
yae-61beb1c0bdc524c9d029d22322ee369ad0a6e28c.zip
feat(yae): allow statically forceable sources
-rw-r--r--sources.go1
-rw-r--r--yae.go2
2 files changed, 2 insertions, 1 deletions
diff --git a/sources.go b/sources.go
index 91410f9..67a8c6c 100644
--- a/sources.go
+++ b/sources.go
@@ -18,6 +18,7 @@ type Source struct {
TagPredicate string `json:"tag_predicate,omitempty"`
TrimTagPrefix string `json:"trim_tag_prefix,omitempty"`
Pinned bool `json:"pinned,omitempty"`
+ Force bool `json:"force,omitempty"`
}
func (s *Sources) EnsureLoaded() error {
diff --git a/yae.go b/yae.go
index 1b7a1fd..7749b2a 100644
--- a/yae.go
+++ b/yae.go
@@ -333,7 +333,7 @@ func updateSource(sources *Sources, name string, source Source, show bool, force
return updated, err
}
- if tag != source.Version || force {
+ if tag != source.Version || force || source.Force {
if show {
fmt.Println("updated version for", name, "from", source.Version, "to", tag)
}