Edit is now open source
35 comments
·May 19, 2025computatrum
01HNNWZ0MV43FF
I'd say the windows crate is even technically first-party since the OS vendor publishes it
massysett
Nitpick - this is a text user oriented (TUI) or a screen editor, not a CLI editor. A CLI editor is ed(1), or ex(1), or EDLIN for MS-DOS lineage.
arghwhat
Yay for finally having a default text editor that works over ssh. Managing windows servers over ssh is a bit of a pain without.
They could just have packaged nano, but oh well.
red_admiral
I was about to say, I use nano regularly, both locally and over ssh (to machines which have it installed, which is pretty much all of them). This looks nice and I love old-style console UIs, I fondly remember EDIT.COM and NC.EXE, and still use `mc` regularly with one pane pointing at a sshfs.
Ages ago I had to maintain a .BAT file, editing in EDIT.COM, that threw stuff at EDLIN.COM (roughly MS version of `ed`). Those where the ... not-so-good old days.
These days, with windows versions of `nano` and `busybox` you have some power tools without a full linux install.
yjftsjthsd-h
Ah, that makes sense then; I was really confused at first because I couldn't figure out why Windows would want a built-in text-mode editor. I suppose if folks are seriously using SSH to access Windows machines ... then I have other questions about why not RDP, but if that's a real thing people are doing then adding a built-in editor for them makes sense.
lysace
Calling it now: 2025 will be the year of Windows on the server. /s
dijit
Aside from Windows being... "windows" (IE; graphical) and the whole "we will do our own paradigm for nearly everything including file paths (UUNC included) and encoding... Windows is actually pretty stellar if you're writing high performance software.
You can go really far with IOCP and it's so nice to write compared to the contemporary kqueue (BSD) or epoll. I will admit to not trying IO_Uring myself though.
Also the Windows system probes predate any kind of bpf and are easier to use than dtrace.
This is the maximum amount of love I will ever send in Windows' direction though. Everything else is ball-busting.
90s_dev
Interesting how we always go in circles.
edit.cmd was one of the first programs I ever used.
Now it's back rewritten as a Windows 10+ program in Rust?
Yet it looks and works just the same as 30 years ago!
dbuxton
I can't wait for the Rust port of QBasic Gorillas
red_admiral
This is a denial-of-service attack on my productivity :)
I fondly remember the times of editing the explosion radius to "tactical nuclear banana".
trinix912
I wonder what prevented them from porting the ms-dos EDIT.COM to 64bit Windows back then. There's still EDLIN.COM in the 32bit version.
zozbot234
DOS-era codebases are just terrible in a modern context, they would have to rewrite it from scratch anyway. The TUI IDE included within FreePascal is basically bitrotting due to this very reason.
tadfisher
They canceled the 64-bit port of NTVDM (virtual DOS machine), which is what handles all those INT 21h syscalls from DOS applications. Without that, there's honestly not much to port, and it's easier to just make a new NT-native CLI app.
90s_dev
Did they cancel it because dosbox exists? If so, that's smart.
kmeisthax
Most likely because Microsoft didn't consider it a valuable use of engineering time in general.
AMD's 64-bit extensions explicitly forbade dropping to 16-bit code. Once you enter 64-bit mode you lose access to all the modes which NTVDM needs to run MS-DOS or 3.x apps.
AFAIK the virtualization extensions added in 64-bit (known as VT-x etc) do allow 16-bit code, but that would require rebuilding NTVDM as a Hyper-V client (ala WSL2) instead of using 32-bit protected mode as a way to virtualize 16-bit code. However, these extensions didn't exist until way later and they didn't get support for booting 16-bit guests until later than that.
You could software emulate x86 to do NTVDM stuff. In fact, there's a FOSS program that does this, called WineVDM[0]. The MIPS/Alpha/PPC ports of NT used software emulation in NTVDM, so it is feasible.
[0] https://github.com/otya128/winevdm
Interestingly, they also recommend using DOSBox for DOS apps.
tored
Oh nice! Can't wait to replace nano. Plugin support in lua?
90s_dev
I hope someone adds typed Lua support and sends a PR!
Ericson2314
Will the old one from DOS be replaced entirely with this?
fredoralive
64 bit Windows, the only sort now with W11, doesn’t have MS-DOS support, so doesn’t have the old edit to start with.
andrewstuart
Edit for DOS was my favorite editor.
All the keys worked as you expect. You could select text with shift. It had find and a replace. That’s a lot more than most editors give you without config fiddling and arcane key commands.
Those simple things get almost everything I need for operating system maintenance.
Edit was the pure distilled essence of an editor.
It was a work of art really.
sedatk
It was okay when it came out because the alternative was EDLIN (DOS version of ed). But IIRC, it had a 64KB file size limitation which was a problem.
GuinansEyebrows
cute. extremely NIH in a field with many existing options, but very cute :)
mixmastamyk
What happened to shipping yedit? From the yori project, which I recommend to everyone on windows. Why wait when it has been available for years?
(Someone mentioned ssh, which leads me to believe this one is using ansi instead of the console API.)
QuiCasseRien
> Open Source, writen and build at Microsoft.
Oh yeah, i will get some C# or C++ code !
> Rust
Fucked. Why Why Why ?
lblume
I can see why people don't like to write Rust. It is more tedious, harder because of the ownership model, and has a very steep learning curve.
What I don't get is what people have against programs written in Rust from the bottom up. They are safer to use, introduce far fewer vulnerabilities, and you can even locally reason about the code much better than in typical 'unsafe' languages like C++.
eikenberry
It seems like your first paragraph answers the question in the second. If it is harder to use and learn then that reduces the value of free software released using it as that software is then harder to modify, fix, contribute to, etc. The tradeoff for Rust being hard should be more security and fewer bugs. The additional cost here, and the one that the OP is probably annoyed with, is that it moves away from the languages/platforms that MS has traditionally used and that developers who work on that platform expect.
koakuma-chan
Is Rust harder than C++?
90s_dev
> and you can even locally reason about the code much better than in typical 'unsafe' languages like C++.
Do you have an example of this? I'm just a TypeScript guy who never had a fair chance to use C++ or Rust for long, so I'd be curious how what you say is true.
free_bip
What's wrong with a terminal app being written in Rust?
sedatk
> Why Why Why?
Less memory overhead and no runtime dependencies?
It not only written in Rust, but they avoid basically any dependencies to third-party crates (beside the obligatory windows-sys/libc), optimizing probably for binary size. To achieve this, they seem to re-implement considerable parts of the rust ecosystem (own TUI library implementation, own unicode handling, own arena implementation, ...).