Want to quickly update a configuration file or edit a solution or project file? Then Microsoft Edit is the ultimate choice. It is a lightweight and easy-to-use text editor from the command line. You can do all this without ever having to switch context.
How to Install:
Plans are to add it to Windows OS soon, making it useful in places where third-party software can’t be installed.
For now, the easiest option to install this editor is using winget:
winget install Microsoft.Edit
Manual Installation:
v1.1.0 is the latest release as of this writing.
You can also install it manually. Download the executable from the official GitHub repo. Then, copy it to any directory in your PATH environment variable.
For Linux, download the TAR archive from the release page and set it up.
# Download the package
wget https://github.com/microsoft/edit/releases/download/v1.1.0/edit-1.1.0-x86_64-linux-gnu.tar.zst
# Extract the archive
tar xvf edit-1.1.0-x86_64-linux-gnu.tar.zst
# Include it in the bin directory for anywhere access
# Have extracted to the user's home directory, adjust the path accordingly
sudo ln -s ~/edit /usr/bin/edit
# Launch the editor
edit
Usage:
The executable is named edit.exe, which sounds familiar to the MS-DOS editor. So once installed, type edit to launch the editor or edit <filename> to open the file for editing.
Features:
- It’s a command-line text editor with full mouse mode support.
- Ability to manage multiple open files and switch easily between them
- Use shortcut key
Ctrl + P - Click on the filename on the bottom right of the status bar to bring up the open file list
- Document Picker menu item from the View menu
- Use shortcut key
- Set file line endings to CRLF or LF.
- Set file encoding
- Set custom tab size
- Support for standard editor functions
- Undo
- Redo
- Cut
- Copy
- Paste
- Select All
- Go to Line/Column
- Support for Find and Replace
- With the Casing and RegEx options
- Word Wrap support (
Alt + Z)
Happy coding. Stay connected as we continue to learn and share the experiences from this exciting journey of being a .NET developer.
One reply on “How to Install and Use Microsoft Edit for Simple CLI Text Edits”
[…] How to Install and Use Microsoft Edit for Simple CLI Text Edits (Vijay Anand E G) […]