{"id":27371561,"url":"https://github.com/wicksome/iterm-launcher","last_synced_at":"2025-06-12T03:35:06.327Z","repository":{"id":86539338,"uuid":"98114828","full_name":"wicksome/iTerm-launcher","owner":"wicksome","description":"🕹 AppleScript code to help you run iTerm2","archived":false,"fork":false,"pushed_at":"2018-01-03T05:13:03.000Z","size":2575,"stargazers_count":3,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-03T22:02:11.321Z","etag":null,"topics":["applescript","iterm","iterm-launcher","iterm-window","iterm2","iterm2-theme","macos"],"latest_commit_sha":null,"homepage":"","language":"AppleScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wicksome.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-07-23T17:43:03.000Z","updated_at":"2023-07-29T18:29:52.000Z","dependencies_parsed_at":"2023-03-13T06:01:04.098Z","dependency_job_id":null,"html_url":"https://github.com/wicksome/iTerm-launcher","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/wicksome/iTerm-launcher","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wicksome%2FiTerm-launcher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wicksome%2FiTerm-launcher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wicksome%2FiTerm-launcher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wicksome%2FiTerm-launcher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wicksome","download_url":"https://codeload.github.com/wicksome/iTerm-launcher/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wicksome%2FiTerm-launcher/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259390206,"owners_count":22850188,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["applescript","iterm","iterm-launcher","iterm-window","iterm2","iterm2-theme","macos"],"created_at":"2025-04-13T09:42:41.262Z","updated_at":"2025-06-12T03:35:06.322Z","avatar_url":"https://github.com/wicksome.png","language":"AppleScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# iTerm Launcher\n\n\u003e iTerm helper using AppleScript.\n\nbuild env:\n\n- macOS: Sierra 10.12.6\n- iTerm2: Build 3.1.5\n\n## Demo\n\n![preview](https://user-images.githubusercontent.com/5036939/33924248-91b0e8fc-e018-11e7-8c57-3207d94400f3.gif)\n\n```sh\n$ ./demo/run 2 4\nCompiling /Users/user/git/iTerm-launcher/app/lib/iterm.applescript...\nv2.0\n```\n\n\n## Example code\n\n```applescript\n-- Load iTerm script.\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\n\n-- Use iTerm script.\nset ITERM_WINDOW to newWindow() of iterm -- row, column\n\n-- show version\nlog VERSION of iterm\n-- Split pane\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n-- run command to current pane\nrunCmd(ITERM_WINDOW, \"echo 'This is active pane current'\") of iterm\n-- run command to all panes\nrunCmdAllPanes(ITERM_WINDOW, \"echo 'all'\") of iterm\n-- run command to specific pane\nrunCmdPane(ITERM_WINDOW, 2, \"echo 'This is second pane'\") of iterm\n-- run commands to each pane\nrunCmdEachPanes(ITERM_WINDOW, [¬\n  \"echo '1'\",¬\n  \"echo '2'\",¬\n  \"echo '3'\"¬\n]) of iterm\n-- send keystroke\nsendKeystroke(\"CMD-OPT-i\") of iterm\n```\n\n## Usage\n\n### `newWindow(): windowId`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\n```\n\n### `splitPane(windowId: int, row: int, column: int)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\n\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n```\n\n### `runCmdAllPanes(windowId: int, command: String)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n\nrunCmdAllPanes(ITERM_WINDOW, \"ls -al\") of iterm\n```\n\n### `runCmd(windowId: int, command: String)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n\nrunCmd(ITERM_WINDOW, \"echo 'This is current active pane'\") of iterm\n```\n\n\n### `runCmdPane(windowId: int, paneId: int, command: String)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n\nrunCmdPane(ITERM_WINDOW, 2, \"echo 'This is second pane'\") of iterm\n```\n\n### `runCmdEachPanes(windowId: Int, commands: Array)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n\nrunCmdEachPanes(ITERM_WINDOW, [¬\n  \"ls -al\",¬\n  \"htop\",¬\n  \"ps -ef | grep java\"¬\n]) of iterm\n```\n\n### `sendKeystroke(keystroke: String)`\n\nExample:\n\n```applescript\ntell application \"Finder\" to set binPath to POSIX path of (container of (path to me) as text) \u0026 \"app/bin/\"\nset iterm to load script file (currentPath \u0026 \"iterm.scpt\")\nset ITERM_WINDOW to newWindow() of iterm\nsplitPane(ITERM_WINDOW, 2, 2) of iterm\n\nsendKeystroke(\"CMD-OPT-i\") of iterm\n```\n\n## Reference\n\n- https://www.iterm2.com/documentation-scripting.html\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwicksome%2Fiterm-launcher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwicksome%2Fiterm-launcher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwicksome%2Fiterm-launcher/lists"}