Created
August 13, 2009 06:43
-
-
Save sousk/167024 to your computer and use it in GitHub Desktop.
reload firefox v3.5
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
ps -xc|grep -sqi firefox && osascript <<'APPLESCRIPT' | |
tell application "Firefox" to activate | |
tell application "System Events" | |
if UI elements enabled then | |
keystroke "r" using command down | |
-- Fails if System Preferences > Universal access > "Enable access for assistive devices" is not on | |
else | |
-- Fails if Firefox is set to open URLs from external apps in new tabs. | |
-- tell app "Firefox" to Get URL "JavaScript:window.location.reload();" inside window 1 | |
tell application "Firefox" to get URL "JavaScript:window.location.reload();" | |
end if | |
end tell | |
APPLESCRIPT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment