diff --git a/README.md b/README.md
index dea36fda7..2d873c514 100644
--- a/README.md
+++ b/README.md
@@ -89,7 +89,7 @@ Oh My Zsh is installed by running one of the following commands in your terminal
| **wget** | `sh -c "$(wget -O- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"` |
| **fetch** | `sh -c "$(fetch -o - https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"` |
-Alternatively, the installer is also mirrored outside GitHub. Using this URL instead may be required if you're in a country like India or China, that blocks `raw.githubusercontent.com`:
+Alternatively, the installer is also mirrored outside GitHub. Using this URL instead may be required if you're in a country like China or India (for certain ISPs), that blocks `raw.githubusercontent.com`:
| Method | Command |
| :-------- | :------------------------------------------------------------------------------------------------ |
@@ -235,7 +235,7 @@ If you're in China, India, or another country that blocks `raw.githubusercontent
#### Installing From A Forked Repository
-The install script also accepts these variables to allow installation of a different repository:
+The install script also accepts these variables to allow the installation of a different repository:
- `REPO` (default: `ohmyzsh/ohmyzsh`): this takes the form of `owner/repository`. If you set
this variable, the installer will look for a repository at `https://github.com/{owner}/{repository}`.
@@ -309,7 +309,7 @@ If you would like to override the functionality of a plugin distributed with Oh
-The default behaviour in Oh My Zsh is to use BSD `ls` in macOS and freeBSD systems. If GNU `ls` is installed
+The default behaviour in Oh My Zsh is to use BSD `ls` in macOS and FreeBSD systems. If GNU `ls` is installed
(as `gls` command), you can choose to use it instead. To do it, you can use zstyle-based config before
sourcing `oh-my-zsh.sh`:
@@ -342,7 +342,7 @@ zstyle ':omz:plugins:*' aliases no
zstyle ':omz:plugins:git' aliases no
```
-You can combine these in other ways taking into account that more specific scopes takes precedence:
+You can combine these in other ways taking into account that more specific scopes take precedence:
```sh
# Skip all plugin aliases, except for the git plugin
@@ -365,7 +365,7 @@ zstyle ':omz:lib:directories' aliases no
### Disable async git prompt
Async prompt functions are an experimental feature (included on April 3, 2024) that allows Oh My Zsh to render prompt information
-asyncronously. This can improve prompt rendering performance, but it might not work well with some setups. We hope that's not an
+asynchronously. This can improve prompt rendering performance, but it might not work well with some setups. We hope that's not an
issue, but if you're seeing problems with this new feature, you can turn it off by setting the following in your .zshrc file,
before Oh My Zsh is sourced:
diff --git a/plugins/bgnotify/bgnotify.plugin.zsh b/plugins/bgnotify/bgnotify.plugin.zsh
index 0e3f2c640..7de6f9a91 100644
--- a/plugins/bgnotify/bgnotify.plugin.zsh
+++ b/plugins/bgnotify/bgnotify.plugin.zsh
@@ -117,7 +117,7 @@ function bgnotify {
local icon="$3"
if (( ${+commands[terminal-notifier]} )); then # macOS
local term_id=$(bgnotify_programid)
- terminal-notifier -message "$message" -title "$title" ${=icon:+-appIcon "$icon"} ${=term_id:+-activate "$term_id" -sender "$term_id"} &>/dev/null
+ terminal-notifier -message "$message" -title "$title" ${=icon:+-appIcon "$icon"} ${=term_id:+-activate "$term_id"} &>/dev/null
elif (( ${+commands[growlnotify]} )); then # macOS growl
growlnotify -m "$title" "$message"
elif (( ${+commands[notify-send]} )); then
diff --git a/plugins/eza/README.md b/plugins/eza/README.md
index 5de935c2c..6fc113eba 100644
--- a/plugins/eza/README.md
+++ b/plugins/eza/README.md
@@ -55,6 +55,16 @@ If `yes` (default), always add `-g` flag to show the group ownership.
Default: `yes`
+### `icons`
+
+```zsh
+zstyle ':omz:plugins:eza' 'icons' yes|no
+```
+
+If `yes`, sets the `--icons` option of `eza`, adding icons for files and folders.
+
+Default: `no`
+
### `size-prefix`
```zsh
diff --git a/plugins/eza/eza.plugin.zsh b/plugins/eza/eza.plugin.zsh
index 6d7f720bd..79f5a0f71 100644
--- a/plugins/eza/eza.plugin.zsh
+++ b/plugins/eza/eza.plugin.zsh
@@ -31,6 +31,9 @@ function _configure_eza() {
if zstyle -t ':omz:plugins:eza' 'git-status'; then
_EZA_TAIL+=("--git")
fi
+ if zstyle -t ':omz:plugins:eza' 'icons'; then
+ _EZA_TAIL+=("--icons")
+ fi
zstyle -s ':omz:plugins:eza' 'time-style' _val
if [[ $_val ]]; then
_EZA_TAIL+=("--time-style='$_val'")
diff --git a/plugins/git/git.plugin.zsh b/plugins/git/git.plugin.zsh
index c48e365b5..1e65a7acc 100644
--- a/plugins/git/git.plugin.zsh
+++ b/plugins/git/git.plugin.zsh
@@ -35,7 +35,7 @@ function git_develop_branch() {
function git_main_branch() {
command git rev-parse --git-dir &>/dev/null || return
local ref
- for ref in refs/{heads,remotes/{origin,upstream}}/{main,trunk,mainline,default,master}; do
+ for ref in refs/{heads,remotes/{origin,upstream}}/{main,trunk,mainline,default,stable,master}; do
if command git show-ref -q --verify $ref; then
echo ${ref:t}
return 0
diff --git a/plugins/golang/README.md b/plugins/golang/README.md
index 128cc7fbb..80f8cf3b5 100644
--- a/plugins/golang/README.md
+++ b/plugins/golang/README.md
@@ -25,6 +25,7 @@ plugins=(... golang)
| goi | `go install` | Compiles and installs packages to $GOPATH |
| gol | `go list` | Lists Go packages |
| gom | `go mod` | Access to operations on modules |
+| gomt | `go mod tidy` | Tidies up the go.mod file |
| gopa | `cd $GOPATH` | Takes you to `$GOPATH` |
| gopb | `cd $GOPATH/bin` | Takes you to `$GOPATH/bin` |
| gops | `cd $GOPATH/src` | Takes you to `$GOPATH/src` |
diff --git a/plugins/golang/golang.plugin.zsh b/plugins/golang/golang.plugin.zsh
index 45ccd3a1c..dc4d91845 100644
--- a/plugins/golang/golang.plugin.zsh
+++ b/plugins/golang/golang.plugin.zsh
@@ -22,6 +22,7 @@ alias goga='go get ./...'
alias goi='go install'
alias gol='go list'
alias gom='go mod'
+alias gomt='go mod tidy'
alias gopa='cd $GOPATH'
alias gopb='cd $GOPATH/bin'
alias gops='cd $GOPATH/src'
diff --git a/plugins/kitty/README.md b/plugins/kitty/README.md
new file mode 100644
index 000000000..ec9e375de
--- /dev/null
+++ b/plugins/kitty/README.md
@@ -0,0 +1,23 @@
+# Kitty plugin
+
+This plugin adds a few aliases and functions that are useful for users of the [Kitty](https://sw.kovidgoyal.net/kitty/) terminal.
+
+To use it, add _kitty_ to the plugins array of your zshrc file:
+```
+plugins=(... kitty)
+```
+
+## Plugin commands
+
+* `kssh`
+ Runs a kitten ssh session that ensures your terminfo settings are copied
+ correctly to the remote hose.
+* `kssh-slow`
+ A slower form of `kssh` that should always work. Use this if `kssh` fails
+ to set terminfo correctly for you on the remote host.
+* `kitty-theme`
+ Browse and change the theme of your Kitty terminal.
+
+## Contributors
+
+- [Ian Chesal](https://github.com/ianchesal)
diff --git a/plugins/kitty/kitty.plugin.zsh b/plugins/kitty/kitty.plugin.zsh
new file mode 100644
index 000000000..1094236a7
--- /dev/null
+++ b/plugins/kitty/kitty.plugin.zsh
@@ -0,0 +1,16 @@
+#####################################################
+# Kitty plugin for oh-my-zsh #
+#####################################################
+
+if [[ "$TERM" == 'xterm-kitty' ]]; then
+ ## kssh
+ # Use this when your terminfo isn't recognized on remote hosts.
+ # See: https://sw.kovidgoyal.net/kitty/faq/#i-get-errors-about-the-terminal-being-unknown-or-opening-the-terminal-failing-when-sshing-into-a-different-computer
+ alias kssh="kitty +kitten ssh"
+ compdef kssh='ssh'
+ # Use this if kssh fails
+ alias kssh-slow="infocmp -a xterm-kitty | ssh myserver tic -x -o \~/.terminfo /dev/stdin"
+
+ # Change the colour theme
+ alias kitty-theme="kitty +kitten themes"
+fi
diff --git a/plugins/kubectl/kubectl.plugin.zsh b/plugins/kubectl/kubectl.plugin.zsh
index 0dd4e691a..a96e409c6 100644
--- a/plugins/kubectl/kubectl.plugin.zsh
+++ b/plugins/kubectl/kubectl.plugin.zsh
@@ -180,13 +180,11 @@ alias kej='kubectl edit job'
alias kdj='kubectl describe job'
alias kdelj='kubectl delete job'
-# Only run if the user actually has kubectl installed
-if (( ${+_comps[kubectl]} )); then
- function kj() { kubectl "$@" -o json | jq; }
- function kjx() { kubectl "$@" -o json | fx; }
- function ky() { kubectl "$@" -o yaml | yh; }
-
- compdef kj=kubectl
- compdef kjx=kubectl
- compdef ky=kubectl
+function kj() { kubectl "$@" -o json | jq; }
+function kjx() { kubectl "$@" -o json | fx; }
+function ky() { kubectl "$@" -o yaml | yh; }
+if (( ${+functions[compdef]} )); then
+ compdef _kubectl kj
+ compdef _kubectl kjx
+ compdef _kubectl ky
fi
diff --git a/plugins/macos/README.md b/plugins/macos/README.md
index 2c52ec8a7..8245e211f 100644
--- a/plugins/macos/README.md
+++ b/plugins/macos/README.md
@@ -8,7 +8,11 @@ To start using it, add the `macos` plugin to your plugins array in `~/.zshrc`:
plugins=(... macos)
```
-Original author: [Sorin Ionescu](https://github.com/sorin-ionescu)
+## Supported Terminals
+- [iTerm](https://iterm.sourceforge.net/)
+- [iTerm2](https://iterm2.com/)
+- [Hyper](https://hyper.is/)
+- [Tabby](https://tabby.sh/)
## Commands
@@ -37,7 +41,9 @@ Original author: [Sorin Ionescu](https://github.com/sorin-ionescu)
## Acknowledgements
-This application makes use of the following third party scripts:
+Original author: [Sorin Ionescu](https://github.com/sorin-ionescu)
+
+This application makes use of the following third-party scripts:
[shpotify](https://github.com/hnarayanan/shpotify)
diff --git a/plugins/macos/macos.plugin.zsh b/plugins/macos/macos.plugin.zsh
index 2702a1901..b951a289f 100644
--- a/plugins/macos/macos.plugin.zsh
+++ b/plugins/macos/macos.plugin.zsh
@@ -79,6 +79,13 @@ EOF
key code 36 #(presses enter)
end tell
EOF
+
+ elif [[ "$the_app" == 'Tabby' ]]; then
+ osascript >/dev/null <&2
return 1
@@ -126,6 +133,12 @@ EOF
delay 1
keystroke "${command} \n"
end tell
+EOF
+ elif [[ "$the_app" == 'Tabby' ]]; then
+ osascript >/dev/null <&2
@@ -175,6 +188,12 @@ EOF
delay 1
keystroke "${command} \n"
end tell
+EOF
+ elif [[ "$the_app" == 'Tabby' ]]; then
+ osascript >/dev/null <&2
diff --git a/plugins/pass/_pass b/plugins/pass/_pass
index d911e122f..c66d99318 100644
--- a/plugins/pass/_pass
+++ b/plugins/pass/_pass
@@ -20,6 +20,8 @@
_pass () {
local cmd
+ local rootcontext
+ rootcontext=$curcontext
if (( CURRENT > 2)); then
cmd=${words[2]}
# Set the context for the subcommand.
@@ -123,8 +125,9 @@ _pass_cmd_show () {
_pass_complete_entries_helper () {
local IFS=$'\n'
local prefix
- zstyle -s ":completion:${curcontext}:" prefix prefix || prefix="${PASSWORD_STORE_DIR:-$HOME/.password-store}"
- _values -C 'passwords' ${$(find -L "$prefix" \( -name .git -o -name .gpg-id \) -prune -o $@ -print 2>/dev/null | sed -e "s#${prefix}/\{0,1\}##" -e 's#\.gpg##' -e 's#\\#\\\\#g' -e 's#:#\\:#g' | sort):-""}
+ zstyle -s ":completion:${rootcontext}:" prefix prefix ||
+prefix="${PASSWORD_STORE_DIR:-$HOME/.password-store}"
+ _values -C 'passwords' ${$(find -L "$prefix" \( -name .git -o -name .gpg-id \) -prune -o $@ -print 2>/dev/null | sed -e "s#${prefix}/\{0,1\}##" -e 's#\.gpg##' -e 's#\\#\\\\#g' -e 's#:#\\:#g' | sort):-""}
}
_pass_complete_entries_with_subdirs () {
diff --git a/plugins/stripe/README.md b/plugins/stripe/README.md
index 9f0f32bc2..7e7944d63 100644
--- a/plugins/stripe/README.md
+++ b/plugins/stripe/README.md
@@ -1,4 +1,4 @@
-# Struoe
+# Stripe
This plugin provides completion for the [Stripe CLI](https://stripe.com/docs/stripe-cli).
diff --git a/plugins/tmux/tmux.plugin.zsh b/plugins/tmux/tmux.plugin.zsh
index f65598358..399de1ccc 100644
--- a/plugins/tmux/tmux.plugin.zsh
+++ b/plugins/tmux/tmux.plugin.zsh
@@ -57,6 +57,19 @@ function _build_tmux_alias {
tmux $2 $3 \"\$@\"
fi
}"
+
+ local f s
+ f="_omz_tmux_alias_${1}"
+ s=(${(z)2})
+
+ eval "function ${f}() {
+ shift words;
+ words=(tmux ${@:2} \$words);
+ ((CURRENT+=${#s[@]}+1))
+ _tmux
+ }"
+
+ compdef "$f" "$1"
}
alias tksv='tmux kill-server'
diff --git a/plugins/yarn/README.md b/plugins/yarn/README.md
index 5c7c7f323..f1d089b1f 100644
--- a/plugins/yarn/README.md
+++ b/plugins/yarn/README.md
@@ -1,7 +1,7 @@
# Yarn plugin
-This plugin adds completion for the [Yarn package manager](https://yarnpkg.com/en/),
-as well as some aliases for common Yarn commands.
+This plugin adds completion for the [Yarn package manager](https://yarnpkg.com/en/), as well as some aliases
+for common Yarn commands.
To use it, add `yarn` to the plugins array in your zshrc file:
@@ -11,48 +11,64 @@ plugins=(... yarn)
## Global scripts directory
-It also adds `yarn` global scripts dir (commonly `~/.yarn/bin`) to the `$PATH`.
-To disable this feature, set the following style in your `.zshrc`:
+It also adds `yarn` global scripts dir (commonly `~/.yarn/bin`) to the `$PATH`. To disable this feature, set
+the following style in your `.zshrc`:
```zsh
zstyle ':omz:plugins:yarn' global-path no
```
+## Yarn Berry
+
+If you are using Yarn berry (a.k.a. Yarn version 2 or higher) as your global Yarn version you should configure
+this plugin to configure its aliases accordingly, set the following style in your `.zshrc`:
+
+```zsh
+zstyle ':omz:plugins:yarn' berry yes
+```
+
## Aliases
-| Alias | Command | Description |
-| ----- | ----------------------------------------- | ----------------------------------------------------------------------------- |
-| y | `yarn` | The Yarn command |
-| ya | `yarn add` | Install a package in dependencies (`package.json`) |
-| yad | `yarn add --dev` | Install a package in devDependencies (`package.json`) |
-| yap | `yarn add --peer` | Install a package in peerDependencies (`package.json`) |
-| yb | `yarn build` | Run the build script defined in `package.json` |
-| ycc | `yarn cache clean` | Clean yarn's global cache of packages |
-| yd | `yarn dev` | Run the dev script defined in `package.json` |
-| yf | `yarn format` | Run the dev script defined in `package.json` |
-| yga | `yarn global add` | Install packages globally on your operating system |
-| ygls | `yarn global list` | Lists global installed packages |
-| ygrm | `yarn global remove` | Remove global installed packages from your OS |
-| ygu | `yarn global upgrade` | Upgrade packages installed globally to their latest version |
-| yh | `yarn help` | Show help for a yarn command |
-| yi | `yarn init` | Interactively creates or updates a package.json file |
-| yin | `yarn install` | Install dependencies defined in `package.json` |
-| yln | `yarn lint` | Run the lint script defined in `package.json` |
-| ylnf | `yarn lint --fix` | Run the lint script defined in `package.json`to automatically fix problems |
-| yls | `yarn list` | List installed packages |
-| yout | `yarn outdated` | Check for outdated package dependencies |
-| yp | `yarn pack` | Create a compressed gzip archive of package dependencies |
-| yrm | `yarn remove` | Remove installed packages |
-| yrun | `yarn run` | Run a defined package script |
-| ys | `yarn serve` | Start the dev server |
-| yst | `yarn start` | Run the start script defined in `package.json` |
-| yt | `yarn test` | Run the test script defined in `package.json` |
-| ytc | `yarn test --coverage` | Run the test script defined in `package.json` with coverage |
-| yuc | `yarn global upgrade && yarn cache clean` | Upgrade global packages and clean yarn's global cache |
-| yui | `yarn upgrade-interactive` | Prompt for which outdated packages to upgrade |
-| yuil | `yarn upgrade-interactive --latest` | Prompt for which outdated packages to upgrade to the latest available version |
-| yup | `yarn upgrade` | Upgrade packages to their latest version |
-| yv | `yarn version` | Update the version of your package |
-| yw | `yarn workspace` | Run a command within a single workspace. |
-| yws | `yarn workspaces` | Run a command within all defined workspaces. |
-| yy | `yarn why` | Show why a package has been installed, detailing which other packages depend on it |
+- Aliases marked with `*` are only available when using Yarn v1 (non-berry)
+- Aliases marked with `b` are only available when using Yarn berry
+
+| Alias | Command | Description |
+| ------------------ | ----------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |
+| y | `yarn` | The Yarn command |
+| ya | `yarn add` | Install a package in dependencies (`package.json`) |
+| yad | `yarn add --dev` | Install a package in devDependencies (`package.json`) |
+| yap | `yarn add --peer` | Install a package in peerDependencies (`package.json`) |
+| yb | `yarn build` | Run the build script defined in `package.json` |
+| ycc | `yarn cache clean` | Clean yarn's global cache of packages |
+| yd | `yarn dev` | Run the dev script defined in `package.json` |
+| yf | `yarn format` | Run the dev script defined in `package.json` |
+| yh | `yarn help` | Show help for a yarn command |
+| yi | `yarn init` | Interactively creates or updates a package.json file |
+| yin | `yarn install` | Install dependencies defined in `package.json` |
+| yln | `yarn lint` | Run the lint script defined in `package.json` |
+| ylnf | `yarn lint --fix` | Run the lint script defined in `package.json`to automatically fix problems |
+| yp | `yarn pack` | Create a compressed gzip archive of package dependencies |
+| yrm | `yarn remove` | Remove installed packages |
+| yrun | `yarn run` | Run a defined package script |
+| ys | `yarn serve` | Start the dev server |
+| yst | `yarn start` | Run the start script defined in `package.json` |
+| yt | `yarn test` | Run the test script defined in `package.json` |
+| ytc | `yarn test --coverage` | Run the test script defined in `package.json` with coverage |
+| yui | `yarn upgrade-interactive` | Prompt for which outdated packages to upgrade |
+| yuil | `yarn upgrade-interactive --latest` (or see `yui` when using [yarn berry](#yarn-berry)) | Prompt for which outdated packages to upgrade to the latest available version |
+| yii | `yarn install --frozen-lockfile` (or `yarn install --immutable` when using [yarn berry](#yarn-berry)) | Install dependencies and abort if the lockfile was to be modified |
+| yifl | `yii` | Install dependencies and abort if the lockfile was to be modified |
+| yup | `yarn upgrade` | Upgrade packages to their latest version |
+| yv | `yarn version` | Update the version of your package |
+| yw | `yarn workspace` | Run a command within a single workspace. |
+| yws | `yarn workspaces` | Run a command within all defined workspaces. |
+| yy | `yarn why` | Show why a package has been installed, detailing which other packages depend on it |
+| yga`*` | `yarn global add` | Install packages globally on your operating system |
+| ygls`*` | `yarn global list` | Lists global installed packages |
+| ygrm`*` | `yarn global remove` | Remove global installed packages from your OS |
+| ygu`*` | `yarn global upgrade` | Upgrade packages installed globally to their latest version |
+| yls`*` | `yarn list` | List installed packages |
+| yout`*` | `yarn outdated` | Check for outdated package dependencies |
+| yuca`*` | `yarn global upgrade && yarn cache clean` | Upgrade global packages and clean yarn's global cache |
+| ydlx`b` | `yarn dlx` | Run a package in a temporary environment. |
+| yn`b` | `yarn node` | Run node with the hook already setup. |
diff --git a/plugins/yarn/yarn.plugin.zsh b/plugins/yarn/yarn.plugin.zsh
index 157044d71..5dd329698 100644
--- a/plugins/yarn/yarn.plugin.zsh
+++ b/plugins/yarn/yarn.plugin.zsh
@@ -18,17 +18,11 @@ alias yb="yarn build"
alias ycc="yarn cache clean"
alias yd="yarn dev"
alias yf="yarn format"
-alias yga="yarn global add"
-alias ygls="yarn global list"
-alias ygrm="yarn global remove"
-alias ygu="yarn global upgrade"
alias yh="yarn help"
alias yi="yarn init"
alias yin="yarn install"
alias yln="yarn lint"
alias ylnf="yarn lint --fix"
-alias yls="yarn list"
-alias yout="yarn outdated"
alias yp="yarn pack"
alias yrm="yarn remove"
alias yrun="yarn run"
@@ -36,11 +30,35 @@ alias ys="yarn serve"
alias yst="yarn start"
alias yt="yarn test"
alias ytc="yarn test --coverage"
-alias yuc="yarn global upgrade && yarn cache clean"
alias yui="yarn upgrade-interactive"
-alias yuil="yarn upgrade-interactive --latest"
alias yup="yarn upgrade"
alias yv="yarn version"
alias yw="yarn workspace"
alias yws="yarn workspaces"
alias yy="yarn why"
+
+# Commands that are specific to the yarn version being used
+if zstyle -t ':omz:plugins:yarn' berry; then
+ # aliases that differ
+ alias yuil='yui' # --latest flag was removed in yarn berry
+ alias yii='yarn install --immutable'
+ alias yifl='yarn install --immutable'
+
+ # unique aliases
+ alias ydlx="yarn dlx"
+ alias yn="yarn node"
+else
+ # aliases that differ
+ alias yuil='yarn upgrade-interactive --latest'
+ alias yii='yarn install --frozen-lockfile'
+ alias yifl='yarn install --frozen-lockfile'
+
+ # unique aliases
+ alias yga="yarn global add"
+ alias ygls="yarn global list"
+ alias ygrm="yarn global remove"
+ alias ygu="yarn global upgrade"
+ alias yls="yarn list"
+ alias yout="yarn outdated"
+ alias yuca="yarn global upgrade && yarn cache clean"
+fi