summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authortheredcmdcraft <57496807+theredcmdcraft@users.noreply.github.com>2024-05-26 21:53:03 +0200
committerGitHub <noreply@github.com>2024-05-26 12:53:03 -0700
commit5e59d21e5465ec0694441f41ff0acf1ddf4de187 (patch)
tree51c2ffab2f9b172ebd153c2c04157b5f9a770222 /plugins
parent1b29fd3a460e43d4a7581d6a6a7e5a1877a39068 (diff)
downloadzsh-5e59d21e5465ec0694441f41ff0acf1ddf4de187.tar.gz
zsh-5e59d21e5465ec0694441f41ff0acf1ddf4de187.tar.bz2
zsh-5e59d21e5465ec0694441f41ff0acf1ddf4de187.zip
Add Support for Tabby Terminal in Macos Plugin (#12451)
* Added Support for Tabby in Macos-Plugin * Update README.md Added Supported Terminal List * chore(macos): Update README to link to terminals Linking to the supported terminals, moving reference to the original author to the Acknowledgements section --------- Co-authored-by: Robby Russell <robby@planetargon.com>
Diffstat (limited to 'plugins')
-rw-r--r--plugins/macos/README.md10
-rw-r--r--plugins/macos/macos.plugin.zsh19
2 files changed, 27 insertions, 2 deletions
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 <<EOF
+ tell application "System Events"
+ tell process "Tabby" to keystroke "t" using command down
+ end tell
+EOF
else
echo "$0: unsupported terminal app: $the_app" >&2
return 1
@@ -127,6 +134,12 @@ EOF
keystroke "${command} \n"
end tell
EOF
+ elif [[ "$the_app" == 'Tabby' ]]; then
+ osascript >/dev/null <<EOF
+ tell application "System Events"
+ tell process "Tabby" to keystroke "D" using command down
+ end tell
+EOF
else
echo "$0: unsupported terminal app: $the_app" >&2
return 1
@@ -176,6 +189,12 @@ EOF
keystroke "${command} \n"
end tell
EOF
+ elif [[ "$the_app" == 'Tabby' ]]; then
+ osascript >/dev/null <<EOF
+ tell application "System Events"
+ tell process "Tabby" to keystroke "d" using command down
+ end tell
+EOF
else
echo "$0: unsupported terminal app: $the_app" >&2
return 1