diff options
Diffstat (limited to '')
| -rwxr-xr-x | .local/bin/dmscrot | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/.local/bin/dmscrot b/.local/bin/dmscrot index dcefb70..b23d886 100755 --- a/.local/bin/dmscrot +++ b/.local/bin/dmscrot @@ -3,12 +3,13 @@ use strict; use warnings; use File::HomeDir qw(home); + use constant { SAVE_PATH => 'pics/scrot/', SCREENSHOT_PATH => 'scrot', IMGVIEW_PATH => 'nsxiv', XCLIP_PATH => 'xclip', - NOTIFY_PATH => 'notify-send' + NOTIFY_PATH => 'herbe' }; use constant LIST => [ 'select region', @@ -33,15 +34,15 @@ sub show_img sub notify_img { my ($file) = @_; + my $pid; - system( - NOTIFY_PATH, - '-u', 'low', - '-t', '2000', - 'scrot', - ' screenshot captured to ' . "\n" . - '<b>' . $file . '</b>' + $pid = fork(); + if (not $pid) { + system( + NOTIFY_PATH, + 'screenshot captured to ' . "\n" . $file ); + } return; } |
