mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-12-31 12:39:51 +00:00
Compare commits
17 Commits
ddec79ad43
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a79b37b954 | ||
|
|
0f45f82c0a | ||
|
|
129aeee6bc | ||
|
|
3a73094983 | ||
|
|
95de26572e | ||
|
|
945d89f7ae | ||
|
|
8a231b1930 | ||
|
|
475b18f39a | ||
|
|
d4a62a2715 | ||
|
|
b5c449e1eb | ||
|
|
7192af5239 | ||
|
|
1fee750c3b | ||
|
|
57781231bb | ||
|
|
a4e15fdb16 | ||
|
|
f84341c574 | ||
|
|
92aed2e936 | ||
|
|
72acd2ca90 |
2
.github/workflows/dependencies.yml
vendored
2
.github/workflows/dependencies.yml
vendored
@@ -13,7 +13,7 @@ jobs:
|
|||||||
contents: write # this is needed to push commits and branches
|
contents: write # this is needed to push commits and branches
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
|
|||||||
@@ -4,4 +4,4 @@ idna==3.11
|
|||||||
PyYAML==6.0.3
|
PyYAML==6.0.3
|
||||||
requests==2.32.5
|
requests==2.32.5
|
||||||
semver==3.0.4
|
semver==3.0.4
|
||||||
urllib3==2.6.0
|
urllib3==2.6.2
|
||||||
|
|||||||
4
.github/workflows/installer.yml
vendored
4
.github/workflows/installer.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
|||||||
- macos-latest
|
- macos-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
@@ -47,7 +47,7 @@ jobs:
|
|||||||
- test
|
- test
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
|
|||||||
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
@@ -24,7 +24,7 @@ jobs:
|
|||||||
if: github.repository == 'ohmyzsh/ohmyzsh'
|
if: github.repository == 'ohmyzsh/ohmyzsh'
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
|
|||||||
2
.github/workflows/project.yml
vendored
2
.github/workflows/project.yml
vendored
@@ -17,7 +17,7 @@ jobs:
|
|||||||
if: github.repository == 'ohmyzsh/ohmyzsh'
|
if: github.repository == 'ohmyzsh/ohmyzsh'
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
- name: Authenticate as @ohmyzsh
|
- name: Authenticate as @ohmyzsh
|
||||||
|
|||||||
6
.github/workflows/scorecard.yml
vendored
6
.github/workflows/scorecard.yml
vendored
@@ -36,7 +36,7 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Harden the runner (Audit all outbound calls)
|
- name: Harden the runner (Audit all outbound calls)
|
||||||
uses: step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
|
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||||
with:
|
with:
|
||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
@@ -53,13 +53,13 @@ jobs:
|
|||||||
publish_results: true
|
publish_results: true
|
||||||
|
|
||||||
- name: "Upload artifact"
|
- name: "Upload artifact"
|
||||||
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
|
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
|
||||||
with:
|
with:
|
||||||
name: SARIF file
|
name: SARIF file
|
||||||
path: results.sarif
|
path: results.sarif
|
||||||
retention-days: 5
|
retention-days: 5
|
||||||
|
|
||||||
- name: "Upload to code-scanning"
|
- name: "Upload to code-scanning"
|
||||||
uses: github/codeql-action/upload-sarif@cf1bb45a277cb3c205638b2cd5c984db1c46a412 # v4.31.7
|
uses: github/codeql-action/upload-sarif@5d4e8d1aca955e8d8589aabd499c5cae939e33c7 # v4.31.9
|
||||||
with:
|
with:
|
||||||
sarif_file: results.sarif
|
sarif_file: results.sarif
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ function detect-clipboard() {
|
|||||||
function clipcopy() { cat "${1:-/dev/stdin}" | termux-clipboard-set; }
|
function clipcopy() { cat "${1:-/dev/stdin}" | termux-clipboard-set; }
|
||||||
function clippaste() { termux-clipboard-get; }
|
function clippaste() { termux-clipboard-get; }
|
||||||
elif [ -n "${TMUX:-}" ] && (( ${+commands[tmux]} )); then
|
elif [ -n "${TMUX:-}" ] && (( ${+commands[tmux]} )); then
|
||||||
function clipcopy() { tmux load-buffer "${1:--}"; }
|
function clipcopy() { tmux load-buffer -w "${1:--}"; }
|
||||||
function clippaste() { tmux save-buffer -; }
|
function clippaste() { tmux save-buffer -; }
|
||||||
else
|
else
|
||||||
function _retry_clipboard_detection_or_fail() {
|
function _retry_clipboard_detection_or_fail() {
|
||||||
|
|||||||
@@ -117,7 +117,7 @@ function _omz_git_prompt_status() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# For each status prefix, do a regex comparison
|
# For each status prefix, do a regex comparison
|
||||||
for status_prefix in ${(k)prefix_constant_map}; do
|
for status_prefix in "${(@k)prefix_constant_map}"; do
|
||||||
local status_constant="${prefix_constant_map[$status_prefix]}"
|
local status_constant="${prefix_constant_map[$status_prefix]}"
|
||||||
local status_regex=$'(^|\n)'"$status_prefix"
|
local status_regex=$'(^|\n)'"$status_prefix"
|
||||||
|
|
||||||
|
|||||||
@@ -77,7 +77,15 @@ EOF
|
|||||||
(*.lzma) unlzma "$full_path" ;;
|
(*.lzma) unlzma "$full_path" ;;
|
||||||
(*.z) uncompress "$full_path" ;;
|
(*.z) uncompress "$full_path" ;;
|
||||||
(*.zip|*.war|*.jar|*.ear|*.sublime-package|*.ipa|*.ipsw|*.xpi|*.apk|*.aar|*.whl|*.vsix|*.crx|*.pk3|*.pk4) unzip "$full_path" ;;
|
(*.zip|*.war|*.jar|*.ear|*.sublime-package|*.ipa|*.ipsw|*.xpi|*.apk|*.aar|*.whl|*.vsix|*.crx|*.pk3|*.pk4) unzip "$full_path" ;;
|
||||||
(*.rar) unrar x -ad "$full_path" ;;
|
(*.rar)
|
||||||
|
if (( $+commands[unrar] )); then
|
||||||
|
unrar x -ad "$full_path"
|
||||||
|
elif (( $+commands[unar] )); then
|
||||||
|
unar -o . "$full_path"
|
||||||
|
else
|
||||||
|
echo "extract: cannot extract RAR files: install unrar or unar" >&2
|
||||||
|
success=1
|
||||||
|
fi ;;
|
||||||
(*.rpm)
|
(*.rpm)
|
||||||
rpm2cpio "$full_path" | cpio --quiet -id ;;
|
rpm2cpio "$full_path" | cpio --quiet -id ;;
|
||||||
(*.7z | *.7z.[0-9]* | *.pk7) 7za x "$full_path" ;;
|
(*.7z | *.7z.[0-9]* | *.pk7) 7za x "$full_path" ;;
|
||||||
|
|||||||
@@ -234,40 +234,26 @@ branch exists. We do this via the function `git_main_branch`.
|
|||||||
These are aliases that have been removed, renamed, or otherwise modified in a way that may, or may not,
|
These are aliases that have been removed, renamed, or otherwise modified in a way that may, or may not,
|
||||||
receive further support.
|
receive further support.
|
||||||
|
|
||||||
| Alias | Command | Modification |
|
| Alias | Command | Modification |
|
||||||
| :------- | :-------------------------------------------------------- | :-------------------------------------------------------- |
|
| :------- | :-------------------------------------------------------- | :-----------------------------------------------------|
|
||||||
| `gap` | `git add --patch` | New alias: `gapa`. |
|
| `gap` | `git add --patch` | New alias: `gapa` |
|
||||||
| `gcl` | `git config --list` | New alias: `gcf`. |
|
| `gcl` | `git config --list` | New alias: `gcf` |
|
||||||
| `gdc` | `git diff --cached` | New alias: `gdca`. |
|
| `gdt` | `git difftool` | No replacement |
|
||||||
| `gdt` | `git difftool` | No replacement. |
|
|
||||||
| `ggpull` | `git pull origin $(current_branch)` | New alias: `ggl`. (`ggpull` still exists for now though.) |
|
|
||||||
| `ggpur` | `git pull --rebase origin $(current_branch)` | New alias: `ggu`. (`ggpur` still exists for now though.) |
|
|
||||||
| `ggpush` | `git push origin $(current_branch)` | New alias: `ggp`. (`ggpush` still exists for now though.) |
|
|
||||||
| `gk` | `gitk --all --branches` | Now aliased to `gitk --all --branches`. |
|
|
||||||
| `glg` | `git log --stat --max-count=10` | Now aliased to `git log --stat --color`. |
|
|
||||||
| `glgg` | `git log --graph --max-count=10` | Now aliased to `git log --graph --color`. |
|
|
||||||
| `gwc` | `git whatchanged -p --abbrev-commit --pretty = medium` | New alias: `gwch`. |
|
|
||||||
| `gup` | `git pull --rebase` | now alias `gpr` |
|
|
||||||
| `gupv` | `git pull --rebase -v` | now alias `gprv` |
|
|
||||||
| `gupa` | `git pull --rebase --autostash` | now alias `gpra` |
|
|
||||||
| `gupav` | `git pull --rebase --autostash -v` | now alias `gprav` |
|
|
||||||
| `gupom` | `git pull --rebase origin $(git_main_branch)` | now alias `gprom` |
|
|
||||||
| `gupomi` | `git pull --rebase=interactive origin $(git_main_branch)` | now alias `gpromi` |
|
|
||||||
|
|
||||||
## Functions
|
## Functions
|
||||||
|
|
||||||
### Current
|
### Current
|
||||||
|
|
||||||
| Command | Description |
|
| Command | Description |
|
||||||
| :----------------------- | :-------------------------------------------------------------------------------------------------------------- |
|
| :----------------------- | :------------------------------------------------------------------------------------------------------------- |
|
||||||
| `current_branch` | Returns the name of the current branch. |
|
| `git_current_branch` | Returns the name of the current branch (Lives in `lib/git.zsh`) |
|
||||||
| `git_current_user_email` | Returns the `user.email` config value. (Lives in `lib/git.zsh`.) |
|
| `git_current_user_email` | Returns the `user.email` config value (Lives in `lib/git.zsh`) |
|
||||||
| `git_current_user_name` | Returns the `user.name` config value. (Lives in `lib/git.zsh`.) |
|
| `git_current_user_name` | Returns the `user.name` config value (Lives in `lib/git.zsh`) |
|
||||||
| `git_develop_branch` | Returns the name of the “development” branch: `dev`, `devel`, `development` if they exist, `develop` otherwise. |
|
| `git_develop_branch` | Returns the name of the “development” branch: `dev`, `devel`, `development` if they exist, `develop` otherwise |
|
||||||
| `git_main_branch` | Returns the name of the main branch: `main` if it exists, `master` otherwise. |
|
| `git_main_branch` | Returns the name of the main branch: `main` if it exists, `master` otherwise |
|
||||||
| `grename <old> <new>` | Renames branch `<old>` to `<new>`, including on the origin remote. |
|
| `grename <old> <new>` | Renames branch `<old>` to `<new>`, including on the origin remote |
|
||||||
| `gbda` | Deletes all merged branches |
|
| `gbda` | Deletes all merged branches |
|
||||||
| `gbds` | Deletes all squash-merged branches (**Note: performance degrades with number of branches**) |
|
| `gbds` | Deletes all squash-merged branches (**Note: performance degrades with number of branches**) |
|
||||||
|
|
||||||
### Work in Progress (WIP)
|
### Work in Progress (WIP)
|
||||||
|
|
||||||
@@ -287,4 +273,3 @@ Note that `gwip` and `gunwip` are aliases, but are also documented here to group
|
|||||||
|
|
||||||
| Command | Description | Reason |
|
| Command | Description | Reason |
|
||||||
| :------------------- | :-------------------------------------- | :--------------------------------------------------------------- |
|
| :------------------- | :-------------------------------------- | :--------------------------------------------------------------- |
|
||||||
| `current_repository` | Return the names of the current remotes | Didn't work properly. Use `git remote -v` instead (`grv` alias). |
|
|
||||||
|
|||||||
@@ -8,14 +8,6 @@ git_version="${${(As: :)$(git version 2>/dev/null)}[3]}"
|
|||||||
# (order should follow README)
|
# (order should follow README)
|
||||||
#
|
#
|
||||||
|
|
||||||
# The name of the current branch
|
|
||||||
# Back-compatibility wrapper for when this function was defined here in
|
|
||||||
# the plugin, before being pulled in to core lib/git.zsh as git_current_branch()
|
|
||||||
# to fix the core -> git plugin dependency.
|
|
||||||
function current_branch() {
|
|
||||||
git_current_branch
|
|
||||||
}
|
|
||||||
|
|
||||||
# Check for develop and similarly named branches
|
# Check for develop and similarly named branches
|
||||||
function git_develop_branch() {
|
function git_develop_branch() {
|
||||||
command git rev-parse --git-dir &>/dev/null || return
|
command git rev-parse --git-dir &>/dev/null || return
|
||||||
@@ -427,19 +419,13 @@ alias gke='\gitk --all $(git log --walk-reflogs --pretty=%h) &!'
|
|||||||
|
|
||||||
unset git_version
|
unset git_version
|
||||||
|
|
||||||
# Logic for adding warnings on deprecated aliases
|
# Logic for adding warnings on deprecated aliases or functions
|
||||||
local old_alias new_alias
|
local old_name new_name
|
||||||
for old_alias new_alias (
|
for old_name new_name (
|
||||||
# TODO(2023-10-19): remove deprecated `git pull --rebase` aliases
|
current_branch git_current_branch
|
||||||
gup gpr
|
|
||||||
gupv gprv
|
|
||||||
gupa gpra
|
|
||||||
gupav gprav
|
|
||||||
gupom gprom
|
|
||||||
gupomi gpromi
|
|
||||||
); do
|
); do
|
||||||
aliases[$old_alias]="
|
aliases[$old_name]="
|
||||||
print -Pu2 \"%F{yellow}[oh-my-zsh] '%F{red}${old_alias}%F{yellow}' is a deprecated alias, using '%F{green}${new_alias}%F{yellow}' instead.%f\"
|
print -Pu2 \"%F{yellow}[oh-my-zsh] '%F{red}${old_name}%F{yellow}' is deprecated, using '%F{green}${new_name}%F{yellow}' instead.%f\"
|
||||||
$new_alias"
|
$new_name"
|
||||||
done
|
done
|
||||||
unset old_alias new_alias
|
unset old_name new_name
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ plugins=(... kubectl)
|
|||||||
| k | `kubectl` | The kubectl command |
|
| k | `kubectl` | The kubectl command |
|
||||||
| kca | `kubectl --all-namespaces` | The kubectl command targeting all namespaces |
|
| kca | `kubectl --all-namespaces` | The kubectl command targeting all namespaces |
|
||||||
| kaf | `kubectl apply -f` | Apply a YML file |
|
| kaf | `kubectl apply -f` | Apply a YML file |
|
||||||
|
| kapk | `kubectl apply -k` | Apply a kustomization directory |
|
||||||
| keti | `kubectl exec -ti` | Drop into an interactive terminal on a container |
|
| keti | `kubectl exec -ti` | Drop into an interactive terminal on a container |
|
||||||
| | | **Manage configuration quickly to switch contexts between local, dev and staging** |
|
| | | **Manage configuration quickly to switch contexts between local, dev and staging** |
|
||||||
| kcuc | `kubectl config use-context` | Set the current-context in a kubeconfig file |
|
| kcuc | `kubectl config use-context` | Set the current-context in a kubeconfig file |
|
||||||
@@ -26,6 +27,7 @@ plugins=(... kubectl)
|
|||||||
| | | **General aliases** |
|
| | | **General aliases** |
|
||||||
| kdel | `kubectl delete` | Delete resources by filenames, stdin, resources and names, or by resources and label selector |
|
| kdel | `kubectl delete` | Delete resources by filenames, stdin, resources and names, or by resources and label selector |
|
||||||
| kdelf | `kubectl delete -f` | Delete a pod using the type and name specified in -f argument |
|
| kdelf | `kubectl delete -f` | Delete a pod using the type and name specified in -f argument |
|
||||||
|
| kdelk | `kubectl delete -k` | Delete all resources defined in a kustomization directory |
|
||||||
| kge | `kubectl get events --sort-by=".lastTimestamp"` | Get events (sorted by timestamp) |
|
| kge | `kubectl get events --sort-by=".lastTimestamp"` | Get events (sorted by timestamp) |
|
||||||
| kgew | `kubectl get events --watch --sort-by=".lastTimestamp"` | Get events and watch as they occur (sorted by timestamp) |
|
| kgew | `kubectl get events --watch --sort-by=".lastTimestamp"` | Get events and watch as they occur (sorted by timestamp) |
|
||||||
| | | **Pod management** |
|
| | | **Pod management** |
|
||||||
|
|||||||
@@ -21,6 +21,9 @@ alias kca='_kca(){ kubectl "$@" --all-namespaces; unset -f _kca; }; _kca'
|
|||||||
# Apply a YML file
|
# Apply a YML file
|
||||||
alias kaf='kubectl apply -f'
|
alias kaf='kubectl apply -f'
|
||||||
|
|
||||||
|
# Apply a kustomization directory
|
||||||
|
alias kapk='kubectl apply -k'
|
||||||
|
|
||||||
# Drop into an interactive terminal on a container
|
# Drop into an interactive terminal on a container
|
||||||
alias keti='kubectl exec -t -i'
|
alias keti='kubectl exec -t -i'
|
||||||
|
|
||||||
@@ -36,6 +39,7 @@ alias kcgc='kubectl config get-contexts'
|
|||||||
# General aliases
|
# General aliases
|
||||||
alias kdel='kubectl delete'
|
alias kdel='kubectl delete'
|
||||||
alias kdelf='kubectl delete -f'
|
alias kdelf='kubectl delete -f'
|
||||||
|
alias kdelk='kubectl delete -k'
|
||||||
alias kge='kubectl get events --sort-by=".lastTimestamp"'
|
alias kge='kubectl get events --sort-by=".lastTimestamp"'
|
||||||
alias kgew='kubectl get events --sort-by=".lastTimestamp" --watch'
|
alias kgew='kubectl get events --sort-by=".lastTimestamp" --watch'
|
||||||
|
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ plugins=(... opentofu)
|
|||||||
|--------|------------------------------|
|
|--------|------------------------------|
|
||||||
| `tt` | `tofu` |
|
| `tt` | `tofu` |
|
||||||
| `tta` | `tofu apply` |
|
| `tta` | `tofu apply` |
|
||||||
| `ttaa` | `tofu apply -auto-approve` |
|
| `tta!` | `tofu apply -auto-approve` |
|
||||||
| `ttc` | `tofu console` |
|
| `ttc` | `tofu console` |
|
||||||
| `ttd` | `tofu destroy` |
|
| `ttd` | `tofu destroy` |
|
||||||
| `ttd!` | `tofu destroy -auto-approve` |
|
| `ttd!` | `tofu destroy -auto-approve` |
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ function tofu_version_prompt_info() {
|
|||||||
|
|
||||||
alias tt='tofu'
|
alias tt='tofu'
|
||||||
alias tta='tofu apply'
|
alias tta='tofu apply'
|
||||||
alias ttaa='tofu apply -auto-approve'
|
alias tta!='tofu apply -auto-approve'
|
||||||
alias ttc='tofu console'
|
alias ttc='tofu console'
|
||||||
alias ttd='tofu destroy'
|
alias ttd='tofu destroy'
|
||||||
alias ttd!='tofu destroy -auto-approve'
|
alias ttd!='tofu destroy -auto-approve'
|
||||||
|
|||||||
@@ -16,13 +16,15 @@ plugins=(... terraform)
|
|||||||
## Aliases
|
## Aliases
|
||||||
|
|
||||||
| Alias | Command |
|
| Alias | Command |
|
||||||
| ------- | -------------------------------------- |
|
|---------|----------------------------------------|
|
||||||
| `tf` | `terraform` |
|
| `tf` | `terraform` |
|
||||||
| `tfa` | `terraform apply` |
|
| `tfa` | `terraform apply` |
|
||||||
| `tfaa` | `terraform apply -auto-approve` |
|
| `tfa!` | `terraform apply -auto-approve` |
|
||||||
|
| `tfap` | `terraform apply -parallelism=1` |
|
||||||
| `tfc` | `terraform console` |
|
| `tfc` | `terraform console` |
|
||||||
| `tfd` | `terraform destroy` |
|
| `tfd` | `terraform destroy` |
|
||||||
| `tfd!` | `terraform destroy -auto-approve` |
|
| `tfd!` | `terraform destroy -auto-approve` |
|
||||||
|
| `tfdp` | `terraform destroy -parallelism=1` |
|
||||||
| `tff` | `terraform fmt` |
|
| `tff` | `terraform fmt` |
|
||||||
| `tffr` | `terraform fmt -recursive` |
|
| `tffr` | `terraform fmt -recursive` |
|
||||||
| `tfi` | `terraform init` |
|
| `tfi` | `terraform init` |
|
||||||
|
|||||||
@@ -17,10 +17,12 @@ function tf_version_prompt_info() {
|
|||||||
|
|
||||||
alias tf='terraform'
|
alias tf='terraform'
|
||||||
alias tfa='terraform apply'
|
alias tfa='terraform apply'
|
||||||
alias tfaa='terraform apply -auto-approve'
|
alias tfa!='terraform apply -auto-approve'
|
||||||
|
alias tfap='terraform apply -parallelism=1'
|
||||||
alias tfc='terraform console'
|
alias tfc='terraform console'
|
||||||
alias tfd='terraform destroy'
|
alias tfd='terraform destroy'
|
||||||
alias 'tfd!'='terraform destroy -auto-approve'
|
alias tfd!='terraform destroy -auto-approve'
|
||||||
|
alias tfdp='terraform destroy -parallelism=1'
|
||||||
alias tff='terraform fmt'
|
alias tff='terraform fmt'
|
||||||
alias tffr='terraform fmt -recursive'
|
alias tffr='terraform fmt -recursive'
|
||||||
alias tfi='terraform init'
|
alias tfi='terraform init'
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ The plugin also supports the following:
|
|||||||
| `tkss` | tmux kill-session -t | Terminate named running tmux session |
|
| `tkss` | tmux kill-session -t | Terminate named running tmux session |
|
||||||
| `tksv` | tmux kill-server | Terminate all running tmux sessions |
|
| `tksv` | tmux kill-server | Terminate all running tmux sessions |
|
||||||
| `tl` | tmux list-sessions | Displays a list of running tmux sessions |
|
| `tl` | tmux list-sessions | Displays a list of running tmux sessions |
|
||||||
|
| `to` | tmux new-session -A -s | Create or attach to a named tmux session |
|
||||||
| `tmux` | `_zsh_tmux_plugin_run` | Start a new tmux session |
|
| `tmux` | `_zsh_tmux_plugin_run` | Start a new tmux session |
|
||||||
| `tmuxconf` | `$EDITOR $ZSH_TMUX_CONFIG` | Open .tmux.conf file with an editor |
|
| `tmuxconf` | `$EDITOR $ZSH_TMUX_CONFIG` | Open .tmux.conf file with an editor |
|
||||||
| `ts` | tmux new-session -s | Create a new named tmux session |
|
| `ts` | tmux new-session -s | Create a new named tmux session |
|
||||||
|
|||||||
@@ -81,6 +81,7 @@ alias tmuxconf='$EDITOR $ZSH_TMUX_CONFIG'
|
|||||||
|
|
||||||
_build_tmux_alias "ta" "attach" "-t"
|
_build_tmux_alias "ta" "attach" "-t"
|
||||||
_build_tmux_alias "tad" "attach -d" "-t"
|
_build_tmux_alias "tad" "attach -d" "-t"
|
||||||
|
_build_tmux_alias "to" "new-session -A" "-s"
|
||||||
_build_tmux_alias "ts" "new-session" "-s"
|
_build_tmux_alias "ts" "new-session" "-s"
|
||||||
_build_tmux_alias "tkss" "kill-session" "-t"
|
_build_tmux_alias "tkss" "kill-session" "-t"
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
# uv plugin
|
# uv plugin
|
||||||
|
|
||||||
This plugin automatically installs [uv](https://github.com/astral-sh/uv)'s completions for you, and keeps them up to date. It also adds convenient aliases for common usage.
|
This plugin automatically installs [uv](https://github.com/astral-sh/uv)'s completions for you,
|
||||||
|
and keeps them up to date. It also adds convenient aliases for common usage.
|
||||||
|
|
||||||
To use it, add `uv` to the plugins array in your zshrc file:
|
To use it, add `uv` to the plugins array in your zshrc file:
|
||||||
|
|
||||||
@@ -10,20 +11,26 @@ plugins=(... uv)
|
|||||||
|
|
||||||
## Aliases
|
## Aliases
|
||||||
|
|
||||||
| Alias | Command | Description |
|
| Alias | Command | Description |
|
||||||
|:----- |------------------------------------------------------------------------ |:-------------------------------------------------------------------- |
|
| :---- | ---------------------------------------------------------------------------------------- | :-------------------------------------------------------------------- |
|
||||||
| uva | `uv add` | Add packages to the project |
|
| uva | `uv add` | Add packages to the project |
|
||||||
| uvexp | `uv export --format requirements-txt --no-hashes --output-file requirements.txt --quiet` | Export the lock file to `requirements.txt` |
|
| uvexp | `uv export --format requirements-txt --no-hashes --output-file requirements.txt --quiet` | Export the lock file to `requirements.txt` |
|
||||||
| uvl | `uv lock` | Lock the dependencies |
|
| uvi | `uv init` | Initialize a new project in current workspace and environment. |
|
||||||
| uvlr | `uv lock --refresh` | Rebuild the lock file without upgrading dependencies |
|
| uvinw | `uv init --no-workspace` | Initialize a new project in a new workspace and environment |
|
||||||
| uvlu | `uv lock --upgrade` | Lock the dependencies to the newest compatible versions |
|
| uvl | `uv lock` | Lock the dependencies |
|
||||||
| uvp | `uv pip` | Manage pip packages |
|
| uvlr | `uv lock --refresh` | Rebuild the lock file without upgrading dependencies |
|
||||||
| uvpy | `uv python` | Manage Python installs |
|
| uvlu | `uv lock --upgrade` | Lock the dependencies to the newest compatible versions |
|
||||||
| uvpp | `uv python pin` | Pin the current project to use a specific Python version |
|
| uvp | `uv pip` | Manage pip packages |
|
||||||
| uvr | `uv run` | Run commands within the project's environment |
|
| uvpi | `uv python install` | Install a specific version of python |
|
||||||
| uvrm | `uv remove` | Remove packages from the project |
|
| uvpl | `uv python list` | Lists all python version installed |
|
||||||
| uvs | `uv sync` | Sync the environment with the lock file |
|
| uvpp | `uv python pin` | Pin the current project to use a specific Python version |
|
||||||
| uvsr | `uv sync --refresh` | "Force" sync the environment with the lock file (ignore cache) |
|
| uvpu | `uv python uninstall` | Remove a specific version of python |
|
||||||
| uvsu | `uv sync --upgrade` | Sync the environment, allowing upgrades and ignoring the lock file |
|
| uvpy | `uv python` | Manage Python installs |
|
||||||
| uvup | `uv self update` | Update the UV tool to the latest version |
|
| uvr | `uv run` | Run commands within the project's environment |
|
||||||
| uvv | `uv venv` | Manage virtual environments |
|
| uvrm | `uv remove` | Remove packages from the project |
|
||||||
|
| uvs | `uv sync` | Sync the environment with the lock file |
|
||||||
|
| uvsr | `uv sync --refresh` | "Force" sync the environment with the lock file (ignore cache) |
|
||||||
|
| uvsu | `uv sync --upgrade` | Sync the environment, allowing upgrades and ignoring the lock file |
|
||||||
|
| uvtr | `uv tree` | Displays the full dependency tree for the current project environment |
|
||||||
|
| uvup | `uv self update` | Update the UV tool to the latest version |
|
||||||
|
| uvv | `uv venv` | Manage virtual environments |
|
||||||
|
|||||||
@@ -7,10 +7,15 @@ alias uv="noglob uv"
|
|||||||
|
|
||||||
alias uva='uv add'
|
alias uva='uv add'
|
||||||
alias uvexp='uv export --format requirements-txt --no-hashes --output-file requirements.txt --quiet'
|
alias uvexp='uv export --format requirements-txt --no-hashes --output-file requirements.txt --quiet'
|
||||||
|
alias uvi='uv init'
|
||||||
|
alias uvinw='uv init --no-workspace'
|
||||||
alias uvl='uv lock'
|
alias uvl='uv lock'
|
||||||
alias uvlr='uv lock --refresh'
|
alias uvlr='uv lock --refresh'
|
||||||
alias uvlu='uv lock --upgrade'
|
alias uvlu='uv lock --upgrade'
|
||||||
alias uvp='uv pip'
|
alias uvp='uv pip'
|
||||||
|
alias uvpi='uv python install'
|
||||||
|
alias uvpl='uv python list'
|
||||||
|
alias uvpu='uv python uninstall'
|
||||||
alias uvpy='uv python'
|
alias uvpy='uv python'
|
||||||
alias uvpp='uv python pin'
|
alias uvpp='uv python pin'
|
||||||
alias uvr='uv run'
|
alias uvr='uv run'
|
||||||
@@ -18,6 +23,7 @@ alias uvrm='uv remove'
|
|||||||
alias uvs='uv sync'
|
alias uvs='uv sync'
|
||||||
alias uvsr='uv sync --refresh'
|
alias uvsr='uv sync --refresh'
|
||||||
alias uvsu='uv sync --upgrade'
|
alias uvsu='uv sync --upgrade'
|
||||||
|
alias uvtr='uv tree'
|
||||||
alias uvup='uv self update'
|
alias uvup='uv self update'
|
||||||
alias uvv='uv venv'
|
alias uvv='uv venv'
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user