aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2021-07-27 00:36:07 +0200
committerJohn Ankarström <john@ankarstrom.se>2021-07-27 00:36:28 +0200
commit536f196c7e4ca57e9ea8abd0a81e7351fda37e21 (patch)
treef30bc39dd60f1654a8bfcb45d5e7a14362404ecb
parent4cf17da6e7e7afc01694eacd85358c480b79c42c (diff)
downloaddwim-master.tar.gz
Open directories in new terminal windowHEADmaster
-rwxr-xr-xdwim4
1 files changed, 2 insertions, 2 deletions
diff --git a/dwim b/dwim
index 04e2632..fae2630 100755
--- a/dwim
+++ b/dwim
@@ -27,7 +27,7 @@ my @PDF_VIEWER = ('xpdf');
my @MAN_VIEWER = (@OPENER, 'man');
my @MAILER = (@OPENER, 'mutt');
my @BROWSER = (@OPENER, 'w3m', '-title');
-my @FILE_BROWSER = ('rox');
+my @FILE_BROWSER = ('tterm');
my @MAILDIR_VIEWER = (@OPENER, 'mutt -f');
my $MAILROOT = env MAILROOT => '/home/john/mail/';
@@ -116,7 +116,7 @@ for ($phrase) {
handle 'maildir / directory / file';
my $p = path $1;
run @MAILDIR_VIEWER, $p if absp($p) =~ /^$MAILROOT/;
- run @FILE_BROWSER, $p if -d absp($p);
+ do { cd $p; run @FILE_BROWSER } if -d absp($p);
run @MAN_VIEWER, absp($p) if -e absp($p) and $p =~ /\.[1-9]$/;
run @PDF_VIEWER, $p if -e absp($p) and $p =~ /\.pdf$/;
run @EDITOR, $p if -e absp($p);