helmfile/.github/workflows
yxxhero 607225c34d
fix: use --force-replace flag for Helm 4 instead of deprecated --force (#2477)
* fix: use --force-replace flag for Helm 4 instead of deprecated --force

Helm 4 deprecated the --force flag in favor of --force-replace.
This fix detects the Helm version and uses the appropriate flag:
- Helm 4: --force-replace
- Helm 3: --force

Also fixed a nil pointer panic in appendHideNotesFlags when called
with nil SyncOpts.

Fixes #2476

Signed-off-by: yxxhero <aiopsclub@163.com>

* fix(ci): pin semver to v2.12.0 for Go 1.25 compatibility

semver@latest requires Go 1.26.1 but the project uses Go 1.25.4.
Pinning to v2.12.0 which is compatible with Go 1.25.

Signed-off-by: yxxhero <aiopsclub@163.com>

* test: add test cases for force flag from defaults with nil release

Add test cases to cover the scenario where release.Force is nil and
HelmDefaults.Force enables force for both Helm 3 and Helm 4.

Signed-off-by: yxxhero <aiopsclub@163.com>

* test: add nil ops test and rename misleading test names

- Add test case for appendHideNotesFlags with ops=nil to prevent
  regression
- Rename force-from-default-nil-release-* to
  force-from-default-nil-force-* for clarity (release.Force is nil,
  not the release itself)

Signed-off-by: yxxhero <aiopsclub@163.com>

* refactor: add explicit parentheses for force condition

Add explicit parentheses around the two disjuncts in the force
condition to make the intended grouping unambiguous and easier
to read.

Signed-off-by: yxxhero <aiopsclub@163.com>

* refactor: check ops nil before Helm version in appendHideNotesFlags

- Swap the order to check ops == nil first to avoid unnecessary
  IsVersionAtLeast call
- Restore the "see Helm release" comment for consistency with other
  flag helpers

Signed-off-by: yxxhero <aiopsclub@163.com>

---------

Signed-off-by: yxxhero <aiopsclub@163.com>
2026-03-11 21:23:51 +08:00
..
Makefile feat: upgrade Helm version to v3.20.0 and v4.1.0 (#2373) 2026-01-23 12:02:58 +08:00
cache.yaml Update workflows (#998) 2023-09-04 06:37:21 -05:00
ci.yaml fix: use --force-replace flag for Helm 4 instead of deprecated --force (#2477) 2026-03-11 21:23:51 +08:00
images.yaml build(deps): bump docker/metadata-action from 5 to 6 (#2468) 2026-03-07 20:39:58 +08:00
lock.yaml build(deps): bump dessant/lock-threads from 5 to 6 (#2330) 2025-12-16 12:24:25 +08:00
releaser.yaml build(deps): bump goreleaser/goreleaser-action from 6 to 7 (#2416) 2026-02-24 14:55:25 +08:00