🚨 Oracle not porting Rdb to x86 and EOL on Itanium 12/2027 🚨

The EDT Editor, Rebuilt for Modern Systems

Faithful DEC OpenVMS EDT for Linux and macOS: drop-in commands, ncurses screen mode, GOLD keypad, and extensions — migrated apps keep running without retraining.
edit source.cob
$ edit source.cob
EDIT/EDT source.cob
1  IDENTIFICATION DIVISION.
* FIND "PROCEDURE"
4  PROCEDURE DIVISION.
* SUBSTITUTE/GLOBAL "SECTION" "BLOCK"
3 substitutions
* DEFINE MACRO TIDY AS "TOP; FIND TODO; SUBSTITUTE DONE"
* TIDY
Substituted
* EXIT
source.cob written — 312 lines
Capabilities

Everything EDT, and more

VX/EDT implements the full OpenVMS EDT command set plus modern extensions for case-insensitive search, global substitution, redo, paragraph fill, and direct printer output.

🖥️

Line & Screen Modes

Starts in EDT line mode with the familiar * prompt. CHANGE enters full ncurses screen mode with GOLD-key keypad emulation. Ctrl/Z returns to line mode at any time.

🔍

Stateful Search

FIND sets the active search string. FNDNXT repeats in the current direction. ADVANCE and BACKUP control direction. Case-sensitive or general search via SET SEARCH.

♻️

Unlimited Undo & Redo

100-level undo stack captures complete editor state — buffers, cursor, direction, selection, and delete buffers. Full redo stack is built on every undo; cleared on any new mutating command.

📋

Named Buffers

The PASTE buffer provides clipboard functionality. User-named buffers (FIND =TEMP) hold arbitrary text. COPY, MOVE, and CLEAR manage content between buffers.

⌨️

Key & Macro Definitions

Redefine any PF key, GOLD+key, or Ctrl key combination with DEFINE KEY. Chain commands into named macros with DEFINE MACRO. Loaded automatically from EDT.INI.

🛠️

Modern Extensions

Global substitute with /GLOBAL, per-match confirmation with /QUERY, paragraph reformat with FILL, line printer output with PRINT, overstrike mode, and horizontal scroll.

Reference

Line-Mode Command Reference

All commands are case-insensitive. Qualifiers may be appended to any command.

Display TYPE

CommandDescription
TYPEDisplay current line
TYPE nDisplay line n
TYPE a THRU bDisplay lines a through b
TYPE RESTDisplay from cursor to end of buffer
TYPE WHOLEDisplay entire buffer

Navigation

CommandDescription
nMove cursor to line n
TOPMove to first line
BOTTOMMove to last line
ADVANCESet direction forward
BACKUPSet direction backward

Substitute

CommandDescription
SUBSTITUTE replReplace next match
SUBSTITUTE/GLOBAL replReplace all occurrences
SUBSTITUTE/QUERY replConfirm each replacement

Insert & Fill

CommandDescription
INSERT textInsert text at cursor
FILLReformat paragraph to terminal width

Delete

CommandDescription
DELETEDelete current line
DEL WDelete word forward
DEL CDelete character at cursor
DEL EOLDelete to end of line

Clipboard

CommandDescription
SELECTAnchor select range
CUTMove to PASTE buffer
PASTEInsert PASTE buffer at cursor

Undo & Redo

CommandDescription
UNDORestore to before last command (100 levels)
REDORe-apply last undone change

Buffer Management

CommandDescription
FIND =NAMESwitch to named buffer
COPY range TO =NAMECopy lines to named buffer
MOVE range TO =NAMEMove lines to named buffer

File I/O

CommandDescription
INCLUDE filenameInsert file at cursor
WRITE filenameWrite buffer to file
PRINTSend buffer to printer

Settings

CommandDescription
SET NUMBERSEnable line numbers
SET OVERSTRIKEOverwrite mode
SET INSERTInsert mode (default)

Macros & Keys

CommandDescription
DEFINE KEY key AS "cmd"Bind key to command
DEFINE MACRO NAME AS "cmds"Define named macro
SHOW MACROSList all macros

Exit

CommandDescription
EXITSave and exit
QUITExit without saving
CHANGEEnter screen mode
Qualifiers

Command Qualifiers

Qualifiers may be placed anywhere in a command and multiple qualifiers can be combined.

/QUERY
Prompt Y/N before each SUBSTITUTE replacement
/GLOBAL
Apply SUBSTITUTE to all occurrences
/NOTYPE
Suppress all output
/BRIEF
Terse output format
/SAVE
Auto-save after command
Screen Mode

Keypad & Screen Mode Reference

Enter with CHANGE. Return to line mode with Ctrl/Z. GOLD key is F1/PF1.

🔑 PF Keys
KeyAction
F1/PF1GOLD prefix
F2/PF2HELP screen
F3/PF3FNDNXT
F4/PF4Delete line
GOLD+F3FIND prompt
GOLD+F4Undelete line
↑↓ Cursor
KeyAction
Arrow keysMove one position
HomeBeginning of line
EndEnd of line
GOLD+TOP
GOLD+BOTTOM
⌨️ Ctrl Keys
KeyAction
Ctrl/AToggle insert/overstrike
Ctrl/EEnd of line
Ctrl/FFNDNXT
Ctrl/KDelete to EOL
Ctrl/ZReturn to line mode
🔢 Numeric Keypad
KeyAction
Kp 0LINE move
Kp 1WORD move
Kp 6CUT to PASTE
Kp .SELECT anchor
Kp -DEL W
Configuration

Startup & Configuration

VX/EDT reads EDT.INI at startup and accepts a command file for batch use.

Invocation

SyntaxDescription
edit file.txtOpen file interactively
edit file -command cmds.edtRun command file then interactive

EDT.INI Example

~/EDT.INI
SET SEARCH GENERAL
SET NUMBERS
DEFINE KEY GOLD Q AS "QUIT"
DEFINE KEY GOLD E AS "EXIT"
DEFINE MACRO TIDY AS "SET NUMBERS; TYPE WHOLE"
Build

Building VX/EDT

Single-file C++17 source. Requires ncurses.

macOS / Clang
clang++ -std=c++17 -Wall -O2 edt.cpp -lncurses -o edt
Linux / GCC
g++ -std=c++17 -Wall -O2 edt.cpp -lncurses -o edt

Requirements

  • C++17 or later
  • ncurses or ncursesw
  • POSIX — macOS 12+, Linux glibc 2.17+
  • No external runtime dependencies

Frequently Asked Questions

Curious about how Sector7 can facilitate your application migration? Explore our FAQs for expert insights.

What is VX/EDT and when would I use it?

VX/EDT is Sector7’s faithful reimplementation of the DEC OpenVMS EDT editor for Linux and macOS. It preserves familiar line-mode commands, ncurses screen mode, GOLD-key keypad behaviour, and common qualifiers so teams moving off OpenVMS can keep the same editing workflow on POSIX systems.

For the broader platform picture—languages, runtimes, and production cutover—see Sector7’s overview of OpenVMS to Linux and UNIX migration and the technical tools directory.

Do OpenVMS EDT line-mode commands work the same way in VX/EDT?

Yes. VX/EDT is built around a drop-in compatible command set: navigation, FIND / FNDNXT, SUBSTITUTE with qualifiers such as /GLOBAL and /QUERY, buffer operations, INCLUDE / WRITE, and the usual range syntax (THRU, WHOLE, REST, and so on). Commands remain case-insensitive, matching OpenVMS EDT expectations.

Enter full-screen editing with CHANGE or C; return to the asterisk prompt with Ctrl/Z. The on-page command reference summarises behaviour for quick lookup.

How does the GOLD key work on a PC or Mac keyboard?

On OpenVMS terminals, GOLD is typically F1 / PF1. VX/EDT follows the same model: press GOLD, then the second key (for example GOLD+F2 for BOTTOM, or GOLD plus keypad keys in screen mode).

On laptops without a dedicated function row, use Fn with F1 as needed. The Screen Mode section on this page lists PF keys, cursor GOLD combinations, Ctrl keys, and GOLD+keypad bindings for day-to-day reference.

Where does VX/EDT read EDT.INI from?

At startup VX/EDT checks, in order: the path in the $EDT_INI environment variable (if set), then $HOME/EDT.INI, then $HOME/edt.ini. Lines beginning with !, #, or ; are treated as comments—in both EDT.INI and -command script files.

Use DEFINE KEY and DEFINE MACRO entries to persist PF-key, GOLD, and Ctrl bindings across sessions. The Startup & Configuration section documents invocation flags and a sample EDT.INI.

Can VX/EDT run from a command file or non-interactive workflow?

Yes. Launch with edit <file> -command <script> (or the -command=<script> form) to execute a sequence of EDT commands—useful for scripted edits, repeatable migration steps, or CI-style checks alongside other tooling.

For larger automation and assessment across a codebase, many teams pair editor workflows with LegacyScan and Sector7’s broader toolset bundles.

How do undo and redo work in VX/EDT?

UNDO (U) restores the editor to the state before the last text-changing command, with up to 100 levels of history. Each undo pushes the current state onto a redo stack so REDO can re-apply the last undone change.

Captured state includes buffer contents, named buffers, cursor position, direction, selection anchor, active search string, and delete buffers—mirroring the depth teams expect from OpenVMS EDT-style editing.

What is required to build VX/EDT from source?

VX/EDT ships as a single-file C++17 source module linked against ncurses (available by default on macOS and typical Linux distributions). A POSIX toolchain—clang++ or g++—is sufficient; there are no additional runtime dependencies beyond the OS curses library.

The optional PRINT command expects a working lpr or lp line-printer interface when used. Exact compiler examples appear in the Building VX/EDT section on this page.

Where can I get help with a larger OpenVMS migration beyond the editor?

VX/EDT removes a common friction point—keeping the EDT editing experience on modern platforms—but most production moves also involve languages, system services, databases, and operational cutover. Sector7 has delivered large-scale OpenVMS migrations since the 1980s using proprietary converters and proven methodology.

Explore migration services (including the assessment process and zero code freeze approach), browse the VX/TOOLS technical catalog, and contact us to discuss scope, timelines, and tooling fit.

Transform Your Legacy Software Today!

Get In Touch
Unlock the potential of your legacy software with our expert migration services.