Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getoptcvt(1) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

getopt(1)

getopts(1)

getoptcvt(1)                                                   getoptcvt(1)

NAME
     getoptcvt - convert getopt command calls to getopts command calls

SYNOPSIS
     /usr/lib/getoptcvt [-b] script

DESCRIPTION
     getoptcvt reads a shell script, converts it to use getopts(1) calls
     instead of getopt(1), and writes the result to standard output.

OPTIONS
     -b   Makes the converted shell sript script portable to earlier
          releases of the operating system. /usr/lib/getoptcvt modifies the
          script so that when the resulting shell script is executed, it
          determines at runtime whether to invoke getopts or getopt.

          -b not specified

          The converted shell script will always use getopts.

     script
          The script file to be converted. The shell script must contain
          correct and meaningful getopt calls such as
          set -- `getopt ... $*`. Otherwise, a "?" (question mark) is
          displayed, and the conversion program exits with an error.

EXAMPLES
     All calls to the getopt command in the shell script oldscript are to
     be converted to getopts calls. The converted shell script is to be
     saved in the file newscript.

     $ /usr/lib/getoptcvt oldscript > newscript

SEE ALSO
     getopt(1), getopts(1).




















Page 1                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026