dotfiles

configuration files for shell, text editor, graphical environment, etc.
git clone git://src.adamsgaard.dk/dotfiles
Log | Files | Refs | README | LICENSE Back to index

commit 7ee47e28247f1b820223f569028c310e4782cbe5
parent e8e24b80e8965ca4d4e1879416a4a486c87e2070
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date:   Wed,  9 Sep 2020 13:02:50 +0200

Allow absolute paths for output files, delete png after converting to jpg

Diffstat:
M.local/bin/maimpick | 10++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/.local/bin/maimpick b/.local/bin/maimpick @@ -17,7 +17,13 @@ c="$(printf 'no\nyes' | dmenu -i -p "convert to jpg?")" case "$c" in yes) convert "$out" "${out%.png}.jpg" - out"${out%.png}.jpg";; + rm "$out" + out="${out%.png}.jpg";; esac -printf '%s/%s' "$HOME" "$out" | xclip -i +case "$out" in + /*) + printf '%s' "$out" | xclip -i;; + *) + printf '%s/%s' "$HOME" "$out" | xclip -i;; +esac