Microsoft Store
 

Ed


 

The text editor ed was the original standard on the UNIX operating system. ed was originally written by Ken Thompson and he implemented regular expression in ed for the first time. Prior to that implementation, the concept of regular expressions was only formalized in a mathematical paper, which Ken Thompson had read. ed was influenced by an earlier editor known as QED from University of California at Berkeley, where Ken Thompson had graduated from. ed went on to influence ex, which in turn spawned vi. The non-interactive UNIX commands grep and sed were inspired by common special uses of ed; their influence is visible in the design of the programming language AWK, which in turn inspired aspects of Perl.

Related Topics:
Text editor - UNIX - Ken Thompson - Regular expression - QED - Ex - Vi - Grep - Sed - AWK - Perl

~ ~ ~ ~ ~ ~ ~ ~ ~ ~

Famous for its terseness, ed has almost no visual feedback. For example, the message that ed will produce in case of error, or when it wants to make sure you want to quit without saving, is "?". It does not report the current filename or line number, or even display the results of a change to the text, unless requested. This terseness was appropriate in the early versions of UNIX, when consoles were teletypes, modems were slow, and hard disk and memory were precious, but these advantages ceased to apply when more interactive editors became the standards.

Related Topics:
Teletype - Modem - Hard disk - Memory

~ ~ ~ ~ ~ ~ ~ ~ ~ ~

In current practice ed is rarely used interactively, but it does find use in some shell scripts. For interactive use, ed was subsumed by sam, vi and Emacs editors in the 1980s. ed can be found on virtually every version of UNIX and Linux available; people who have to work with multiple versions of UNIX often know at least the basic ed commands. If something goes wrong, and the OS is somehow not fully loaded, ed is sometimes the only editor available. This is often the only time when it is used interactively, aside maybe from torturing first year students.

Related Topics:
Shell script - Sam - Vi - Emacs - 1980s - Linux

~ ~ ~ ~ ~ ~ ~ ~ ~ ~

The ed commands are often imitated in other line-based editors. For example, EDLIN in early MS-DOS versions had somewhat similar syntax, and text editors in many MUDs (LPMud and descendants, for example) use ed-like syntax. These editors, however, are typically more limited in function.

Related Topics:
EDLIN - MS-DOS - MUD - LPMud

~ ~ ~ ~ ~ ~ ~ ~ ~ ~