Skip to content

Instantly share code, notes, and snippets.

@gogamid
Last active June 13, 2024 16:49
Show Gist options
  • Save gogamid/664bccb3d02acfbc4abc0ba4dcc209d8 to your computer and use it in GitHub Desktop.
Save gogamid/664bccb3d02acfbc4abc0ba4dcc209d8 to your computer and use it in GitHub Desktop.
wezterm-alfred.applescript
on alfred_script(query)
tell application "wezterm" to activate
set paneId to do shell script "/Applications/WezTerm.app/Contents/MacOS/wezterm cli split-pane"
set commandList to paragraphs of query
repeat with command in commandList
do shell script "echo " & command & " | /Applications/WezTerm.app/Contents/MacOS/wezterm cli send-text --no-paste --pane-id " & paneId
end repeat
end alfred_script
@jasonminsookim
Copy link

Thanks this worked perfectly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment