#! /bin/sh
#
# @(#)setMAILSTYLE	1.2	LPS_UNX_COM	2/15/93
#
# Copyright 1993   Digital Equipment Corporation, Maynard, MA
#
# setMAILSTYLE
#
# A script that produces a value for attribute MAILSTYLE.
#
# Parameters:
#    $1 - LPS class identifier, one of {PC, MC, PS, ENV}
#    $2 - Operating system type identifier (eg: SV2, BSD, etc)
#    $3 - Print client type identifier (eg: AIX, BSD, SV3, etc)
#    $4 - PrintServer printer model (eg: LPS17, LPS20)
#    $5 - Default value for the attribute
#    $6 - Path of the output file to receive the final attribute value
#
# Global variables:
#    ECHON
#    FUNCS
#    PAGER
#    TR    (for the checknumrange() function)
#
# Exit values:
#    0 - Success, output file contains newly set attribute value.
#    1 - Error or interruption occurred, error messages go to stderr,
#	 contents of the output file are undefined.
###

CLASS=$1
OSTYPE=$2
PCTYPE=$3
PSMODEL=$4
DEFVAL=$5
OUTFILE=$6

. $FUNCS   # Import the standard LPS shell functions

showhelp true "
What style of electronic mail addressing should be used?

Some LPS programs send electronic mail messages to users upon certain
types of events; for example, when a problem is encountered during the
processing of a print request, the Print Client will send the
requesting user a message containing the nature of the error.

Also, in the case of PostScript(R) \"user data\" output during
the execution of a PostScript(R) program on a PrintServer printer, the
data is captured and mailed to the requesting user.

Three styles of electronic mail addressing are supported:

    RFC822 - Standard Internet convention, based on users and domains;
	     for example: user@host

    UNIX   - Original UNIX convention, now considered somewhat obsolete;
	     for example: host!user

    DECNET - Digital Equipment Corporation network implementation;
	     for example: host::user

RFC822 is generally considered to be the best style of mail
addressing, and support for this style is fairly widespread.

The UNIX style of addressing should work on all UNIX-based systems,
but is generally considered to be an inferior form of mail addressing,
and may not work properly depending on your particular network
configuration.

In order to use DECNET addressing, you must either have DECNET
installed on your system, or have special support for this type of
addressing (which is fairly rare).

If you are not familiar with the various styles of mail addressing,
you should choose the default response."

list="RFC822 UNIX DECNET"

choose $DEFVAL "Mail addressing type" $list

echo "$RESPONSE" > $OUTFILE

exit 0
