GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
ECCE(1) FreeBSD General Commands Manual (con) ECCE(1)

ecce
Edinburgh Compatible Context Editor

ecce -from inputfile [-to outputfile] [-log logfile] [-size bytes]

ecce is a line-based text editor. It first appeared many years ago at the University of Edinburgh, and has been re-implemented many times. Thuis manual page does not attempt to be an ecce tutorial; it merely details how to invoke ecce, and summarises the basic commands. For more details, see the full documentation.

When invoking ecce, there is no need to precede arguments with flags if they are given in the order shown above. If an argument is omitted, the next agument must be specified using the appropriate flag.

To create a new file, an empty input file must be specified. A suitable file is /dev/null.

The operation of ecce is directed by a series of commands which are typed by the user. Each command line consists of a single command, or a sequence of several commands terminated by a newline. No command separator is required between individual commands, and unquoted spaces are not significant. The individual commands in a command sequence are executed from left to right. The basic editing commands consist of a letter, or a letter followed by a text string. The letter is mnemonic for an imperative verb. The text string is any sequence of characters (excluding newline) enclosed within quotation marks. Any command may be followed by a repetition number to indicate that the command is to be executed repeatedly the number of times specified. Compound commands may be formed by enclosing a sequence of commands within parentheses.

In the following list, the Notes column indicates the notes pertaining to the particular command. These can indicate how a command can `fail', or other relevant information about the command.
Command Effect Notes
m{n} move to next line 1
m-{n} move to previous line 2
f{m}'....'{n} find text 3,10
s'....' substitute text 4
g{n} get line 5
k{n} kill (delete) whole line 1
i'....'{n} insert text 6
b break line (insert newline)
d{m}'....'{n} delete text 3,7
j join (delete next newline) 6
p{n} print line 1
r{n} move right 8
l{n} move left 9
e{n} erase right 8
e-{n} erase left 9
t{m}'....'{n} traverse text 3,7
u{m}'....'{n} uncover (delete until) text 3,7
v'....' verify (test for) text

Note Information
1 file pointer at end of file
2 current line is first line of file
3 text not found
4 no text to replace
5 entered line begins with a:
6 current line too long
7 default scope is current line
8 file pointer at end of current line
9 file pointer at beginning of current line
10 default scope is rest of file

Command Effect
%a abort (abandon editing)
%c close (finish editing)
%v print the current version number of ecce

Sequences of commands may be enclosed in parentheses to form compound commands.

Commands may be repeated, unconditionally or conditionally.

Operation Example Meaning/Effect
0 or * indefinite repetition
(repeat until failure)"
r0 move file pointer to end of line
(mr)0 find first blank line
e-0 erase backwards to start of line

? optional execution
(failure condition is ignored)
((r61p)?m)0 print lines with more than 60 characters

, alternative execution
(if first fails, execute next etc.)
(r81lb,m)0 split lines with more than 80 characters
(f/print/(v/printstring/,e5i/write/))*
replace print by write except in printstring

\ inverted failure
(mv'+'\)0 find next line starting with `+'

A command line consisting solely of a number repeats the previous command line the number of times specified.

Patterns may be delimited by any character except letters, digits and those which have defined significance: for example, one can use:
" / $ > + . : = _

/tmp/eccesaveNNNNNN
Emergency save file. This is used when ecce cannot write to the original file being edited. NNNNNN is the zero-filled process ID.
/tmp/eccenoteXNNNNNN
Context file. These are used for holding secondary contexts, and are not deleted when ecce exits. X is the context number, and NNNNNN is the zero-filled process ID.

The ecce utility exits 0 on success, and >0 if an error occurs.

G. Toal, A quick guide to G.Toal's ECCE-in-C for existing ECCE users.

Hamish Dewar, ECCE - revised specification, 1982.

L.D. Smith, ECCE - The Edinburgh Compatible Context Editor, 1978.

G. Toal, ECCE - a review.

Note that only the first reference is definitive for this implementation, so some commands may be missing (or added) elsewhere. However, the other documents may provide a good way of learning how to use ecce effectively.

This implementation is by Graham Toal, of the Edinburgh Computer History Project. It is based on earlier implementations by H. Dewar, University of Edinburgh, and H. Whitfield, University of Newcastle upon Tyne.
September 11, 2016 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.