refactor kitty,alacritty,warp startup scripts to same implementation
parent
d22f69429d
commit
cf8baeade0
|
@ -7,7 +7,7 @@ start_terminal_and_run_tmux() {
|
||||||
osascript <<-EOF
|
osascript <<-EOF
|
||||||
tell application "alacritty"
|
tell application "alacritty"
|
||||||
activate
|
activate
|
||||||
delay 0.5
|
delay 1
|
||||||
tell application "System Events" to tell process "alacritty"
|
tell application "System Events" to tell process "alacritty"
|
||||||
set frontmost to true
|
set frontmost to true
|
||||||
keystroke "tmux"
|
keystroke "tmux"
|
||||||
|
@ -39,19 +39,11 @@ resize_window_to_full_screen() {
|
||||||
|
|
||||||
resize_to_true_full_screen() {
|
resize_to_true_full_screen() {
|
||||||
osascript <<-EOF
|
osascript <<-EOF
|
||||||
tell application "Alacritty"
|
tell application "alacritty"
|
||||||
activate
|
activate
|
||||||
delay 0.5
|
delay 1
|
||||||
tell application "System Events" to tell process "Alacritty"
|
tell application "System Events" to tell process "alacritty"
|
||||||
if front window exists then
|
keystroke "f" using {control down, command down}
|
||||||
tell front window
|
|
||||||
if value of attribute "AXFullScreen" then
|
|
||||||
set value of attribute "AXFullScreen" to false
|
|
||||||
else
|
|
||||||
set value of attribute "AXFullScreen" to true
|
|
||||||
end if
|
|
||||||
end tell
|
|
||||||
end if
|
|
||||||
end tell
|
end tell
|
||||||
end tell
|
end tell
|
||||||
EOF
|
EOF
|
||||||
|
|
|
@ -7,7 +7,7 @@ start_terminal_and_run_tmux() {
|
||||||
osascript <<-EOF
|
osascript <<-EOF
|
||||||
tell application "kitty"
|
tell application "kitty"
|
||||||
activate
|
activate
|
||||||
delay 5
|
delay 1
|
||||||
tell application "System Events" to tell process "kitty"
|
tell application "System Events" to tell process "kitty"
|
||||||
set frontmost to true
|
set frontmost to true
|
||||||
keystroke "tmux"
|
keystroke "tmux"
|
||||||
|
|
|
@ -9,7 +9,7 @@ start_terminal_and_run_tmux() {
|
||||||
osascript <<-EOF
|
osascript <<-EOF
|
||||||
tell application "Warp"
|
tell application "Warp"
|
||||||
activate
|
activate
|
||||||
delay 5
|
delay 1
|
||||||
tell application "System Events" to tell process "Warp"
|
tell application "System Events" to tell process "Warp"
|
||||||
set frontmost to true
|
set frontmost to true
|
||||||
keystroke "tmux"
|
keystroke "tmux"
|
||||||
|
|
Loading…
Reference in New Issue