ESC ESC ESC

Emacs Command of the Day offers a tip that, oddly, a lot of people don’t seem to know about:

I usually use it after trying Ctrl+g and right before sending a SIGUSR2 signal.

I didn’t realize the part about closing the minibuffer but that’s probably why it often works for me.

Posted in General | Tagged | Leave a comment

Apple’s New Maps

Way back in 2012, I wrote about Apple venturing into maps and the problems they were having. As I said at the time, getting good map data is extraordinarily hard—Google at the time had over 7,000 people working on their data—and it was going to be some time before Apple could catch up with Google.

That time, it appears, has come. Tech Crunch has a fairly long article reporting that Apple is rebuilding Maps from the ground up. Like Google, they have built new tools and assembled a large team to gather the data needed for a world class mapping application. After 4 years work, Apple is expecting to release their new maps for the San Francisco and Bay Area with iOS 12. Other areas will roll out over the next year.

Being Apple, the company has built in privacy from the beginning. No person ever sees the unsanitized data containing license plate numbers and faces: The data is encrypted as it’s gathered and the key is held by software that scrubs the privacy violating objects from it.

The other Apple-like feature is the attention to detail. Maps in Japan show more detail at an intermediate zoom level than a corresponding map in the U.S. would because that’s what the two cultures expect. Apple even licensed the fonts used by, say, the NY subway system so the signs on the maps would look the same to users. There are other examples as well. Read the article for the details. Even if you aren’t an Apple user, the article is an interesting discussion of the technical problems Apple has had to solve in building their new maps.

Posted in General | Tagged , | Leave a comment

Don’t Be a Peripheral

Here’s a little red meat for the Vim vs. Emacs crowd:

Posted in General | Tagged | Leave a comment

A BBEdit Challenge

My friend Watts tweets that he thinks BBEdit has the simplest workflow for doing a search and replace on the files of a directory that do not include some term:

I took that as a challenge, of course, and immediately started figuring out how to do it in Emacs. I have a solution that uses two (or arguably 3) simple commands to do the same thing starting from a dired buffer. So the challenge is, how would you do this in Emacs using the minimum number of {commands | keystrokes}1? If you know BBEdit (I don’t) is your solution easier/simpler than the same thing in BBEdit?

Footnotes:

1

Not counting keystrokes for the search term or regular expressions in the search and replace.

Posted in General | Tagged | Leave a comment

Zamansky 50: Presentations

Mike Zamansky is getting ready to give a presentation at a professional conference. As always, this means preparing a slide deck and Zamansky is faced with deciding how to do it.

In the past, he’s described reveal.js as his go to presentation software but he decided to look at the other options. In particular, he looked at ox-beamer and epresent as well as ox-reveal. His latest video discusses each of these and what he chose to use for his presentation.

All these solutions share the virtue that you can write your slides with Org mode and export them to ready-to-show slide decks. He starts by explaining why he doesn’t just use something like PowerPoint, Google Slides, or one of their free software siblings. Those systems, he says, force him to focus on how the slides are laid out and that gets in the way of writing coherent content. He much prefers to write in Org mode taking advantage of its editing capabilities and leave it to the exporter to make the final results look pretty.

His first attempt was to use beamer. Although he likes the way the slides look, he found beamer difficult to use. He doesn’t give very many presentations so it would be hard to remember the details of using it even if he made the initial investment in learning the system.

Epresent’s slides don’t look as nice as those from the other two systems but they have the virtue of displaying from within Emacs. It’s also very easy to navigate through the slides.

Finally, Zamansky considers reveal.js and its Emacs interface, ox-reveal. It combines a nice looking final product with a dead simple input structure. Basically, any Org file can be exported as a slide deck by the inclusion of a single statement telling ox-reveal where reveal.js is located. In the video, Zamansky just uses the epresent source file for the reveal.js example. All he needed to do was point it towards reveal.js. He also showed how it’s possible to serve the slide deck directly from GitHub. That could be handy if it’s not possible to use your own laptop for some reason or another.

The video is a bit longer than usual (20:12) so you may need to schedule some time. As always, it’s definitely worth your while to watch it.

Posted in General | Tagged , | Leave a comment

Two Videos on Early Unix

I just came across some old videos from AT&T about Unix that are worth taking some time to watch. I thought I had written about them before but I couldn’t find any mention of them either locally or on Irreal itself. In 1982, Unix had been around for a bit over a decade, had matured quite a bit, and was being used throughout the Bell system as well as other places. That year, Bell Labs produced two short films, The UNIX System: Making Computers More Productive and The UNIX System: Making Computers Easier to Use. They cover the same material and even use some of the same sequences but it’s still worth watching both. AT&T says the first was aimed towards software developers and computer science students. The second was for programmers specifically.

I really enjoyed seeing some of the original Unix developers including an impossibly young Brian Kernighan but also Thompson, Ritchie, Steve Johnson, Lorinda Cherry, John Mashey, and Al Aho. They’re all delightfully nerdy as they describe Unix and how it makes developers’ lives easier.

At one point in both films, Kernighan builds a spell checker by piping together a series of existing programs to do things like splitting text into one word per line, sorting, eliminating duplicates, and checking against an existing dictionary. What was interesting is that although the same commands (more or less) exist today, they had different names. Kernighan used a program called makewords to split the text into words while today we’d probably use tr. What we now know as uniq as called unique and the functionality of comm was implemented in a program called mismatch. Nonetheless, you could build the same pipeline today with any Unix system using the modern versions of the programs Kernighan used.

If you enjoy seeing how things were early in Unix’s life and would like to see what the early researchers looked and sounded like, it’s definitely worth spending a bit of time watching these videos. The first is about 27 and a half minutes and the second is about 23 and a half minutes.

Posted in General | Tagged | Leave a comment

The Emacs Commune

Someone posted a chapter from Sam Williams’ book Free as in Freedom (online here), that discusses the early history of Emacs. The chapter, The Emacs Commune, is full of things I didn’t know about how Emacs evolved from the TECO editor.

We all know that Emacs started as a set of macros to the TECO editor (hence Editing MACroS) but there’s a lot more to the story. In the first place, the choice of the name Emacs involved more than just the obvious mnemonic. The choice was, in fact, chosen for efficiency reasons. You can read the chapter to see what that was.

You may also have heard that Guy Steele played an important role in the development of Emacs. That’s true, and, in a way, he started the whole thing, but the driving force was always Richard Stallman.

If you’re an Emacser, you owe it to yourself to take a look at this chapter if only so you’ll know where the editor that we love and depend on came from. Even early on, lots of people contributed, if only in the form of their own TECO macros. It turns out that the early standardization of those macros—in what was later to become Emacs—presented a political problem for Stallman. Read it and become enlightened.

Posted in General | Tagged | Leave a comment

HTTPS Is Easy

Troy Hunt, whom I’ve written about many times, has performed a public service by putting together 4 simple videos that show how easy it is to implement HTTPS on your site. The link takes you to a blog post that discusses all this but the actual videos are on a separate site, httpsiseasy.com.

You can get security that’s stronger than the typical bank site security with a little more than 5 minutes of work. It turns out you can do all of this and more for free. As Hunt explains, CloudFlare has a free service that allows you to easily do all this without changing your hosting provider.

Head over to the httpsiseasy.com site and watch the videos. The four of them together take a little less than 20 and a half minutes to watch. You’ll see how easy it is to secure your site. Even if, like Irreal, there’s nothing on the site worth securing, you’ll protect your users from malware and make it harder for the nosey parkers to peek at what you’re doing.

Posted in General | Tagged | Leave a comment

An Emacs Interface to the macOS System Dictionary

As I’ve said many times, I consider abo-abo’s define-word one of my most useful packages. I use it several times a day. If you’re looking for a dictionary that ties in seamlessly with Emacs, you should take a look at define-word.

Some people may be put off by the fact that define-word leverages the Wordnik dictionary site to get its definitions. As I noted in my post on powerthesaurus, I’ve used define-word since it was announced (over 3 years ago) and have never had a problem with its depending on a third-party site. I guess that if I lost or didn’t have connectivity for some reason, I could just use the macOS system dictionary but I’ve never had to do that.

For any macOS Emacs users who are worried about such things, Xu Chunyang has written a package to query the macOS system dictionary from Emacs. I am, as I said, perfectly happy with define-word so I haven’t installed osx-dictionary. I could, I suppose, install it as a backup system in case I don’t have connectivity but, at least at this point, it doesn’t seem necessary.

But don’t let my preferences sway you. If you’re looking for an easy way to access the macOS system dictionary from Emacs, you should definitely take a look at Xu’s package.

Posted in General | Tagged | Leave a comment

Literate Programming Using Org Babel

Gregory Stein has an excellent post on Literate Programming with Org-Mode. Despite the title, it’s really more about leveraging Org Babel to create literate documents that contain notes, code, and results. This is, of course, the same area that Howard Abrams covered so well with his Literate DevOps post and video and Stein mentions Abrams work but also adds some material that I wasn’t familiar with.

In his section on working with code blocks, Stein covers how to set parameters that are specific to a language. That’s not useful for individual code blocks, of course, but it’s handy for file-global settings in, say, the :PROPERTIES: drawer when the file contains code from more than one language. He also shows how to enable the asynchronous execution of the code blocks using the ob-async package.

Finally, Stein offers an extended example of setting up a Python virtual buffer, If you program in Python with Emacs, that alone makes his post worthwhile.

Stein’s examples are a little less complex than Abrams’ so his post is a nice introduction to the subject and should probably be read first if you haven’t already read Abrams’ post and watched his video. This is really useful material that’s sure to give you plenty of good ideas; I recommend reading both Stein’s and Abrams’ posts and, of course, watching the video.

Posted in General | Tagged , | Leave a comment