Last active
August 29, 2015 14:07
-
-
Save bolasblack/3a96477ba079bc164f46 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "iTerm2" | |
activate | |
set windowCount to count of terminal windows | |
-- display dialog windowCount as text | |
if windowCount is 0 then | |
create window with default profile | |
delay 0.1 | |
tell application "System Events" | |
tell process "iTerm2" | |
tell menu bar 1 | |
tell menu bar item "View" | |
tell menu "View" | |
click menu item "Toggle Full Screen" | |
end tell | |
end tell | |
end tell | |
end tell | |
end tell | |
-- another way to full screen | |
-- | |
-- tell application "System Events" | |
-- keystroke return using {command down} | |
-- end tell | |
end if | |
end tell |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment