Skip to content

Instantly share code, notes, and snippets.

@Meshiest
Created June 2, 2017 15:52
Show Gist options
  • Save Meshiest/db4fcbb8c53d28a3186e557350a946ee to your computer and use it in GitHub Desktop.
Save Meshiest/db4fcbb8c53d28a3186e557350a946ee to your computer and use it in GitHub Desktop.
Screenshot Area on KDE/arch
#!/bin/bash
# Requires spectacle and xclip, stores last screenshot at /tmp/screenshot.png
# Screenshots a specified area and copies the content to clipboard
# Author: Meshiest
rm /tmp/screenshot.png
spectacle -rbnwo /tmp/screenshot.png
[[ -f /tmp/screenshot.png ]] && xclip -selection c -t image/png -i /tmp/screenshot.png
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment