Skip to content

Instantly share code, notes, and snippets.

@dmitry-vsl
Last active August 29, 2015 14:12
Show Gist options
  • Save dmitry-vsl/704528b42f35527a7dd2 to your computer and use it in GitHub Desktop.
Save dmitry-vsl/704528b42f35527a7dd2 to your computer and use it in GitHub Desktop.

Use vim and chrome developer tools as REPl environment. Press Ctrl-C Ctrl-C to eval code right in chrome console.

cat | pbcopy
osascript << EOF
tell application "Google Chrome" to activate
tell application "System Events"
keystroke "c" using {command down, shift down}
keystroke "v" using {command down}
key code 36
delay 0.05
key code 36
end tell
delay 0.05
tell application "Terminal" to activate
EOF
vnoremap <C-c><C-c> y:call system('~/chromerepl/repl.sh',@")<CR>
nnoremap <C-c><C-c> {V}y:call system('~/chromerepl/repl.sh',@")<CR>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment