On my machine a a few of the scripts generate duplicate lines when help is printed out:
this can be fixed by adding a -n to the sed command that generates the help output
e.g.
sed >&2 -n -e '1,/^####/d; /^######/g; /^#/!q; s/^#*//; s/^ //; 4,$p' "$PROGDIR/$PROGNAME"
this affects multicrop and innercrop
duplicated lines in usage() or help files
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: duplicated lines in usage() or help files
All my scripts have the same code. It only happens on certain Linux systems. For example not on my Mac. I have seen several variations that fix this, but some cause it to break on my Mac. So right now I have no universal solution. Furthermore, it would mean manually changing over 300 scripts. So at this time, each person will have to make modifications, if this is important. See Pointer 13 on my home page about other solutions to the same issue. I will add your solution to the list there.