Remove all v0.x references (#1919)

* fix tests

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

* refactor(two_pass_renderer): remove unused imports and functions

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

* fix tests

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

---------

Signed-off-by: yxxhero <aiopsclub@163.com>
This commit is contained in:
yxxhero
2025-03-08 07:43:21 -06:00
committed by GitHub
parent 3f6d5f52ab
commit 5d29f03782
229 changed files with 510 additions and 9464 deletions
-7
View File
@@ -5,7 +5,6 @@ import (
"github.com/helmfile/helmfile/pkg/app"
"github.com/helmfile/helmfile/pkg/config"
"github.com/helmfile/helmfile/pkg/runtime"
)
// NewApplyCmd returns apply subcmd
@@ -44,12 +43,6 @@ func NewApplyCmd(globalCfg *config.GlobalImpl) *cobra.Command {
f.StringVar(&applyOptions.DiffArgs, "diff-args", "", `pass args to helm helm-diff`)
f.StringVar(&applyOptions.SyncArgs, "sync-args", "", `pass args to helm upgrade`)
f.StringVar(&globalCfg.GlobalOptions.Args, "args", "", "pass args to helm exec")
if !runtime.V1Mode {
// TODO: Remove this function once Helmfile v0.x
f.BoolVar(&applyOptions.RetainValuesFiles, "retain-values-files", false, "DEPRECATED: Use skip-cleanup instead")
_ = f.MarkDeprecated("retain-values-files", "Use skip-cleanup instead")
}
f.BoolVar(&applyOptions.SkipCleanup, "skip-cleanup", false, "Stop cleaning up temporary values generated by helmfile and helm-secrets. Useful for debugging. Don't use in production for security")
f.BoolVar(&applyOptions.SkipCRDs, "skip-crds", false, "if set, no CRDs will be installed on sync. By default, CRDs are installed if not already present")
f.BoolVar(&applyOptions.SkipNeeds, "skip-needs", true, `do not automatically include releases from the target release's "needs" when --selector/-l flag is provided. Does nothing when --selector/-l flag is not provided. Defaults to true when --include-needs or --include-transitive-needs is not provided`)
-41
View File
@@ -1,41 +0,0 @@
// TODO: Remove this function once Helmfile v0.x
package cmd
import (
"github.com/spf13/cobra"
"github.com/helmfile/helmfile/pkg/app"
"github.com/helmfile/helmfile/pkg/config"
)
// NewChartsCmd returns charts subcmd
func NewChartsCmd(globalCfg *config.GlobalImpl) *cobra.Command {
chartsOptions := config.NewChartsOptions()
cmd := &cobra.Command{
Use: "charts",
Short: "DEPRECATED: sync releases from state file (helm upgrade --install)",
RunE: func(cmd *cobra.Command, args []string) error {
chartsImpl := config.NewChartsImpl(globalCfg, chartsOptions)
err := config.NewCLIConfigImpl(chartsImpl.GlobalImpl)
if err != nil {
return err
}
if err := chartsImpl.ValidateConfig(); err != nil {
return err
}
a := app.New(chartsImpl)
return toCLIError(chartsImpl.GlobalImpl, a.DeprecatedSyncCharts(chartsImpl))
},
}
f := cmd.Flags()
f.StringVar(&globalCfg.GlobalOptions.Args, "args", "", "pass args to helm exec")
f.StringArrayVar(&chartsOptions.Set, "set", nil, "additional values to be merged into the helm command --set flag")
f.StringArrayVar(&chartsOptions.Values, "values", nil, "additional value files to be merged into the helm command --values flag")
f.IntVar(&chartsOptions.Concurrency, "concurrency", 0, "maximum number of concurrent helm processes to run, 0 is unlimited")
return cmd
}
-44
View File
@@ -1,44 +0,0 @@
// TODO: Remove this function once Helmfile v0.x
package cmd
import (
"github.com/spf13/cobra"
"github.com/helmfile/helmfile/pkg/app"
"github.com/helmfile/helmfile/pkg/config"
)
// NewDeleteCmd returns delete subcmd
func NewDeleteCmd(globalCfg *config.GlobalImpl) *cobra.Command {
deleteOptions := config.NewDeleteOptions()
cmd := &cobra.Command{
Use: "delete",
Short: "DEPRECATED: delete releases from state file (helm delete)",
RunE: func(cmd *cobra.Command, args []string) error {
deleteImpl := config.NewDeleteImpl(globalCfg, deleteOptions)
err := config.NewCLIConfigImpl(deleteImpl.GlobalImpl)
if err != nil {
return err
}
if err := deleteImpl.ValidateConfig(); err != nil {
return err
}
a := app.New(deleteImpl)
return toCLIError(deleteImpl.GlobalImpl, a.Delete(deleteImpl))
},
}
f := cmd.Flags()
f.StringVar(&globalCfg.GlobalOptions.Args, "args", "", "pass args to helm exec")
f.StringVar(&deleteOptions.Cascade, "cascade", "", "pass cascade to helm exec, default: background")
f.IntVar(&deleteOptions.Concurrency, "concurrency", 0, "maximum number of concurrent helm processes to run, 0 is unlimited")
f.BoolVar(&deleteOptions.Purge, "purge", false, "purge releases i.e. free release names and histories")
f.BoolVar(&deleteOptions.SkipCharts, "skip-charts", false, "don't prepare charts when deleting releases")
f.BoolVar(&deleteOptions.DeleteWait, "deleteWait", false, `override helmDefaults.wait setting "helm uninstall --wait"`)
f.IntVar(&deleteOptions.DeleteTimeout, "deleteTimeout", 300, `time in seconds to wait for helm uninstall, default: 300`)
return cmd
}
-8
View File
@@ -109,14 +109,6 @@ func NewRootCmd(globalConfig *config.GlobalOptions) (*cobra.Command, error) {
),
)
// TODO: Remove this function once Helmfile v0.x
if !runtime.V1Mode {
cmd.AddCommand(
NewChartsCmd(globalImpl),
NewDeleteCmd(globalImpl),
)
}
return cmd, nil
}