diff options
Diffstat (limited to '')
-rwxr-xr-x | website | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -50,6 +50,13 @@ sub test { die "FIXME"; } +sub escaped_cmd { + my ($cmd, @args) = @_; + $cmd = $cmd." \"$_\"", for @args; + system($cmd); + exit $? >> 8; +} + sub dispatch { my $action = shift; my @args = @_; @@ -66,11 +73,9 @@ sub dispatch { -exitval => 2 ); } elsif ($action eq 'pastebin') { - print `./pastebin/website-pastebin @sub_args`; - exit $? >> 8; + escaped_cmd("./pastebin/website-pastebin", @sub_args); } elsif ($action eq 'slides') { - print `./pastebin/website-slides @sub_args`; - exit $? >> 8; + escaped_cmd("./slides/website-slides", @sub_args); } elsif ($action eq 'test') { test(); } else { |