]> ruderich.org/simon Gitweb - fcscs/fcscs.git/blobdiff - bin/fcscs
support $match->{handler} to overwrite handler for certain matches
[fcscs/fcscs.git] / bin / fcscs
index ade298a6114e57a3d8ee7a77b1fff068fc1f041d..9c33fe95ca06d3c9f7bcc05e261d620af02923d4 100755 (executable)
--- a/bin/fcscs
+++ b/bin/fcscs
@@ -729,7 +729,7 @@ sub handler_paste {
 sub handler_url {
     my ($screen, $config, $match) = @_;
 
-    debug $config, 'handler_url', 'started';
+    debug $config, 'handler_url', "opening $match->{value}";
 
     run_in_background($config, sub {
         my @cmd = map { $screen->encode($_) } (
@@ -1212,6 +1212,7 @@ RESULT:
 
             debug \%config, 'input', 'running handler';
             my $handler = $config{state}{handler};                 # set by user
+            $handler = $result->{match}->{handler} unless defined $handler; # set by match
             $handler = $result->{handler} unless defined $handler; # set by mapping
             $handler = $config{handler}{yank} unless defined $handler; # fallback
             $handler->($screen, \%config, $result->{match});