Skip to content

Instantly share code, notes, and snippets.

@prasmussen
Last active March 20, 2024 23:18
Show Gist options
  • Save prasmussen/7fda8d5bcce65fd7d186 to your computer and use it in GitHub Desktop.
Save prasmussen/7fda8d5bcce65fd7d186 to your computer and use it in GitHub Desktop.
chrome-cli execute loop
#!/bin/bash
for n in $(chrome-cli list tabs | awk '{print $1}' | sed -e 's/\[//' | sed -e 's/\]//'); do
chrome-cli execute '$("#run-code-button").click()' -t $n > /dev/null
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment