Super Quick & Simple Imgur Screenshotting – Debian/Ubuntu

Keyboard shortcut that will allow you to select an area on screen, then one second later the Imgur link is in your clipboard ready to paste.

Steps to install:

1) sudo apt-get install scrot curl zenity xclip
2) Copy the script below into an empty file, save as
3) chmod +x
4) Set a keyboard shortcut to run the script on keypress

nano=`date '+%d-%m-%y-%N'`;

sleep 2; scrot -s -b -q 0 $file;

TEXT=$(curl -F "image"=@"$file" -F "key"="5d317f0bee23b282473522e1aa68f621" | grep -Eo '<[a-z_]+>http[^<]+'|sed 's/^<.\|_./\U&/g;s/_/ /;s/<\(.*\)>/\1:\ /' | grep "Original" | awk '{print $3}' );

echo $TEXT | xclip;

exit 0



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s