Created
July 15, 2019 18:19
-
-
Save amin3mej/5e63b22911901bf0af7efd63908adaf1 to your computer and use it in GitHub Desktop.
Wait 3 seconds and if "q" button doesn't pressed, go to HACKER mode! (good for RPi)
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 | |
tmuv() ( tmux split-window -dv -t $TMUX_PANE "bash --rcfile <(echo '. ~/.bashrc;$*')" ) | |
tmuh() ( tmux split-window -dh -t $TMUX_PANE "bash --rcfile <(echo '. ~/.bashrc;$*')" ) | |
end=$((SECONDS+3)) | |
while [ $SECONDS -lt $end ]; do | |
read -t 0.25 -N 1 input | |
if [[ $input = "q" ]] || [[ $input = "Q" ]]; then | |
exit 0 | |
fi | |
done | |
tmuh htop | |
tmuv ping 8.8.8.8 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment