Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ red(1) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ed(1)

red(1)                                                               red(1)

NAME
     red - restricted interactive line editor

SYNOPSIS
     red[ -s][ -p string][ -x][ -C][ file]

DESCRIPTION
     red is the same as ed with the following two restrictions: it can only
     edit files in the current working directory; and it does not allow the
     !command mechanism for the execution of shell commands.

     See ed(1) for a description of the parameters.

LOCALE
     The LCMESSAGES environment variable governs the language in which
     message texts are displayed.

     In regular expressions in square brackets, the LCCOLLATE environment
     variable governs the scope of character ranges, equivalence classes
     and collating elements, and the LCCTYPE environment variable governs
     the scope of character classes. LCCTYPE also governs which characters
     the ed command l treats as non-printing.

     If LCMESSAGES, LCCOLLATE or LCCTYPE is undefined or is defined as
     the null string, it defaults to the value of LANG. If LANG is likewise
     undefined or null, the system acts as if it were not international-
     ized.

     The LCALL environment variable governs the entire locale. LCALL
     takes precedence over all the other environment variables which affect
     internationalization.

     If any of the locale variables has an invalid value, the system acts
     as if none of the variables were set.





















Page 1                       Reliant UNIX 5.44                Printed 11/98

red(1)                                                               red(1)

EXAMPLES
     The following session with red demonstrates and explains all the com-
     mands available in red. A fuller example is given under ed(1).
     ______________________________________________________________________
    | red command  |  Explanation                                         |
    |______________|______________________________________________________|
    | red          |  Call red                                            |
    |______________|______________________________________________________|
    | P            |  Display * prompt in command mode                    |
    |______________|______________________________________________________|
    | *a           |  Append to current line, in this case to beginning of|
    |              |  file                                                |
    |______________|______________________________________________________|
    | First line   |  Input text                                          |
    |______________|______________________________________________________|
    | Last line    |  Input text                                          |
    |______________|______________________________________________________|
    | .            |  Terminate input mode                                |
    |______________|______________________________________________________|
    | *2 i         |  Insert before second line                           |
    |______________|______________________________________________________|
    | Second line  |  Input text                                          |
    |______________|______________________________________________________|
    | .            |  Terminate input mode                                |
    |______________|______________________________________________________|
    | *1,3 p       |  Print lines 1 to 3                                  |
    |______________|______________________________________________________|
    | First line   |                                                      |
    | Second line  |                                                      |
    | Last line    |                                                      |
    |______________|______________________________________________________|
    | *w textfile  |  Write buffer contents to file named textfile        |
    |______________|______________________________________________________|
    | 33           |  The number of characters written is displayed       |
    |______________|______________________________________________________|
    | *q           |  Quit red                                            |
    |______________|______________________________________________________|
    | $            |  Bourne shell prompt                                 |
    |______________|______________________________________________________|

SEE ALSO
     ed(1).












Page 2                       Reliant UNIX 5.44                Printed 11/98

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