Skip to content

Commit

Permalink
remove dry-run-mode flag
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-jackson committed Apr 24, 2024
1 parent 692e046 commit 2c40ff5
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 17 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ Usage:
Flags:
-a, --attribute string required - Workspace attribute to update, use Terraform Cloud API workspace attribute names
-d, --dry-run-mode dry run mode only. (e.g. "-d")
-h, --help help for update
-v, --value string required - Value
-w, --workspace string required - Partial workspace name to search across all workspaces
Expand Down
10 changes: 0 additions & 10 deletions cmd/variablesUpdate.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,16 +78,6 @@ func init() {
false,
`optional (e.g. "-v=true") whether to do the search based on the value of the variables. (Must be false if add-key-if-not-found is true`,
)
updateCmd.Flags().BoolVarP(
&readOnlyMode,
"dry-run-mode",
"d",
false,
`optional (e.g. "-d=true") dry run mode only.`,
)
if err := updateCmd.Flags().MarkDeprecated("dry-run-mode", "use -r for read-only-mode"); err != nil {
errLog.Fatalln(err)
}
updateCmd.Flags().BoolVarP(
&sensitiveVariable,
"sensitive-variable",
Expand Down
7 changes: 1 addition & 6 deletions cmd/workspacesUpdate.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,7 @@ func init() {
requiredPrefix+"Value")
workspaceUpdateCmd.Flags().StringVarP(&workspaceFilter, flagWorkspaceFilter, "w", "",
requiredPrefix+"Partial workspace name to search across all workspaces")
workspaceUpdateCmd.Flags().BoolVarP(&readOnlyMode, "dry-run-mode", "d", false,
`dry run mode only. (e.g. "-d")`,
)
if err := updateCmd.Flags().MarkDeprecated("dry-run-mode", "use -r for read-only-mode"); err != nil {
errLog.Fatalln(err)
}

requiredFlags := []string{flagAttribute, flagValue, flagWorkspaceFilter}
for _, flag := range requiredFlags {
if err := workspaceUpdateCmd.MarkFlagRequired(flag); err != nil {
Expand Down

0 comments on commit 2c40ff5

Please sign in to comment.