man: clean-out man1x category.
Removes the following man pages: * awk.1x -- for a version of awk we no longer have * kermit.1x -- seems gone altogether * macros.1x -- not useful for anyone anymore Moves the following man pages: * mined.1x -- Moved to minix/commands/mined/mined.1 and reformatted to use the mdoc macros instead of the Minix macros so that it displays properly. Removes /usr/man/man1x from the directory tree. closes #44 Change-Id: I59b8bd54cf5cba6d188e51e99a92b36e90c275c1
This commit is contained in:
parent
d1a87c1f64
commit
fc850d580c
10 changed files with 236 additions and 2061 deletions
|
@ -2520,6 +2520,7 @@
|
|||
./usr/man/man1/md5.1 minix-sys
|
||||
./usr/man/man1/menuc.1 minix-sys
|
||||
./usr/man/man1/mesg.1 minix-sys
|
||||
./usr/man/man1/mined.1 minix-sys
|
||||
./usr/man/man1/ministat.1 minix-sys
|
||||
./usr/man/man1/mixer.1 minix-sys
|
||||
./usr/man/man1/mkdep.1 minix-sys
|
||||
|
@ -2687,11 +2688,11 @@
|
|||
./usr/man/man1/zless.1 minix-sys
|
||||
./usr/man/man1/zmore.1 minix-sys
|
||||
./usr/man/man1/znew.1 minix-sys
|
||||
./usr/man/man1x minix-sys
|
||||
./usr/man/man1x/awk.1x minix-sys
|
||||
./usr/man/man1x/kermit.1x minix-sys
|
||||
./usr/man/man1x/macros.1x minix-sys
|
||||
./usr/man/man1x/mined.1x minix-sys
|
||||
./usr/man/man1x minix-sys obsolete
|
||||
./usr/man/man1x/awk.1x minix-sys obsolete
|
||||
./usr/man/man1x/kermit.1x minix-sys obsolete
|
||||
./usr/man/man1x/macros.1x minix-sys obsolete
|
||||
./usr/man/man1x/mined.1x minix-sys obsolete
|
||||
./usr/man/man2 minix-sys
|
||||
./usr/man/man2/accept.2 minix-sys
|
||||
./usr/man/man2/access.2 minix-sys
|
||||
|
|
|
@ -110,7 +110,6 @@
|
|||
./usr/log
|
||||
./usr/man
|
||||
./usr/man/man1
|
||||
./usr/man/man1x
|
||||
./usr/man/man2
|
||||
./usr/man/man3
|
||||
./usr/man/man4
|
||||
|
|
|
@ -2,6 +2,5 @@
|
|||
|
||||
PROG= mined
|
||||
SRCS= mined1.c mined2.c
|
||||
MAN=
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
|
229
minix/commands/mined/mined.1
Normal file
229
minix/commands/mined/mined.1
Normal file
|
@ -0,0 +1,229 @@
|
|||
.Dd March 25, 2015
|
||||
.Dt MINED 1
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm mined
|
||||
.Nd text editor
|
||||
.Sh SYNOPSIS
|
||||
.Nm
|
||||
.Op file
|
||||
.Sh DESCRIPTION
|
||||
.Nm
|
||||
is a simple screen editor.
|
||||
At any instant, a window of 24 lines is visible on the screen.
|
||||
The current position in the file is shown by the cursor.
|
||||
Ordinary characters typed in are inserted at the cursor.
|
||||
Control characters and keys on the numeric keypad (at the right-hand side
|
||||
of the keyboard) are used to move the cursor and perform other functions.
|
||||
.Pp
|
||||
Commands exist to move forward and backward a word, and delete words
|
||||
either in front of the cursor or behind it.
|
||||
A word in this context is a sequence of characters delimited on both ends by
|
||||
white space (space, tab, line feed, start of file, or end of file).
|
||||
The commands for deleting characters and words also work on line feeds, making
|
||||
it possible to join two consecutive lines by deleting the line feed between them.
|
||||
.Pp
|
||||
The editor maintains one save buffer (not displayed).
|
||||
Commands are present to move text from the file to the buffer, from the buffer
|
||||
to the file, and to write the buffer onto a new file.
|
||||
If the edited text cannot be written out due to a full disk, it may still
|
||||
be possible to copy the whole text to the save buffer and then write it to a
|
||||
different file on a different disk with CTRL-Q.
|
||||
It may also be possible to escape from the editor with CTRL-S and remove
|
||||
some files.
|
||||
.Pp
|
||||
Some of the commands prompt for arguments (file names, search patterns, etc.).
|
||||
All commands that might result in loss of the file being edited prompt to ask
|
||||
for confirmation.
|
||||
.Pp
|
||||
A key (command or ordinary character) can be repeated
|
||||
.Em n
|
||||
times by typing
|
||||
.Em "ESC n key"
|
||||
where
|
||||
.Em ESC
|
||||
is the
|
||||
.Em escape
|
||||
key.
|
||||
.Pp
|
||||
Forward and backward searching requires a regular expression as the search
|
||||
pattern.
|
||||
Regular expressions follow the same rules as in the
|
||||
.Ux
|
||||
editor,
|
||||
.Xr ed 1 .
|
||||
These rules can be stated as:
|
||||
.Bl -tag -compact -offset indent -width "012345679"
|
||||
.It Em c
|
||||
Any displayable character matches itself
|
||||
.It Em \&.
|
||||
(period) matches any character except line feed
|
||||
.It Em \&^
|
||||
(circumflex) matches the start of the line
|
||||
.It Em \&$
|
||||
(dollar sign) matches the end of the line
|
||||
.It Em \ec
|
||||
matches the character \fIc\fR (including period, circumflex, etc)
|
||||
.It Em [string]
|
||||
matches any of the characters in the string
|
||||
.It Em [^string]
|
||||
matches any of the characters except those in the string
|
||||
.It Em [x-y]
|
||||
matches any characters between
|
||||
.Em x
|
||||
and
|
||||
.Em y
|
||||
(e.g.,
|
||||
.Em [a-z]
|
||||
).
|
||||
.It Pattern*
|
||||
matches any number of occurrences of
|
||||
.Em pattern
|
||||
.El
|
||||
.Pp
|
||||
Some examples of regular expressions are:
|
||||
.Bl -tag -compact -offset indent -width "012345679"
|
||||
.It Em The boy
|
||||
matches the string
|
||||
.Em The boy
|
||||
.It Em ^$
|
||||
matches any empty line.
|
||||
.It Em ^.$
|
||||
matches any line containing exactly 1 character
|
||||
.It ^A.*\e.$
|
||||
matches any line starting with an
|
||||
.Em A
|
||||
, ending with a period.
|
||||
.It ^[A\(enZ]*$
|
||||
matches any line containing only capital letters (or empty).
|
||||
.It [A-Z0-9]
|
||||
matches any line containing either a capital letter or a digit.
|
||||
.It \&.*X$
|
||||
matches any line ending in
|
||||
.Em X.
|
||||
.It A.*B
|
||||
matches any line containing an
|
||||
.Em A
|
||||
and then a
|
||||
.Em B
|
||||
.El
|
||||
.Pp
|
||||
Control characters cannot be entered into a file simply by typing them because
|
||||
all of them are editor commands.
|
||||
To enter a control character, depress the ALT key, and then while holding it
|
||||
down, hit the ESC key.
|
||||
Release both ALT and ESC and type the control character.
|
||||
Control characters are displayed in reverse video.
|
||||
.Pp
|
||||
The
|
||||
.Nm
|
||||
commands are as follows.
|
||||
.Ss CURSOR MOTION
|
||||
.Bl -tag -width "0123456789" -compact
|
||||
.It Em arrows
|
||||
Move the cursor in the indicated direction
|
||||
.It Em CTRL-A
|
||||
Move cursor to start of current line
|
||||
.It Em CTRL-Z
|
||||
Move cursor to end of current line
|
||||
.It Em CTRL-^
|
||||
Move cursor to top of screen
|
||||
.It Em CTRL-_
|
||||
Move cursor to end of screen
|
||||
.It Em CTRL-F
|
||||
Move cursor forward to start of next word
|
||||
.It Em CTRL-B
|
||||
Move cursor backward to start of previous word
|
||||
.El
|
||||
.Ss SCREEN MOTION
|
||||
.Bl -tag -width "0123456789" -compact
|
||||
.It Em Home key
|
||||
Move to first character of the file
|
||||
.It Em End key
|
||||
Move to last character of the file
|
||||
.It Em PgUp key
|
||||
Scroll window up 23 lines (closer to start of the file)
|
||||
.It Em PgDn Key
|
||||
Scroll window down 23 lines (closer to end of the file)
|
||||
.It Em CTRL-U
|
||||
Scroll window up 1 line
|
||||
.It Em CTRL-D
|
||||
Scroll window down 1 line
|
||||
.El
|
||||
.Ss MODIFYING TEXT
|
||||
.Bl -tag -width "0123456789" -compact
|
||||
.It Em Del key
|
||||
Delete the character under the cursor
|
||||
.It Em Backspace
|
||||
Delete the character to left of the cursor
|
||||
.It Em CTRL-N
|
||||
Delete the next word
|
||||
.It Em CTRL-P
|
||||
Delete the previous word
|
||||
.It Em CTRL-T
|
||||
Delete tail of line (all characters from cursor to end of line)
|
||||
.It Em CTRL-O
|
||||
Open up the line (insert line feed and back up)
|
||||
.It Em CTRL-G
|
||||
Get and insert a file at the cursor position
|
||||
.El
|
||||
.Ss BUFFER OPERATIONS
|
||||
.Bl -tag -width "0123456789" -compact
|
||||
.It Em CTRL-@
|
||||
Set mark at current position for use with CTRL-C and CTRL-K
|
||||
.It Em CTRL-C
|
||||
Copy the text between the mark and the cursor into the buffer
|
||||
.It Em CTRL-K
|
||||
Delete text between mark and cursor; also copy it to the buffer
|
||||
.It Em CTRL-Y
|
||||
Yank contents of the buffer out and insert it at the cursor
|
||||
.It Em CTRL-Q
|
||||
Write the contents of the buffer onto a file
|
||||
.El
|
||||
.Ss MISCELLANEOUS
|
||||
.Bl -tag -width "0123456789" -compact
|
||||
.It Em numeric +
|
||||
Search forward (prompts for regular expression)
|
||||
.It Em numeric -
|
||||
Search backward (prompts for regular expression)
|
||||
.It Em numeric 5
|
||||
Display the file status
|
||||
.It Em CTRL-]
|
||||
Go to specific line
|
||||
.It Em CTRL-R
|
||||
Global replace
|
||||
.Em pattern
|
||||
with
|
||||
.Em string
|
||||
(from cursor to end)
|
||||
.It Em CTRL-L
|
||||
Line replace
|
||||
.Em pattern
|
||||
with
|
||||
.Em string
|
||||
.It Em CTRL-W
|
||||
Write the edited file back to the disk
|
||||
.It Em CTRL-X
|
||||
Exit the editor
|
||||
.It Em CTRL-S
|
||||
Fork off a shell (use CTRL-D to get back to the editor)
|
||||
.It Em CTRL-\e
|
||||
Abort whatever the editor was doing and wait for command
|
||||
.It Em CTRL-E
|
||||
Erase screen and redraw it
|
||||
.It Em CTRL-V
|
||||
Visit (edit) a new file
|
||||
.El
|
||||
.Sh SEE ALSO
|
||||
.Xr vi 1 ,
|
||||
.Xr ed 1
|
||||
.Sh HISTORY
|
||||
.Nm
|
||||
first appeared in Minix 1.1.
|
||||
.Sh AUTHORS
|
||||
.Nm
|
||||
was designed by
|
||||
.An "Andy Tanenbaum"
|
||||
and written by
|
||||
.An "Michiel Huisjes".
|
||||
.\" .Sh BUGS
|
|
@ -1,6 +1,6 @@
|
|||
.include <bsd.own.mk>
|
||||
|
||||
SUBDIR= man1 man1x man2 man4 man5 man7 man8 man9
|
||||
SUBDIR= man1 man2 man4 man5 man7 man8 man9
|
||||
|
||||
WHATISDBDIR?= /usr/man
|
||||
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
MAN= awk.1x kermit.1x \
|
||||
macros.1x mined.1x
|
||||
|
||||
.include <bsd.man.mk>
|
|
@ -1,248 +0,0 @@
|
|||
.so mnx.mac
|
||||
.TH AWK 1x
|
||||
.CD "awk \(en pattern matching language"
|
||||
.SX "awk \fIrules\fR [\fIfile\fR] ...
|
||||
.FL "\fR(none)"
|
||||
.EX "awk rules input" "Process \fIinput\fR according to \fIrules\fR"
|
||||
.EX "awk rules \(en >out" "Input from terminal, output to \fIout\fR"
|
||||
.PP
|
||||
AWK is a programming language devised by Aho, Weinberger, and Kernighan
|
||||
at Bell Labs (hence the name).
|
||||
\fIAwk\fR programs search files for
|
||||
specific patterns and performs \*(OQactions\*(CQ for every occurrence
|
||||
of these patterns. The patterns can be \*(OQregular expressions\*(CQ
|
||||
as used in the \fIed\fR editor. The actions are expressed
|
||||
using a subset of the C language.
|
||||
.PP
|
||||
The patterns and actions are usually placed in a \*(OQrules\*(CQ file
|
||||
whose name must be the first argument in the command line,
|
||||
preceded by the flag \fB\(enf\fR. Otherwise, the first argument on the
|
||||
command line is taken to be a string containing the rules
|
||||
themselves. All other arguments are taken to be the names of text
|
||||
files on which the rules are to be applied, with \fB\(en\fR being the
|
||||
standard input. To take rules from the standard input, use \fB\(enf \(en\fR.
|
||||
.PP
|
||||
The command:
|
||||
.HS
|
||||
.Cx "awk rules prog.\d\s+2*\s0\u"
|
||||
.HS
|
||||
would read the patterns and actions rules from the file \fIrules\fR
|
||||
and apply them to all the arguments.
|
||||
.PP
|
||||
The general format of a rules file is:
|
||||
.HS
|
||||
~~~<pattern> { <action> }
|
||||
~~~<pattern> { <action> }
|
||||
~~~...
|
||||
.HS
|
||||
There may be any number of these <pattern> { <action> }
|
||||
sequences in the rules file. \fIAwk\fR reads a line of input from
|
||||
the current input file and applies every <pattern> { <action> }
|
||||
in sequence to the line.
|
||||
.PP
|
||||
If the <pattern> corresponding to any { <action> } is missing,
|
||||
the action is applied to every line of input. The default
|
||||
{ <action> } is to print the matched input line.
|
||||
.SS "Patterns"
|
||||
.PP
|
||||
The <pattern>s may consist of any valid C expression. If the
|
||||
<pattern> consists of two expressions separated by a comma, it
|
||||
is taken to be a range and the <action> is performed on all
|
||||
lines of input that match the range. <pattern>s may contain
|
||||
\*(OQregular expressions\*(CQ delimited by an @ symbol. Regular
|
||||
expressions can be thought of as a generalized \*(OQwildcard\*(CQ
|
||||
string matching mechanism, similar to that used by many
|
||||
operating systems to specify file names. Regular expressions
|
||||
may contain any of the following characters:
|
||||
.HS
|
||||
.in +0.75i
|
||||
.ta +0.5i
|
||||
.ti -0.5i
|
||||
x An ordinary character
|
||||
.ti -0.5i
|
||||
\\ The backslash quotes any character
|
||||
.ti -0.5i
|
||||
^ A circumflex at the beginning of an expr matches the beginning of a line.
|
||||
.ti -0.5i
|
||||
$ A dollar-sign at the end of an expression matches the end of a line.
|
||||
.ti -0.5i
|
||||
\&. A period matches any single character except newline.
|
||||
.ti -0.5i
|
||||
* An expression followed by an asterisk matches zero or more occurrences
|
||||
of that expression: \*(OQfo*\*(CQ matches \*(OQf\*(CQ, \*(OQfo\*(CQ, \*(OQfoo\*(CQ, \*(OQfooo\*(CQ, etc.
|
||||
.ti -0.5i
|
||||
+ An expression followed by a plus sign matches one or more occurrences
|
||||
of that expression: \*(OQfo+\*(CQ matches \*(OQfo\*(CQ, \*(OQfoo\*(CQ, \*(OQfooo\*(CQ, etc.
|
||||
.ti -0.5i
|
||||
[] A string enclosed in square brackets matches any single character in that
|
||||
string, but no others. If the first character in the string is a circumflex, the
|
||||
expression matches any character except newline and the characters in the
|
||||
string. For example, \*(OQ[xyz]\*(CQ matches \*(OQxx\*(CQ and \*(OQzyx\*(CQ, while
|
||||
\*(OQ[^xyz]\*(CQ matches \*(OQabc\*(CQ but not \*(OQaxb\*(CQ. A range of characters may be
|
||||
specified by two characters separated by \*(OQ-\*(CQ.
|
||||
.in -0.75i
|
||||
.SS "Actions"
|
||||
.PP
|
||||
Actions are expressed as a subset of the C language. All
|
||||
variables are global and default to int's if not formally
|
||||
declared.
|
||||
Only char's and int's and pointers and arrays of
|
||||
char and int are allowed. \fIAwk\fR allows only decimal integer
|
||||
constants to be used\(emno hex (0xnn) or octal (0nn). String
|
||||
and character constants may contain all of the special C
|
||||
escapes (\\n, \\r, etc.).
|
||||
.PP
|
||||
\fIAwk\fR supports the \*(OQif\*(CQ, \*(OQelse\*(CQ,
|
||||
\*(OQwhile\*(CQ and \*(OQbreak\*(CQ flow of
|
||||
control constructs, which behave exactly as in C.
|
||||
.PP
|
||||
Also supported are the following unary and binary operators,
|
||||
listed in order from highest to lowest precedence:
|
||||
.HS
|
||||
.ta 0.25i 1.75i 3.0i
|
||||
.nf
|
||||
\fB Operator Type Associativity\fR
|
||||
() [] unary left to right
|
||||
.tr ~~
|
||||
! ~ ++ \(en\(en \(en * & unary right to left
|
||||
.tr ~
|
||||
* / % binary left to right
|
||||
+ \(en binary left to right
|
||||
<< >> binary left to right
|
||||
< <= > >= binary left to right
|
||||
== != binary left to right
|
||||
& binary left to right
|
||||
^ binary left to right
|
||||
| binary left to right
|
||||
&& binary left to right
|
||||
|| binary left to right
|
||||
= binary right to left
|
||||
.fi
|
||||
.HS
|
||||
Comments are introduced by a '#' symbol and are terminated by
|
||||
the first newline character. The standard \*(OQ/*\*(CQ and \*(OQ*/\*(CQ
|
||||
comment delimiters are not supported and will result in a
|
||||
syntax error.
|
||||
.SP 0.5
|
||||
.SS "Fields"
|
||||
.SP 0.5
|
||||
.PP
|
||||
When \fIawk\fR reads a line from the current input file, the
|
||||
record is automatically separated into \*(OQfields.\*(CQ A field is
|
||||
simply a string of consecutive characters delimited by either
|
||||
the beginning or end of line, or a \*(OQfield separator\*(CQ character.
|
||||
Initially, the field separators are the space and tab character.
|
||||
The special unary operator '$' is used to reference one of the
|
||||
fields in the current input record (line). The fields are
|
||||
numbered sequentially starting at 1. The expression \*(OQ$0\*(CQ
|
||||
references the entire input line.
|
||||
.PP
|
||||
Similarly, the \*(OQrecord separator\*(CQ is used to determine the end
|
||||
of an input \*(OQline,\*(CQ initially the newline character. The field
|
||||
and record separators may be changed programatically by one of
|
||||
the actions and will remain in effect until changed again.
|
||||
.PP
|
||||
Multiple (up to 10) field separators are allowed at a time, but
|
||||
only one record separator.
|
||||
.PP
|
||||
Fields behave exactly like strings; and can be used in the same
|
||||
context as a character array. These \*(OQarrays\*(CQ can be considered
|
||||
to have been declared as:
|
||||
.SP 0.15
|
||||
.HS
|
||||
~~~~~char ($n)[ 128 ];
|
||||
.HS
|
||||
.SP 0.15
|
||||
In other words, they are 128 bytes long. Notice that the
|
||||
parentheses are necessary because the operators [] and $
|
||||
associate from right to left; without them, the statement
|
||||
would have parsed as:
|
||||
.HS
|
||||
.SP 0.15
|
||||
~~~~~char $(1[ 128 ]);
|
||||
.HS
|
||||
.SP 0.15
|
||||
which is obviously ridiculous.
|
||||
.PP
|
||||
If the contents of one of these field arrays is altered, the
|
||||
\*(OQ$0\*(CQ field will reflect this change. For example, this
|
||||
expression:
|
||||
.HS
|
||||
.SP 0.15
|
||||
~~~~~*$4 = 'A';
|
||||
.HS
|
||||
.SP 0.15
|
||||
will change the first character of the fourth field to an upper-
|
||||
case letter 'A'. Then, when the following input line:
|
||||
.HS
|
||||
.SP 0.15
|
||||
~~~~~120 PRINT "Name address Zip"
|
||||
.SP 0.15
|
||||
.HS
|
||||
is processed, it would be printed as:
|
||||
.HS
|
||||
.SP 0.15
|
||||
~~~~~120 PRINT "Name Address Zip"
|
||||
.HS
|
||||
.SP 0.15
|
||||
Fields may also be modified with the strcpy() function (see
|
||||
below). For example, the expression:
|
||||
.HS
|
||||
~~~~~strcpy( $4, "Addr." );
|
||||
.HS
|
||||
applied to the same line above would yield:
|
||||
.HS
|
||||
~~~~~120 PRINT "Name Addr. Zip"
|
||||
.HS
|
||||
.SS "Predefined Variables"
|
||||
.PP
|
||||
The following variables are pre-defined:
|
||||
.HS
|
||||
.in +1.5i
|
||||
.ta +1.25i
|
||||
.ti -1.25i
|
||||
FS Field separator (see below).
|
||||
.ti -1.25i
|
||||
RS Record separator (see below also).
|
||||
.ti -1.25i
|
||||
NF Number of fields in current input record (line).
|
||||
.ti -1.25i
|
||||
NR Number of records processed thus far.
|
||||
.ti -1.25i
|
||||
FILENAME Name of current input file.
|
||||
.ti -1.25i
|
||||
BEGIN A special <pattern> that matches the beginning of input text.
|
||||
.ti -1.25i
|
||||
END A special <pattern> that matches the end of input text.
|
||||
.in -1.5i
|
||||
.HS
|
||||
\fIAwk\fR also provides some useful built-in functions for string
|
||||
manipulation and printing:
|
||||
.HS
|
||||
.in +1.5i
|
||||
.ta +1.25i
|
||||
.ti -1.25i
|
||||
print(arg) Simple printing of strings only, terminated by '\\n'.
|
||||
.ti -1.25i
|
||||
printf(arg...) Exactly the printf() function from C.
|
||||
.ti -1.25i
|
||||
getline() Reads the next record and returns 0 on end of file.
|
||||
.ti -1.25i
|
||||
nextfile() Closes the current input file and begins processing the next file
|
||||
.ti -1.25i
|
||||
strlen(s) Returns the length of its string argument.
|
||||
.ti -1.25i
|
||||
strcpy(s,t) Copies the string \*(OQt\*(CQ to the string \*(OQs\*(CQ.
|
||||
.ti -1.25i
|
||||
strcmp(s,t) Compares the \*(OQs\*(CQ to \*(OQt\*(CQ and returns 0 if they match.
|
||||
.ti -1.25i
|
||||
toupper(c) Returns its character argument converted to upper-case.
|
||||
.ti -1.25i
|
||||
tolower(c) Returns its character argument converted to lower-case.
|
||||
.ti -1.25i
|
||||
match(s,@re@) Compares the string \*(OQs\*(CQ to the regular expression \*(OQre\*(CQ and
|
||||
returns the number of matches found (zero if none).
|
||||
.in -1.5i
|
||||
.SS "Authors"
|
||||
.PP
|
||||
\fIAwk\fR was written by Saeko Hirabauashi and Kouichi Hirabayashi.
|
|
@ -1,130 +0,0 @@
|
|||
.so mnx.mac
|
||||
.TH KERMIT 1x
|
||||
.CD "kermit \(en transfer a file using the kermit protocol"
|
||||
.SX "kermit"
|
||||
.FL "\fR(many)"
|
||||
.EY "kermit" "Start kermit"
|
||||
.PP
|
||||
This is a slightly lobotomized \fIkermit\fR.
|
||||
The help command, the script facility, and the automatic dial support
|
||||
have been removed.
|
||||
The ? and ESC commands still work, so there is still reasonable built-in help.
|
||||
The only V7 \fIkermit\fR feature that does not work is the ability to see
|
||||
whether there are input characters waiting. This means that you will not
|
||||
be able to ask for status during a file transfer (though
|
||||
this is not critical, because \fIkermit\fR prints a dot every so often and
|
||||
other special characters whenever there is an error or timeout).
|
||||
.PP
|
||||
Start \fIkermit\fR, and then type the following to open a 2400 baud session,
|
||||
for example:
|
||||
.HS
|
||||
.nf
|
||||
.Cx "set line /dev/tty1"
|
||||
.Cx "set speed 2400"
|
||||
.Cx "connect"
|
||||
.HS
|
||||
.fi
|
||||
(It is more convenient if you put these commands in \fI.kermrc\fR in your
|
||||
home directory, so that they get done automatically whenever you
|
||||
run \fIkermit\fR.) This will connect you to the modem or whatever on
|
||||
the serial port. Now log into the other system.
|
||||
.PP
|
||||
When you want to transfer files, run \fIkermit\fR on the other system.
|
||||
To it, type
|
||||
.HS
|
||||
.Cx "server"
|
||||
.HS
|
||||
This puts its \fIkermit\fR into a sort of \*(OQslave mode\*(CQ where it expects
|
||||
commands from the \fIkermit\fR running on your \s-2MINIX\s0 system. Now come back
|
||||
to the command level on \s-2MINIX\s0 \fIkermit\fR, by typing the escape character
|
||||
followed by \fIc\fR. (\fIKermit\fR will tell you
|
||||
the current escape character when
|
||||
you do the connect command.) At this point you can issue various
|
||||
commands.
|
||||
Your \fIkermit\fR will coordinate things with \fIkermit\fR on the other
|
||||
machine so that you only have to type commands at one end. Common
|
||||
commands are
|
||||
.HS
|
||||
.Cx "get \fI\s+2filename\fP\s0"
|
||||
.br
|
||||
.Cx "put \fI\s+2filename\fP\s0"
|
||||
.br
|
||||
.Cx "remote \fI\s+2dir\fP\s0"
|
||||
.HS
|
||||
\fRFilenames can include wildcards. By default, \fIkermit\fR works in a
|
||||
system-independent, text mode. (In effect it assumes that the
|
||||
whole world is \s-2MS-DOS\s0 and converts end of line and file names
|
||||
accordingly.) To send binary files, you will want to type
|
||||
.HS
|
||||
.Cx "set file type bin"
|
||||
.HS
|
||||
on both ends before starting any transfers. This disables
|
||||
CR LF to newline conversion. If both of your systems are some
|
||||
flavor of \s-2UNIX\s0, you might as well put this in \fI.kermrc\fR on both
|
||||
ends and run in binary mode all the time. Also, if both systems
|
||||
are \s-2UNIX\s0 it is recommended that you use
|
||||
.HS
|
||||
.Cx "set file name lit"
|
||||
.HS
|
||||
on both ends. This causes it to keep file names unchanged,
|
||||
rather than mapping to legal \s-2MS-DOS\s0 names.
|
||||
.PP
|
||||
Here is a typical \fI.kermrc\fR for use on
|
||||
.MX :
|
||||
.HS
|
||||
.nf
|
||||
.Cx "set line /dev/tty1"
|
||||
.Cx "set speed 1200"
|
||||
.Cx "set esc 29"
|
||||
.Cx "set file type bin"
|
||||
.Cx "set file name lit"
|
||||
.Cx "set retry 90"
|
||||
.Cx "set prompt MINIX kermit>"
|
||||
.Cx "connect"
|
||||
.fi
|
||||
.PP
|
||||
On the other end of the line, for example, the host at your local computer
|
||||
center to which you want to transfer files, a typical profile might be:
|
||||
.HS
|
||||
.nf
|
||||
.Cx "set rec packet 1000"
|
||||
.Cx "set fil name lit"
|
||||
.Cx "set fil type bin"
|
||||
.Cx "server"
|
||||
.fi
|
||||
.HS
|
||||
.PP
|
||||
\fIKermit\fR has many other options and features. For a pleasant and
|
||||
highly readable description of it, see the following book:
|
||||
.HS
|
||||
.in +0.25i
|
||||
.nf
|
||||
Title: Kermit: A File Transfer Protocol
|
||||
Author: Frank da Cruz
|
||||
Publisher: Digital Press
|
||||
Date: 1987
|
||||
ISBN: 0-932376-88
|
||||
.fi
|
||||
.in -0.25i
|
||||
.HS
|
||||
.PP
|
||||
For information about recent \fIkermit\fR developments, versions for other
|
||||
systems, and so forth, please contact:
|
||||
.nf
|
||||
.HS
|
||||
.in +0.25i
|
||||
Christine M. Gianone
|
||||
Manager, Kermit Development and Distribution
|
||||
University Center for Computing Activities
|
||||
Columbia University
|
||||
612 West 115th Street
|
||||
New York, N.Y. 10025
|
||||
.in -0.25i
|
||||
.HS
|
||||
.fi
|
||||
Over 400 versions of \fIkermit\fR are available, so it is likely there is one
|
||||
for any computer your
|
||||
.MX
|
||||
system might want to talk to.
|
||||
Columbia University also publishes a newsletter about \fIkermit\fR that can be
|
||||
requested from the above address.
|
File diff suppressed because it is too large
Load diff
|
@ -1,206 +0,0 @@
|
|||
.so mnx.mac
|
||||
.TH MINED 1x
|
||||
.CD "mined \(en \*(M2 editor"
|
||||
.SX "mined\fR [\fIfile\fR]
|
||||
.FL "\fR(none)"
|
||||
.TP 20
|
||||
.B mined /user/ast/book.3
|
||||
# Edit an existing file
|
||||
.TP 20
|
||||
.B mined
|
||||
# Call editor to create a new file
|
||||
.TP 20
|
||||
.B ls \(enl | mined
|
||||
# Use \fImined\fR as a pager to inspect listing
|
||||
.PP
|
||||
\fIMined\fR is a simple screen editor.
|
||||
At any instant, a window of 24 lines is visible on the screen.
|
||||
The current position in the file is shown by the cursor.
|
||||
Ordinary characters typed in are inserted at the cursor.
|
||||
Control characters and keys on the numeric keypad (at the right-hand side
|
||||
of the keyboard) are used to move the cursor and perform other functions.
|
||||
.PP
|
||||
Commands exist to move forward and backward a word, and delete words
|
||||
either in front of the cursor or behind it.
|
||||
A word in this context is a sequence of characters delimited on both ends by
|
||||
white space (space, tab, line feed, start of file, or end of file).
|
||||
The commands for deleting characters and words also work on line feeds, making
|
||||
it possible to join two consecutive lines by deleting the line feed between them.
|
||||
.PP
|
||||
The editor maintains one save buffer (not displayed).
|
||||
Commands are present to move text from the file to the buffer, from the buffer
|
||||
to the file, and to write the buffer onto a new file.
|
||||
If the edited text cannot be written out due to a full disk, it may still
|
||||
be possible to copy the whole text to the save buffer and then write it to a
|
||||
different file on a different disk with CTRL-Q.
|
||||
It may also be possible to escape from the editor with CTRL-S and remove
|
||||
some files.
|
||||
.PP
|
||||
Some of the commands prompt for arguments (file names, search patterns, etc.).
|
||||
All commands that might result in loss of the file being edited prompt to ask
|
||||
for confirmation.
|
||||
.PP
|
||||
A key (command or ordinary character) can be repeated
|
||||
.I n
|
||||
times by typing
|
||||
.I "ESC n key"
|
||||
where
|
||||
.I ESC
|
||||
is the \*(OQescape\*(CQ key.
|
||||
.PP
|
||||
Forward and backward searching requires a regular expression as the search
|
||||
pattern.
|
||||
Regular expressions follow the same rules as in the
|
||||
.Ux
|
||||
editor,
|
||||
.I ed .
|
||||
These rules can be stated as:
|
||||
.LI
|
||||
.IT
|
||||
Any displayable character matches itself.
|
||||
.IT
|
||||
\&. (period) matches any character except line feed.
|
||||
.IT
|
||||
\&^ (circumflex) matches the start of the line.
|
||||
.IT
|
||||
\&$ (dollar sign) matches the end of the line.
|
||||
.IT
|
||||
\&\\c matches the character \fIc\fR (including period, circumflex, etc).
|
||||
.IT
|
||||
[\fIstring\fR] matches any of the characters in the string.
|
||||
.IT
|
||||
[^string] matches any of the characters except those in the string.
|
||||
.IT
|
||||
[\fIx\(eny\fR] matches any characters between \fIx\fR and \fIy\fR (e.g., [\fIa\(enz\fR]).
|
||||
.IT
|
||||
Pattern\(** matches any number of occurrences of \fIpattern\fR.
|
||||
.LX
|
||||
Some examples of regular expressions are:
|
||||
.HS
|
||||
.in +1.25i
|
||||
.ta +1.0i
|
||||
.ti -1.0i
|
||||
The boy matches the string \*(OQThe boy\*(CQ
|
||||
.ti -1.0i
|
||||
^$ matches any empty line.
|
||||
.ti -1.0i
|
||||
^.$ matches any line containing exactly 1 character
|
||||
.ti -1.0i
|
||||
^A.*\\.$ matches any line starting with an \fIA\fR, ending with a period.
|
||||
.ti -1.0i
|
||||
^[A\(enZ]*$ matches any line containing only capital letters (or empty).
|
||||
.ti -1.0i
|
||||
[A\(enZ0\(en9] matches any line containing either a capital letter or a digit.
|
||||
.ti -1.0i
|
||||
\&.*X$ matches any line ending in \*(OQX\*(CQ
|
||||
.ti -1.0i
|
||||
A.*B matches any line containing an \*(OQA\*(CQ and then a \*(OQB\*(CQ
|
||||
.in -1.25i
|
||||
.sp
|
||||
.PP
|
||||
Control characters cannot be entered into a file simply by typing them because
|
||||
all of them are editor commands.
|
||||
To enter a control character, depress the ALT key, and then while holding it
|
||||
down, hit the ESC key.
|
||||
Release both ALT and ESC and type the control character.
|
||||
Control characters are displayed in reverse video.
|
||||
.PP
|
||||
The
|
||||
.I mined
|
||||
commands are as follows.
|
||||
.sp
|
||||
.in +1.25i
|
||||
.ta +1.0i
|
||||
.ti -1.25i
|
||||
\fBCURSOR MOTION\fR
|
||||
.ti -1.0i
|
||||
\fBarrows\fR Move the cursor in the indicated direction
|
||||
.ti -1.0i
|
||||
\fBCTRL-A\fR Move cursor to start of current line
|
||||
.ti -1.0i
|
||||
\fBCTRL-Z\fR Move cursor to end of current line
|
||||
.ti -1.0i
|
||||
\fBCTRL-^\fR Move cursor to top of screen
|
||||
.ti -1.0i
|
||||
\fBCTRL-_\fR Move cursor to end of screen
|
||||
.ti -1.0i
|
||||
\fBCTRL-F\fR Move cursor forward to start of next word
|
||||
.ti -1.0i
|
||||
\fBCTRL-B\fR Move cursor backward to start of previous word
|
||||
|
||||
.ti -1.25i
|
||||
\fBSCREEN MOTION\fR
|
||||
.ti -1.0i
|
||||
\fBHome key\fR Move to first character of the file
|
||||
.ti -1.0i
|
||||
\fBEnd key\fR Move to last character of the file
|
||||
.ti -1.0i
|
||||
\fBPgUp key\fR Scroll window up 23 lines (closer to start of the file)
|
||||
.ti -1.0i
|
||||
\fBPgDn key\fR Scroll window down 23 lines (closer to end of the file)
|
||||
.ti -1.0i
|
||||
\fBCTRL-U\fR Scroll window up 1 line
|
||||
.ti -1.0i
|
||||
\fBCTRL-D\fR Scroll window down 1 line
|
||||
|
||||
.ti -1.25i
|
||||
\fBMODIFYING TEXT\fR
|
||||
.ti -1.0i
|
||||
\fBDel key\fR Delete the character under the cursor
|
||||
.ti -1.0i
|
||||
\fBBackspace\fR Delete the character to left of the cursor
|
||||
.ti -1.0i
|
||||
\fBCTRL-N\fR Delete the next word
|
||||
.ti -1.0i
|
||||
\fBCTRL-P\fR Delete the previous word
|
||||
.ti -1.0i
|
||||
\fBCTRL-T\fR Delete tail of line (all characters from cursor to end of line)
|
||||
.ti -1.0i
|
||||
\fBCTRL-O\fR Open up the line (insert line feed and back up)
|
||||
.ti -1.0i
|
||||
\fBCTRL-G\fR Get and insert a file at the cursor position
|
||||
|
||||
.ti -1.25i
|
||||
\fBBUFFER OPERATIONS\fR
|
||||
.ti -1.0i
|
||||
\fBCTRL-@\fR Set mark at current position for use with CTRL-C and CTRL-K
|
||||
.ti -1.0i
|
||||
\fBCTRL-C\fR Copy the text between the mark and the cursor into the buffer
|
||||
.ti -1.0i
|
||||
\fBCTRL-K\fR Delete text between mark and cursor; also copy it to the buffer
|
||||
.ti -1.0i
|
||||
\fBCTRL-Y\fR Yank contents of the buffer out and insert it at the cursor
|
||||
.ti -1.0i
|
||||
\fBCTRL-Q\fR Write the contents of the buffer onto a file
|
||||
|
||||
.ti -1.25i
|
||||
\fBMISCELLANEOUS\fR
|
||||
.ti -1.0i
|
||||
\fBnumeric +\fR Search forward (prompts for regular expression)
|
||||
.ti -1.0i
|
||||
\fBnumeric \(mi\fR Search backward (prompts for regular expression)
|
||||
.ti -1.0i
|
||||
\fBnumeric 5\fR Display the file status
|
||||
.ti -1.0i
|
||||
\fBCTRL-]\fR Go to specific line
|
||||
.ti -1.0i
|
||||
\fBCTRL-R\fR Global replace \fIpattern\fR with \fIstring\fR (from cursor to end)
|
||||
.ti -1.0i
|
||||
\fBCTRL-L\fR Line replace \fIpattern\fR with \fIstring\fR
|
||||
.ti -1.0i
|
||||
\fBCTRL-W\fR Write the edited file back to the disk
|
||||
.ti -1.0i
|
||||
\fBCTRL-X\fR Exit the editor
|
||||
.ti -1.0i
|
||||
\fBCTRL-S\fR Fork off a shell (use CTRL-D to get back to the editor)
|
||||
.ti -1.0i
|
||||
\fBCTRL-\\\fR Abort whatever the editor was doing and wait for command
|
||||
.ti -1.0i
|
||||
\fBCTRL-E\fR Erase screen and redraw it
|
||||
.ti -1.0i
|
||||
\fBCTRL-V\fR Visit (edit) a new file
|
||||
.in -1.25i
|
||||
|
||||
.SS "Author"
|
||||
.PP
|
||||
\fIMined\fR was designed by Andy Tanenbaum and written by Michiel Huisjes.
|
Loading…
Reference in a new issue