You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

18 lines
338 B

#!/bin/bash
PICTURES=~/Pictures
mkdir -p $PICTURES
cd $PICTURES
# make screenshot
SCREENSHOT=$(scrot -e 'echo $f')
if [ "$SCREENSHOT" = "" ]; then
exit 1
fi
# open screenshot in 2/3 window
read W H X <<< $(xrandr 2>/dev/null | fgrep '*' | tr -s " " | tr "x" " ")
W=$(($W*2/3))
H=$(($H*2/3))
exec feh --geometry $W"x"$H $SCREENSHOT