Created
October 11, 2022 20:20
-
-
Save topher1kenobe/73053b393cad123510e1bbbecf1b4457 to your computer and use it in GitHub Desktop.
take a screenshot, ssh it someplace
This file contains hidden or 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 | |
/opt/homebrew/bin/ffmpeg -ss 0.5 -f avfoundation -r 30.000030 -i "0" -t 1 /Users/topher/window_shots/"grmi_$(date +%F_%H-%M-%S).jpg" -frames:v 1 | |
unset -v latest | |
for file in /Users/topher/window_shots/*; do | |
[[ $file -nt $latest ]] && latest=$file | |
done | |
keychain --noask --eval id_dsa | |
scp $latest cat:~/www/example.com/public_html/window_shot.jpg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment