Skip to content
This repository has been archived by the owner on Apr 18, 2023. It is now read-only.

Commit

Permalink
Merge pull request #2995 from orestisf1993/dump-asy-basename
Browse files Browse the repository at this point in the history
dump-asy.pl: use correct tmp dirname instead of hardcoded /tmp
  • Loading branch information
Airblader committed Sep 27, 2017
2 parents 54d61b5 + 828ce9c commit 9aa016c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion contrib/dump-asy.pl
Expand Up @@ -13,6 +13,7 @@
use Data::Dumper;
use AnyEvent::I3;
use File::Temp;
use File::Basename;
use v5.10;

my $i3 = i3();
Expand Down Expand Up @@ -75,4 +76,5 @@ sub find_node_with_name {
close($tmp);
my $rep = "$tmp";
$rep =~ s/asy$/eps/;
system("cd /tmp && asy $tmp && gv --scale=-1000 --noresize --widgetless $rep && rm $rep");
my $tmp_dir = dirname($rep);
system("cd $tmp_dir && asy $tmp && gv --scale=-1000 --noresize --widgetless $rep && rm $rep");

0 comments on commit 9aa016c

Please sign in to comment.