Skip to content

Instantly share code, notes, and snippets.

@sirjofri
Created September 1, 2017 13:24
Show Gist options
  • Select an option

  • Save sirjofri/7ca2f613481d2ccf4846a9de7729f555 to your computer and use it in GitHub Desktop.

Select an option

Save sirjofri/7ca2f613481d2ccf4846a9de7729f555 to your computer and use it in GitHub Desktop.
scrot with filename, preview, mouse select and saving into a specific directory. I use it with dmenu on i3
#!/bin/bash
mkdir -p ~/scrot
if [ -z "$1" ]; then
scrot -s -e 'mv $f ~/scrot/$n ; feh ~/scrot/$n'
else
scrot -s ~/scrot/$1.png -e 'feh $f'
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment