Tmux Chess Clock Pairing
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
#!/bin/bash | |
`tmux set-option -g display-time 2000` | |
IFS=$'\n' | |
CLIENTS=() | |
for CLIENT in $(tmux list-clients); do | |
CLIENTID="${CLIENT%:*}" | |
if [[ $CLIENT == *\(ro\) ]] | |
then | |
`tmux display-message -c $CLIENTID "YOU'RE IT"` | |
else | |
`tmux display-message -c $CLIENTID "READ ONLY"` | |
fi | |
`tmux switch-client -c $CLIENTID -r` | |
done | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment