diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2016-06-26 18:15:09 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2016-06-26 18:15:09 +0000 |
commit | aab4792db8e0adcaf63cf57a1f5e0b18666dae47 (patch) | |
tree | bbfa9c4e12783d2dfd785c4e10964366550e9a60 /editor/ppmfade | |
parent | fe14f983ade44baa0794e4ce58a1a5334e46cf68 (diff) | |
download | netpbm-mirror-aab4792db8e0adcaf63cf57a1f5e0b18666dae47.tar.gz netpbm-mirror-aab4792db8e0adcaf63cf57a1f5e0b18666dae47.tar.xz netpbm-mirror-aab4792db8e0adcaf63cf57a1f5e0b18666dae47.zip |
Promote Development to Advanced as Release 10.75.00
git-svn-id: http://svn.code.sf.net/p/netpbm/code/advanced@2803 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'editor/ppmfade')
-rwxr-xr-x | editor/ppmfade | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/editor/ppmfade b/editor/ppmfade index 027fc793..dcd7bf26 100755 --- a/editor/ppmfade +++ b/editor/ppmfade @@ -41,6 +41,19 @@ exec perl -w -x -S -- "$0" "$@" ############################################################################## use strict; +sub doVersionHack($) { + my ($argvR) = @_; + + my $arg1 = $argvR->[0]; + + if (defined($arg1) && (($arg1 eq "--version") || ($arg1 eq "-version"))) { + my $termStatus = system('ppmmix', '--version'); + exit($termStatus == 0 ? 0 : 1); + } +} + + + my $SPREAD = 1; my $SHIFT = 2; my $RELIEF = 3; @@ -59,6 +72,7 @@ my $base_name = "fade"; # default base name of output files my $image = "ppm"; # default output storage format my $mode = $SPREAD; # default fading mode +doVersionHack(\@ARGV); my $n; # argument number @@ -98,8 +112,6 @@ for ($n = 0; $n < @ARGV; $n++) { $mode = $BLOCK; } elsif ("$ARGV[$n]" eq "-mix") { $mode = $MIX; - } elsif ($ARGV[$n] eq "-help" || $ARGV[$n] eq "-h") { - usage(); } else { print "Unknown argument: $ARGV[$n]\n"; exit 100; |