I3 WM Gnome style screenshots

I found lot's of examples to take screenshots in I3, but most of them require additional scripts or will always overwrite the same temp file. So I've been testing a bit to make it easier. Put this in your .i3/config to take Gnome style screenshots in a png in ~/Pictures. Mod+x selects a rectangle on the screen or mod+y takes the entire screen contents.

bindsym --release $mod+x exec --no-startup-id import ~/Pictures/screenshot-`/bin/date +%Y%m%d-%H:%M:%S`.png
bindsym --release $mod+y exec --no-startup-id import -window root ~/Pictures/screenshot-`/bin/date +%Y%m%d-%H:%M:%S`.png

Anonymous (not verified)

Fri, 03/07/2015 - 15:12

Hi,
thanks you for this simple solution, but there is a little typo in your config. Both commands are binded to Mod+x, I think it has to be:

bindsym --release $mod+x exec --no-startup-id import ~/Pictures/screenshot-`/bin/date +%Y%m%d-%H:%M:%S`.png
bindsym --release $mod+y exec --no-startup-id import -window root ~/Pictures/screenshot-`/bin/date +%Y%m%d-%H:%M:%S`.png