Wanted: Console Text Editor for Windows

(This is a guest post by Antoni Sawicki aka Tenox)

Since 2012 or so Microsoft is pushing concept of running Windows Server headless without GUI and administering everything through PowerShell. I remember sitting through countless TechEd / Ignite sessions year after year and all I could see were blue PowerShell command prompts everywhere. No more wizards and forms, MMC and GUI based administration is suddenly thing of a past. Just take a look at Server Core, WinPE, Nano, PS Remoting, Windows SSH server and Recovery Console. Even System Center is a front end for PowerShell. Nowadays everything seems to be text mode.

This overall is good news and great improvement since previous generations of Windows, but what if you need to create or edit a PowerShell, CMD script or some config file?

Oooops, looks like you are screwed. Seems that Redmond forgot to include most crucial tool in sysadmins job – a simple text mode editor. WTF Microsoft?

So, are there any 3rd party alternatives? Yes, and there are and quite a few of them! Unfortunately none are perfect. This article aims to be a grand tour of whatever is available out there.

Note that throughout the article I will be repeatedly referring to a “portable” editor, that for me means single .exe file that can be carried around on a USB pen drive or network share. I also cry a lot about 64bit Windows build because I work a lot in WinPE and other environments where syswow64 is not available. 

First lets start with most obvious choices well known through intertubes. If you search for a Windows Console Editor VIM and Emacs will naturally pop up first. These editors don’t need any introduction or praising. I use VIM every day and Emacs every now and then. These two had ports to Windows for as long as I can remember and in terms of quality and stability definitely up top. The problem is that both are completely foreign and just plain unusable to a typical Windows user and learning curve is pretty steep. Also portability suffers a lot at least for Emacs. Both editors come with hundreds of supporting files and are massive in size. Emacs.exe binary is whooping 83 MB in size and the zip file contains two of them just in case. Whole unpacked folder is 400 MB. Thats biggern than W

Emacs on Windows Console

VIM is fortunately much much better you can extract single vim.exe binary from the package and use it without much complaints.

VIM on Windows Console

When talking about about VI and Emacs hard not to mention some more historical versions. Emacs’ little brother MicroEmacs has been available for Windows since earliest days. I’m not going to attempt to link to any particular one since there are so many flavors.

MicroEmacs

VIM little brother VI also comes in different shapes and forms. Lets take look at a few.

Elvis

Elvis on Windows

XVI

XVI on Windows

Stevie is a very special case. Rumor has it, this editor played crucial role in development of Windows NT itself or has been used since earliest days of NT as part of the private SDK. If you could ever look at Windows source code I’d bet you could probably find it buried inside. Because it was ported by folks at Redmond the quality should be pretty good. Unfortunately README states “this is an incomplete VI that has not been fully tested. Use at your own risk.”. For a historical note according to Wikipedia, Stevie port to Amiga has been used by Bram Moolenaar as a base source code for VIM.

Stevie for Windows aka NT VI

One particularly interesting case is VI editor from Watcom compiler suite. It has very nice TUI known from MS-DOS editors, syntax highlighting and online help. One of nicest versions of VI available for Windows. Small portable and just all around handy editor. This is probably my main to go text editor when working on WinPE or Server Core. Unfortunately not very well known. I hope it can gain some popularity it deserves.

OpenWatcom VI Editor

I don’t want this article to be all about VI and Emacs clones. Let this nice color menus be a segue to more native Windows / DOS editors at least departing from hardcore keystrokes and Unix.

For a change in theme lets look at SemWare TSE Pro, the editor that originally started a QEDIT for DOS and OS/2. It has most advanced features one could ever imagine for a text mode editor. Including resizable windows, hex editor, macros and spell checker. I really wish I could use it in everyday’s life. Unfortunately TSE has some drawbacks, it lacks portable version and install is little cumbersome. It also doesn’t have 64bit version which is a problem for WinPE. The biggest problem however is a license which runs $100 per user. I can’t imagine installing it on hundreds of Windows servers.

SemWare TSE Pro

Next one up is Brief. It used to be very popular in it’s own time and sparked quite bit of following as there are numerous of editors being “brief style”. It’s a nice and small console based text editor. It comes in two versions basic (free) and professional (paid). The pro version supports splitting in to multiple windows regexp and unicode. Unfortunately it runs at $120 per user and there is no 64bit build or a portable edition.

Brief

There also is an open source clone of Brief called GRIEF. Flipping through the manual it has very impressive set of features including $120 windowing feature and macros. Unfortunately it’s rather unportable due to large amount of dll and other files. 64bit build could probably be made if someone wanted.

GRIEF free Brief Clone

As we talk about less costly options there is Kinesics Text Editor aka KIT. It’s more well known if you search on google, completely free and after installing you can find and a x64 binary file! This makes it somewhat portable and able to run in WinPE for instance. Until recently the editor did not have 64bit version so I did not have chance to use it much in practice but the TUI appears to have a well rounded easy to use (F1 or right mouse click brings menus). It does’t seem to have any advanced features but it’s very stable and actively maintained. And frankly this is what matters for editing on the console. It may actually be the right missing Windows console editor.

Kinesics aka KIT

Another one is Minimum Profit. It’s fully open source and it supports a lot of platforms in both windowing and text mode. It has a lot of interesting features such as syntax highlighting, spell checked and menus. It can’t be easily made portable as it needs a lot of files of it’s own scripting language. There is no Win64 build by default but one could probably make it with Mingw64. I also find that screen refresh is somewhat funky.

Minimum Profit

Lets look at somewhat well know FTE. It’s a very nice text editor available on many platforms such QNX, OS/2 and of course Windows. It has nice TUI, split windows, syntax highlighting, folding, bookmarks and tools for HTML authoring etc. Overall awesome editor falling short only to TSE. Support for NT console has been available since 1997. I have recently fixed couple of bugs and built a 64bit portable version.

FTE Editor

One could also not forget Borland Turbo C IDE. Apparently there is an open source clone of the IDE as a regular editor called SETEdit. It’s multi platform editor with MS-DOS style windows and menus. Syntax highlighting macros and all regular amenities. Looks like DOS version can play MP3 songs while you code. There is a native WinNT build made with BCPP. To run on Windows you install the DOS version then overwrite dos exe file win NT exe. The editor is absolutely awesome, unfortunately currently doesn’t work in a portable manner and there is no x64 binary. However as it’s open source it could be probably made.

SETEdit a Borland Turbo C IDE Clone

When talking about MS-DOS style windows, Norton Commander like file managers come to mind. There is one particular built specifically for Windows – FAR Manager. Written by author of WinRAR, originally shareware, but since 2007 it has been released under BSD license. FAR does come with a built in text editor hence it’s featured here. It’s actively supported and developed, and because it’s designed from ground up for Windows, it’s probably most stable and trustworthy of all applications in this post. I normally don’t use it that much, but I do keep a copy of it lying around when I need to do some more heavy lifting from Windows console. There is a 64bit binary by default but unfortunately FAR can be hardly made portable as it comes with 400 files.

FAR Manager Text Editor

When talking about Norton Commander clones lets not forget Midnight Commander, which does have an unofficial native Windows console build called mcwin32. Similar to FAR, MC has a very nice built-in text editor. MC overall seems far nicer than FAR but because it’s multi platform rather than WIndows specific and not officially supported I don’t trust it as much for day to day use.

GNU Midnight Commander

When on topic of Unix, lets talk about GNU Nano. In it’s native habitat, it’s very popular and stable editor making it a perfect choice for a text mode console. Unfortunately Windows port is lacking quite a lot, especially for things like resizing Window or handling file names. The official build looks like a fusion of cygwin, mingw, pdcurses and other horrible stuff. Version that comes with Mingw/MSYS is not portable and so far I failed in attempts to build a static windows binary by hand. Nano predecessor UW Pico unfortunately never did have console terminal Windows port. Authors of Pine decided to make it semi graphical application with it’s own window, menus and buttons. Sad story for both Pico and Nano. Hopefully one day someone will make a 100% native Windows port.

Another non-vi and non-emacs Unix editor with Windows console port is JED. Frankly I have not used JED that much in the past although I did play with it in the 90s. This is the original web page of Jed editor. It does seem to have menus and multi windows. Unfortunately doesn’t look like it can be easily made in to a portable image.

JED Win32 Port

Yet another more obscure editor is ED-NT which is DEC EDT clone. Unfortunately seems to be completely dead an unmaintained. Sources are still available through archive.org so perhaps it could be still looked after if someone wanted EDT editor on Windows.

ED-NT

When going through obscurities via archive.org one can also mention ZABED and more specifically Z95 which is a 32bit console version. I don’t know anything about the editor and I’m little too lazy to play with it extensively although pdf manual is available. Probably little too old and too obscure for every day use.

Z95

Thanks to Andreas Kohl I have learned about X2 Programmers Editor which also has NT console version. The editor seems very nice and has extensive help, syntax highlighting, etc. Unfortunately I have never used this editor before. Last version has been released in 2008 which is not loo long ago but sadly there has been no update since. I hope the author will continue to maintain it.

X2 Programmers Editor

Andreas also brought up Personal Editor, which comes as PE32 and PE64. Looks like really well maintained and stable editor designed and developed specifically for Windows. 64bit bit version is really cool however the editor doesn’t seem to be portable and $40 license will probably prevent me from using it professionally in environments where I would need it. Never the less looks like a very fine editor!

Another find is e3 editor. Pretty interesting stuff. It’s written in assembler and available on many operating systems including DOS and Windows. Looks like it’s still maintained as last version was released in 2016. It supports multiple modes, Wordstar, Emacs, Vi, Pico and Nedit by renaming or linking the main executable. It’s definitely portable as it doesn’t need any extra files and the exe is just 20KB (take that emacs!). Unfortunately because of assembler I don’t think there will be a 64bit release any time soon. Overall seem to be really cool to keep this one around.

e3 editor

A really cool last minute find is public domain TDE – Thomson-Davis Editor. Released not so long ago in 2007 it has 16, 32bit DOS and 32bit Windows console executable. It has DOS style menus,syntax highlighting, resizable windows and bunch of other features. Looks like a very handy editor. I don’t know how did I miss it. Since source code was available so I was able to make a x64 build. This is really untested so use at your own risk!

TDE

Also a recent find – shareware editor called Aurora. I never had a chance to use it in the past but after taking it for a quick spin I fell in love. The text mode UI it feels like it’s own windowing operating system! Originally for DOS, Unix and OS/2, Win32 port is relatively new. Unfortunately it’s no longer maintained or even sold. This is very sad because the editor is extremely cool. I hope the author may be willing to release the source code so it could be maintained.

Aurora

Last but not least, a new kid on the block, is Micro. It’s a modern times editor for all platforms including Windows. It looks really cool and seem to have all recent amenities from editors such as Sublime Text or Atom. Multi windows, syntax highlighting and even it’s own built in terminal emulator for running a subshell. Micro is 100% portable and comes in as a single x64 exe file. It’s 10 MB size but I think well worth keeping around. Unfortunately it doesn’t have built-in file browser. Yes, there is a plugin for it but I don’t know how to use it. Also seems to have issues with Windows style path names. However I’m really happy that a new editor has been developed in recent times. It has a great chance of becoming the missing Windows text mode editor for the future! Definitely worth keeping an eye on it.

Micro Editor

With this positive news it’s time to wrap up. To summarize there currently is no perfect text mode editor for Windows. I hope that Microsoft can one day step up and provide one, especially for PowerShell environment. In the mean time I usually stick around to OpenWatcom VI and FAR Manager. For people who do not wish to learn VI, Kinesics KIT may probably be the most perfect editor in short term and Micro in the future. I also hope someone can make a good GNU Nano port using native Win32 APIs without going to pdcurses and cygwin.

Have I forgotten or missed any editor? Please let me know and I will promptly add it to the list! Note: please do not include editors that work under Cygwin.

 

Welcome to the uncanny valley

It’s that awkward time of the year when those of us that still have to work feel as if we really should be on vacation…  But here we are flipping your burgers and keeping the lights on.

Oh and I thought it’d be fun to do one last giveaway for the year.  And a good one too, DooM 3 BFG!

As always, I have 5 keys.  So to the first 5 people!

Calamus for Windows NT RISC

(This is a guest blog post by Antoni Sawicki aka Tenox)

A Christmas gift for those who run Windows NT on Alpha AXP, MIPS or PowerPC. These ports of Windows are really lacking some good applications. Yes, there are utilities and games, Alpha even has Microsoft Word, Excel and Oracle DB, but apart from that there are just no serious apps available.

Calamus is a professional DTP (Desktop Publishing) software. It’s still actively developed and sold by German company Invers. If you want to play around with the latest version you can download a 30 day trial and even purchase the Lite version for 99 Euro on calamus.net. There are versions for Windows, Mac and Atari ST.

Atari ST ?! Well yes, the original Calamus was born some 30 years ago on Atari ST:

I had pleasure of using Calamus professionally on Atari for several years in early 90s. At the time when 486 could have max 64MB RAM and 640×480 VGA, a high end Atari TT packed 256MB Magnum card and 1280×1024 framebuffer and it was much cheaper than Mac. The memory and high resolution displays were really needed to process large images and complex page layouts.  You can read more about my Atari TT restoration efforts.

In the mid ’90s DMC decided to port Calamus to Windows in order to expand to other hardware platforms. An interesting fact is that the port isn’t really a full source code rewrite, which would be impossible due codebase size. Even that Calamus has 100% native Windows GUI and a lot of functionality has been rewritten, inside the software lives a small embedded Atari ST emulator that does on fly translation of some of the Atari/m68k ABI. You can read a bit about it here.

Calamus on Windows NT Alpha AXP

At the time of the port, Windows NT was still being actively developed on RISC platforms, so thankfully Calamus has been compiled on all of the available NT CPUs. Alpha version was probably the most popular choice because of performance. High end Alphas were the fastest machines capable of running Windows among all hardware. When publishing firms were thinking about upgrades they naturally looked at DEC as a first choice as regular PCs weren’t powerful enough.

And this is how I finally found a copy Calamus NT with support for RISC CPUs. It took me quite a lot of time and resources to track down and obtain copy of surviving media from owner of a publishing studio. This is how it looks when you first install it:

Calamus NT Install Wizard

Note that there were separate builds for 386/485 and Pentium CPUs. Also as you can see the disk contains a demo version which now Santa is delivering to you. This is a fully functional trial that expires after some time. If you ever lacked serious apps for your RISC NT machine, you can how play with one! The demo version is distributed with permission of Invers Software.

If you don’t have one of these machines you can still run Windows NT MIPS on Qemu:

Calamus on Windows NT MIPS

And finally to the goods. You can download following files:

Calamus NT v1.5 DEMO for DEC Alpha AXP

Calamus NT v1.5 DEMO for MIPS

Calamus NT v1.5 DEMO for PowerPC

386 and Pentium builds are not available. Please do not ask. For Intel build download the latest version from Invers Software.

Thinking about doing something different about monitization

I hate ads, and didn’t want to go down that road, but I was thinking of something different.  I keep reading in the news about these ‘javascript bitcoin miners’.  Many of them apparently are stealthy, but how about one that is overt?  I saw over at coinhive.com that they do have ‘opt in’ versions of their scripts as opposed to doing it silently.  So I thought this would be something interesting to ask for:

Loading Authed Mine…
100% volentary!

So, buddy, spare some CPU cycles?

And we’re back.

So this last 24 hours has been chaotic.  I’d had this word press installation for a number of years, going back to the 2 week Blogspot outage a long time ago.  But things change and I’ve found dealing with systemd and it’s bizarre need to hide and obscure things, along with it’s worthless logging a losing fight.  So over Thanksgiving I saw this “web reseller” package that has 250gb space and 1TB of network for $15 a year.  And being a reseller means I can add additional domains and whatnot for free.

As you may have seen rss was broken the menu bars stopped working and all kinds of other smaller issues.  I figured it was as good time as any to do a fresh install of word press and only copy the article, comments and user tables.

In the middle of this, the superglobalmegacorp redirection broke as it’s no longer a combined site.  And then disaster struck when I tried to move the install to PHP 7.1, getting away from 5.6 as I was constantly running out of memory.

Something happened on the hosting side and their server lost all configs for virtuallyfun.  I’d opened a ticket, and after 4 hours of nothing I moved the site back to the old machine, but I got interrupted with life and it was all messed up.  As soon as I got up, the issue has been resolved and we are back.

For me, this site feels substantiality faster than the older one.  The old server literally costs me $25 a month.  But it’s old and tired.  I have a sales call out on a new data center in Tai Po, Hong Kong so I may be moving all my USA hosting here. Which would be nice for me, at least the server will literally be down the street.

Oh well you know the internet, things move.

I’ve been debating about doing a SQL dump and purging the user table, and placing a copy of this blog on archive.org ..  I know at the same time people will load it up and place shitty ads all over it..  but at the same time I’d like to keep a better copy of my insane ramblings.  I see some people already tried, but their backup strategy is clearly automated and all they did was capture a single article.

As always, keep backups!

**added

For those with legacy systems, currently the HTTP site works.

OS X 10.6 Safari

Naturally for older systems the SSL support is still SHA-1 centered, and the entire SSL infrastructure is quickly moving to SHA-2.  Plenty of the site’s resources will be linked as https, and that’s pretty much the way it is.

I’ve tried to get some devs to write a simplified front end to the wordpress database to at least make things visible to legacy systems, but for some reason people just run away at the prospect.  Personally I’d love to have one in classical ASP so I can host it on Windows NT Server 4.0 … But I haven’t had any takers.

For my own benefit here is what I amputated to get rss working.


feed-rss2.php
====================================================================
<?php /* (get_option('rss_use_excerpt')) : ?>
    <description><![CDATA[<?php the_excerpt_rss(); ?>]]></description>
<?php else : ?>
    <description><![CDATA[<?php the_excerpt_rss(); ?>]]></description>
  <?php $content = get_the_content_feed('rss2'); ?>
  <?php if ( strlen( $content ) > 0 ) : ?>
    <content:encoded><![CDATA[<?php echo $content; ?>]]></content:encoded>
  <?php else : ?>
    <content:encoded><![CDATA[<?php the_excerpt_rss(); ?>]]></content:encoded>
  <?php endif; ?>
<?php endif; */?>
====================================================================