Skip to content

Commit

Permalink
[Merge on 9/18] Remove nexus feature flag (#391)
Browse files Browse the repository at this point in the history
* Remove nexus feature flag

* PR review changes
  • Loading branch information
nikki-dag authored Sep 18, 2024
1 parent 89fff33 commit 6a6af68
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 23 deletions.
14 changes: 1 addition & 13 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,20 +27,8 @@ func NewApp(params AppParams) (*cli.App, error) {
InsecureConnectionFlag,
EnableDebugLogsFlag,
},
Commands: params.Commands,
}

var commands []*cli.Command

for _, command := range params.Commands {
if command.Name == "nexus" {
if IsFeatureEnabled(NexusFeatureFlag) {
commands = append(commands, command)
}
} else {
commands = append(commands, command)
}
}
app.Commands = commands

return app, nil
}
11 changes: 1 addition & 10 deletions app/feature.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@ import (

var (
GCPSinkFeatureFlag = "enable-gcp-sink"
NexusFeatureFlag = "enable-nexus"
featureflagFileName = "feature.json"
)

var supportFeatureFlags = []string{GCPSinkFeatureFlag, NexusFeatureFlag}
var supportFeatureFlags = []string{GCPSinkFeatureFlag}

type FeatureFlag struct {
Name string `json:"Name"`
Expand Down Expand Up @@ -133,14 +132,6 @@ func NewFeatureCommand() (CommandOut, error) {
return toggleFeature(GCPSinkFeatureFlag)
},
},
{
Name: "toggle-nexus",
Aliases: []string{"tnxs"},
Usage: "switch nexus on/off",
Action: func(c *cli.Context) error {
return toggleFeature(NexusFeatureFlag)
},
},
{
Name: "get",
Aliases: []string{"g"},
Expand Down

0 comments on commit 6a6af68

Please sign in to comment.