~mdw
/
profile
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
el/dot-emacs.el (mdw-regexp): Sort the input list.
[profile]
/
firefox
/
explode-stylus
diff --git
a/firefox/explode-stylus
b/firefox/explode-stylus
index
6dde67c
..
1b20b83
100755
(executable)
--- a/
firefox/explode-stylus
+++ b/
firefox/explode-stylus
@@
-1,10
+1,11
@@
#! /usr/bin/perl
use autodie;
#! /usr/bin/perl
use autodie;
+use POSIX qw{:errno_h};
use JSON;
my ($dir) = @ARGV;
use JSON;
my ($dir) = @ARGV;
-
mkdir $dir
;
+
eval { mkdir $dir; }; die if $@ && $@->errno != EEXIST
;
local $/;
my $js = decode_json <STDIN>;
local $/;
my $js = decode_json <STDIN>;
@@
-17,6
+18,7
@@
for my $e (@$js) {
next KEY if $k eq "code";
print $fh "/*@ $k: ", join(", ", $s->{$k}->@*), " */\n";
}
next KEY if $k eq "code";
print $fh "/*@ $k: ", join(", ", $s->{$k}->@*), " */\n";
}
+ $s->{code} =~ s/\n$//;
print $fh $s->{code}, "\n";
print $fh "/*\@END*/\n";
}
print $fh $s->{code}, "\n";
print $fh "/*\@END*/\n";
}