Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Jeconias Santos 2025-06-14 15:02:51 -03:00
commit c70b79dca5
95 changed files with 2657 additions and 547 deletions

View file

@ -15,28 +15,29 @@ plugins=(... terraform)
## Aliases
| Alias | Command |
|---------|----------------------------------|
| `tf` | `terraform` |
| `tfa` | `terraform apply` |
| `tfaa` | `terraform apply -auto-approve` |
| `tfc` | `terraform console` |
| `tfd` | `terraform destroy` |
| `tfd!` | `terraform destroy -auto-approve`|
| `tff` | `terraform fmt` |
| `tffr` | `terraform fmt -recursive` |
| `tfi` | `terraform init` |
| `tfiu` | `terraform init -upgrade` |
| `tfo` | `terraform output` |
| `tfp` | `terraform plan` |
| `tfv` | `terraform validate` |
| `tfs` | `terraform state` |
| `tft` | `terraform test` |
| `tfsh` | `terraform show` |
| `tfw` | `terraform workspace` |
| `tfwl` | `terraform workspace list` |
| `tfws` | `terraform workspace select` |
| Alias | Command |
| ------- | -------------------------------------- |
| `tf` | `terraform` |
| `tfa` | `terraform apply` |
| `tfaa` | `terraform apply -auto-approve` |
| `tfc` | `terraform console` |
| `tfd` | `terraform destroy` |
| `tfd!` | `terraform destroy -auto-approve` |
| `tff` | `terraform fmt` |
| `tffr` | `terraform fmt -recursive` |
| `tfi` | `terraform init` |
| `tfir` | `terraform init -reconfigure` |
| `tfiu` | `terraform init -upgrade` |
| `tfiur` | `terraform init -upgrade -reconfigure` |
| `tfo` | `terraform output` |
| `tfp` | `terraform plan` |
| `tfv` | `terraform validate` |
| `tfs` | `terraform state` |
| `tft` | `terraform test` |
| `tfsh` | `terraform show` |
| `tfw` | `terraform workspace` |
| `tfwl` | `terraform workspace list` |
| `tfws` | `terraform workspace select` |
## Prompt function

View file

@ -2,9 +2,9 @@ function tf_prompt_info() {
# dont show 'default' workspace in home dir
[[ "$PWD" != ~ ]] || return
# check if in terraform dir and file exists
[[ -d .terraform && -r .terraform/environment ]] || return
[[ -d "${TF_DATA_DIR:-.terraform}" && -r "${TF_DATA_DIR:-.terraform}/environment" ]] || return
local workspace="$(< .terraform/environment)"
local workspace="$(< "${TF_DATA_DIR:-.terraform}/environment")"
echo "${ZSH_THEME_TF_PROMPT_PREFIX-[}${workspace:gs/%/%%}${ZSH_THEME_TF_PROMPT_SUFFIX-]}"
}
@ -24,7 +24,9 @@ alias 'tfd!'='terraform destroy -auto-approve'
alias tff='terraform fmt'
alias tffr='terraform fmt -recursive'
alias tfi='terraform init'
alias tfir='terraform init -reconfigure'
alias tfiu='terraform init -upgrade'
alias tfiur='terraform init -upgrade -reconfigure'
alias tfo='terraform output'
alias tfp='terraform plan'
alias tfv='terraform validate'