Skip to content

Instantly share code, notes, and snippets.

@yanyaoer
Created February 10, 2011 15:59
Show Gist options
  • Save yanyaoer/820761 to your computer and use it in GitHub Desktop.
Save yanyaoer/820761 to your computer and use it in GitHub Desktop.
reload firefox or chrome
tell application "Firefox" to activate
tell application "System Events"
if UI elements enabled then
keystroke "r" using command down
keystroke tab using command down
end if
end tell
tell application "Google Chrome"
tell active tab of first window
execute javascript "window.location.reload()"
end tell
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment