(02.08.2011 15:30)
Erstellt 5 Sekunden nach Aufruf einen Screenshot im definierten Ordner.
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
#!/bin/bash showmsg() { path="/usr/share/icons/gnome/scalable" icon="$1" title="$2" msg="$3" notify-send -u normal "$title" "$msg" -i "$path/$icon" -t 5000 return 0; } target="/home/sim4000/Documents/screenshots" date=`date +%y-%m-%d_%H-%M-%S` filename="$target/screenie_$(hostname)_${date}.png" icon="mimetypes/image.svg" if [ ! -d "$target" ]; then mkdir -p "$target" showmsg "$icon" "Screenshot" "Create $target. Try again." exit 0; fi sleep 5 fbgrab "$filename" showmsg "$icon" "Screenshot" "Create $filename" |