Skip to content

Instantly share code, notes, and snippets.

@andykais
Last active August 29, 2015 14:17
Show Gist options
  • Save andykais/e3e9f9040e3d2a1ff227 to your computer and use it in GitHub Desktop.
Save andykais/e3e9f9040e3d2a1ff227 to your computer and use it in GitHub Desktop.
chrome version of my run on change to auto update for web pages
#!/bin/bash
# the current version of chrome in linux requires focus on the window for xdotool
#this is a workaround to focus back to the editor after reloading the page
editor=`xdotool getwindowfocus`
xdotool search --onlyvisible --class "Chrome" windowfocus key 'ctrl+r'
xdotool windowfocus $editor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment