149 lines
4.0 KiB
HTML
149 lines
4.0 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta name="description" content="MontaukOS manual page: edit(1) - text editor for MontaukOS">
|
|
<title>edit(1) - MontaukOS Manual</title>
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600&display=swap" rel="stylesheet">
|
|
<style>
|
|
body {
|
|
font-family: 'Open Sans', Arial, sans-serif;
|
|
max-width: 960px;
|
|
margin: 0 auto;
|
|
padding: 1em;
|
|
line-height: 1.5;
|
|
display: flex;
|
|
gap: 2em;
|
|
}
|
|
p { margin: 0 0 0.5em; }
|
|
h2 { margin: 0.5em 0; }
|
|
.sidebar {
|
|
width: 160px;
|
|
flex-shrink: 0;
|
|
}
|
|
.sidebar ul {
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
.sidebar li {
|
|
margin: 0.5em 0;
|
|
}
|
|
.sidebar a {
|
|
color: #0066CC;
|
|
text-decoration: none;
|
|
font-weight: 600;
|
|
}
|
|
.sidebar a:hover {
|
|
color: #004499;
|
|
text-decoration: underline;
|
|
}
|
|
.sidebar .current {
|
|
color: #004499;
|
|
}
|
|
.sidebar hr {
|
|
border: none;
|
|
border-top: 1px solid #999;
|
|
margin: 0.75em 0;
|
|
}
|
|
.main {
|
|
flex: 1;
|
|
min-width: 0;
|
|
}
|
|
a { color: #0000EE; }
|
|
a:visited { color: #0066CC; }
|
|
hr { border-style: solid; border-width: 1px 0 0 0; border-color: #999; }
|
|
pre { background: #f0f0f0; padding: 0.5em; overflow-x: auto; }
|
|
code { background: #f0f0f0; padding: 0 0.15em; }
|
|
pre code { padding: 0; }
|
|
.center { text-align: center; }
|
|
.box {
|
|
border: 1px solid #999;
|
|
padding: 0.5em;
|
|
margin: 0.5em 0;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
|
|
<div class="sidebar">
|
|
<ul>
|
|
<li><a href="../../index.html">Home</a></li>
|
|
<li><a href="../index.html">Documentation</a></li>
|
|
</ul>
|
|
<hr>
|
|
<ul>
|
|
<li><a href="index.html" class="current">Man Pages</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="main">
|
|
<div class="center">
|
|
<h1>edit(1)</h1>
|
|
</div>
|
|
|
|
<hr>
|
|
|
|
<pre><code><strong>NAME</strong>
|
|
edit - text editor for MontaukOS
|
|
|
|
<strong>SYNOPSIS</strong>
|
|
edit [filename]
|
|
|
|
<strong>DESCRIPTION</strong>
|
|
edit is an interactive text editor. When invoked with a filename,
|
|
it opens the file for editing. If the file does not exist, a new
|
|
empty buffer is created and will be saved to that path on write.
|
|
|
|
When invoked without arguments, edit opens an empty buffer. You
|
|
will be prompted for a filename when saving.
|
|
|
|
<strong>KEYBOARD SHORTCUTS</strong>
|
|
|
|
<strong>Navigation</strong>
|
|
Arrow Keys Move cursor up/down/left/right
|
|
Home Move to start of line
|
|
End Move to end of line
|
|
Page Up Scroll up one page
|
|
Page Down Scroll down one page
|
|
|
|
<strong>Editing</strong>
|
|
Backspace Delete character before cursor
|
|
Delete Delete character at cursor
|
|
Enter Insert new line
|
|
Tab Insert 4 spaces
|
|
|
|
<strong>Commands</strong>
|
|
Ctrl+S Save file
|
|
Ctrl+Q Quit (warns if unsaved changes)
|
|
Ctrl+F Search for text
|
|
Ctrl+G Find next occurrence
|
|
|
|
<strong>DISPLAY</strong>
|
|
The top line shows the filename, a modified indicator [+],
|
|
and the current cursor position (Ln, Col).
|
|
|
|
The bottom line shows keyboard shortcuts or status messages.
|
|
|
|
Line numbers are displayed in a gutter on the left side.
|
|
Lines past the end of the file are marked with ~.
|
|
|
|
<strong>EXAMPLES</strong>
|
|
edit intro.1 Edit a file
|
|
edit Open a new empty buffer
|
|
|
|
<strong>SEE ALSO</strong>
|
|
cat(1), shell(1)</code></pre>
|
|
|
|
<hr>
|
|
|
|
<div class="center">
|
|
<a href="../index.html">Back to Documentation Index</a>
|
|
</div>
|
|
|
|
</div>
|
|
</body>
|
|
</html>
|