Screenshot in wmii

Tagged wmii, screenshot, linux, imagemagick  Languages bash

Method 1

A simple script to create a screenshot in wmii. It probably works in other window managers too. I call it 'scrot'. Put it in the path and run it as you'd run any program in wmii. The "import" program comes with imagemagick.

import -window root /tmp/screenshot.png

Method 2

If you want timestamped screenshots then

apt-get install scrot
mkdir -p ~/screenshots

And create a script with the following content for making the screenshot.

scrot '%Y-%m-%d-%H-%M-%S_$wx$h_scrot.png' -e 'mv $f ~/screenshots'