Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[tutorial/make-pdf] ported to Perl 6

  • Loading branch information...
commit c0ad07f7d80fc3f2c0dd0bf042177d9cb9deb543 1 parent 432339a
@masak authored
Showing with 7 additions and 8 deletions.
  1. +7 −8 tutorial/make-pdf
View
15 tutorial/make-pdf
@@ -1,19 +1,18 @@
-#!/usr/bin/perl -w
-use strict;
+#!/usr/local/bin/perl6
my $inkscape_executable
= '/Applications/Inkscape.app/Contents/Resources/bin/inkscape';
die 'Could not find inkscape'
- unless -f $inkscape_executable;
+ unless $inkscape_executable ~~ :f;
-system
+run
"$inkscape_executable "
- . "--without-gui --file=src/page$_.svg "
- . "--export-pdf=pdf/page$_.pdf 2> /dev/null"
+ ~ "--without-gui --file=src/page$_.svg "
+ ~ "--export-pdf=pdf/page$_.pdf 2> /dev/null"
for 1..5;
-system
+run
'gs -q -sPAPERSIZE=letter -dNOPAUSE -dBATCH -sDEVICE=pdfwrite'
- . " -sOutputFile=win.pdf pdf/*.pdf 2> /dev/null";
+ ~ " -sOutputFile=win.pdf pdf/*.pdf 2> /dev/null";
Please sign in to comment.
Something went wrong with that request. Please try again.