From d21a6651a71a2e35e0f5498e85f6d9aad640bfe9 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 8 Dec 2025 07:43:03 +0000 Subject: [PATCH] Enable ForceDownload when SkipDeps is true for offline mode support Co-authored-by: yxxhero <11087727+yxxhero@users.noreply.github.com> --- pkg/app/app.go | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/pkg/app/app.go b/pkg/app/app.go index 6dffe8ed..c9f61e4c 100644 --- a/pkg/app/app.go +++ b/pkg/app/app.go @@ -161,6 +161,7 @@ func (a *App) Diff(c DiffConfigProvider) error { includeCRDs := !c.SkipCRDs() prepErr := run.withPreparedCharts("diff", state.ChartPrepareOptions{ + ForceDownload: c.SkipDeps(), SkipRepos: c.SkipRefresh() || c.SkipDeps(), SkipRefresh: c.SkipRefresh(), SkipDeps: c.SkipDeps(), @@ -231,6 +232,7 @@ func (a *App) Template(c TemplateConfigProvider) error { run.helm.SetExtraArgs() prepErr := run.withPreparedCharts("template", state.ChartPrepareOptions{ + ForceDownload: c.SkipDeps(), SkipRepos: c.SkipRefresh() || c.SkipDeps(), SkipRefresh: c.SkipRefresh(), SkipDeps: c.SkipDeps(), @@ -367,6 +369,7 @@ func (a *App) Sync(c SyncConfigProvider) error { includeCRDs := !c.SkipCRDs() prepErr := run.withPreparedCharts("sync", state.ChartPrepareOptions{ + ForceDownload: c.SkipDeps(), SkipRepos: c.SkipRefresh() || c.SkipDeps(), SkipRefresh: c.SkipRefresh(), SkipDeps: c.SkipDeps(), @@ -402,6 +405,7 @@ func (a *App) Apply(c ApplyConfigProvider) error { includeCRDs := !c.SkipCRDs() prepErr := run.withPreparedCharts("apply", state.ChartPrepareOptions{ + ForceDownload: c.SkipDeps(), SkipRepos: c.SkipRefresh() || c.SkipDeps(), SkipRefresh: c.SkipRefresh(), SkipDeps: c.SkipDeps(), @@ -465,6 +469,7 @@ func (a *App) Destroy(c DestroyConfigProvider) error { return a.ForEachState(func(run *Run) (ok bool, errs []error) { if !c.SkipCharts() { err := run.withPreparedCharts("destroy", state.ChartPrepareOptions{ + ForceDownload: c.SkipDeps(), SkipRepos: c.SkipRefresh() || c.SkipDeps(), SkipRefresh: c.SkipRefresh(), SkipDeps: c.SkipDeps(), @@ -493,10 +498,11 @@ func (a *App) Test(c TestConfigProvider) error { } err := run.withPreparedCharts("test", state.ChartPrepareOptions{ - SkipRepos: c.SkipRefresh() || c.SkipDeps(), - SkipRefresh: c.SkipRefresh(), - SkipDeps: c.SkipDeps(), - Concurrency: c.Concurrency(), + ForceDownload: c.SkipDeps(), + SkipRepos: c.SkipRefresh() || c.SkipDeps(), + SkipRefresh: c.SkipRefresh(), + SkipDeps: c.SkipDeps(), + Concurrency: c.Concurrency(), }, func() { errs = a.test(run, c) })