Skip to content

Commit

Permalink
feat(terraform): add terraform workspace command alias
Browse files Browse the repository at this point in the history
  • Loading branch information
mefengl committed Feb 23, 2023
1 parent a1ed3b4 commit 9090597
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions plugins/terraform/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ plugins=(... terraform)
| `tfo` | `terraform output` |
| `tfall` | `terraform init && terraform fmt -recursive && terraform validate && terraform plan && terraform apply` |
| `tfall!` | `terraform init && terraform fmt -recursive && terraform validate && terraform plan && terraform apply -auto-approve` |
| `tfw` | `terraform workspace` |
| `tfws` | `terraform workspace select` |
| `tfwn` | `terraform workspace new` |
| `tfwd` | `terraform workspace delete` |
| `tfwls` | `terraform workspace list` |
| `tfr` | `terraform refresh` |

## Prompt function

Expand Down
6 changes: 6 additions & 0 deletions plugins/terraform/terraform.plugin.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,9 @@ alias tfo='terraform output'
alias tfc='terraform console'
alias tfall='terraform init && terraform fmt -recursive && terraform validate && terraform plan && terraform apply'
alias tfall!='terraform init && terraform fmt -recursive && terraform validate && terraform plan && terraform apply -auto-approve'
alias tfw='terraform workspace'
alias tfws='terraform workspace select'
alias tfwn='terraform workspace new'
alias tfwd='terraform workspace delete'
alias tfwls='terraform workspace list'
alias tfr='terraform refresh'

0 comments on commit 9090597

Please sign in to comment.