about summary refs log tree commit diff
path: root/editor/pnmcat
blob: 4893720c1ae0efa1f475b214afd20aca0bc14791 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#! /bin/sh

plainopt=""
quietopt=""
pamcatopts=""

# Parse args.
while true ; do
    case "$1" in
        -v|--v|-version|--version )
        pamcat --version; exit $?;
        ;;
        -p|-pl|-pla|-plai|-plain|--p|--pl|--pla|--plai|--plain )
        plainopt="-plain"
        shift
        ;;
        -q|-qu|-qui|-quie|-quiet|--q|--qu|--qui|--quie|--quiet )
        quietopt="-quiet"
	shift
        ;;
	"" )
	break
	;;
	* )
        pamcatargs=${pamcatargs}" $1" 	    
	shift
	;;
    esac
  done

pamcat -extendplane ${pamcatargs} ${quietopt} | \
  pamtopnm --assume ${plainopt} ${quietopt}