An Update on Emacs and macOS Catalina

Just a quick update on my experience with macOS Catalina and Emacs. Last week, I wrote that after not reading about any significant problems with Emacs on Catalina, I upgraded my laptop. I haven’t seen any problems with Emacs as a result of the update. Quite the opposite. Emacs now seems snappier in general and it’s definitely faster for operations that involve shelling out to the operating system.

For example, before when I followed a URL link from an Org file, there was a significant delay. That started happening when I upgraded to Mojave. With the upgrade to Catalina, that delay is gone and everything is back to being nearly instantaneous. That’s a very welcome change.

The feeling that Emacs is snappier in general is more subjective but I do think things have speeded up a bit. Perhaps that’s wishful thinking but I guess it doesn’t matter. Seeming to be snappier is just as good as being snappier since it’s a matter of perception.

The takeaway is that there doesn’t seem to be any reason not to update to Catalina as far as Emacs is concerned. The biggest problem people are having with Catalina appears to be that 32 bit applications no longer work just as Apple warned us they wouldn’t. If you are absolutely dependent on an old 32 bit app, you may want to hold off upgrading but 32 bit support is never coming back so you’re going to have to make some arrangements sooner or later.

Posted in General | Tagged , | Leave a comment

Clearing Out the Eshell Buffer

Marcin Borkowski has a really handy tip that explains something that I didn’t know. I’m a big fan of Eshell and usually reach for it first when I need a shell. One long standing problem I’ve had with it is clearing the screen. Doing a clear, as you would in other shells, doesn’t work. You can do a clear in Eshell but it doesn’t do what your expecting.

To deal with this, I long ago wrote a bit of code that lets me use the universal argument to clear the screen when I finish with an Eshell session. I like to run Eshell in full screen, which I invoke with Hyper+e, so the following lets me start and stop an Eshell session optionally clearing the history (by quitting Eshell) when I exit.

(global-set-key (kbd "H-e")
                (lambda (exit)
                  "Bring up a full-screen eshell or restore previous config.
With a prefix argument, exit eshell before restoring previous config."
                  (interactive "P")
                  (if (string= "eshell-mode" major-mode)
                      (progn
                        (when exit
                          (insert "exit")
                          (eshell-send-input))
                        (jump-to-register :eshell-fullscreen))
                    (progn
                      (window-configuration-to-register :eshell-fullscreen)
                      (eshell)
                      (delete-other-windows)))))

The result of that is that Eshell forgets its previous content when I exit it with the universal argument.

Borkowski’s tip is really simple. If you want to clear the Eshell buffer, you can do it by specifying clear with an argument. Thus, clear t will clear the Eshell buffer in the way you’re expecting. That’s very nice and good to know.

Posted in General | Tagged | Leave a comment

Getting Tough on the Corporate Snoopers

It almost certainly won’t be enacted in its current form but US Senator Ron Wyden has introduced a privacy bill with some real teeth. Among other things it calls for significant jail time for CEOs and other executives who lie to the FTC about their snooping.

As I’ve said before, fining the corporations doesn’t work because they merely write the fines off as a cost of doing business. Fining the executives directly probably wouldn’t work either because, one way or another, the fines would be paid by the corporations. Jail time is different. The corporation can’t serve an executive’s sentence; it’s an entirely personal cost payable only by the perpetrator.

Sadly, even privacy groups—who have widely praised Wyden’s bill—admit that its chances of passage are slim because of the powerful forces arrayed against it. Facebook and Google, of course, are adamantly opposed to such legislation but so are other powerful corporations that collect and sell our information.

Wyden’s bill would allow individual consumers to opt out of having their information collected. To companies like Facebook and Google, that’s an existential threat. Imagine if Facebook were prohibited from collecting its users’ information without their permission and that Zuckerberg could go to jail for ignoring the ban. How long would Facebook stay in business? Probably not very long, at least not with their current business model.

The good news about the bill is not that it will pass. It probably won’t, although I very much hope it will. Its real effect is more apt to be felt as a wakeup call to those abusing our privacy. If the bill is hard to defeat and costs the lobbyists a lot of money, perhaps the abusers will dial back their behavior a bit. Or not.

Posted in General | Tagged | Leave a comment

Asynchronous Communication

Amir Salihefendic of Doist notes that study after study have shown that remote workers are more productive and asks why that is. One thing that everyone cites is the time saved on commuting and to a lessor extent the lack of distractions that come from working in an office. The other benefits, however, do not come from location independence. Rather Salihefendic says, those benefits come from asynchronous communication.

By that he means communication that does not require an immediate response. A telephone call, for example, is an example of a synchronous communication. Someone asks you a question on the phone, you hear the question as it’s asked, and respond immediately. An example of a (possibly) asynchronous communication is email. Someone sends you an email asking a question and you might not read it or answer for several hours or even days.

The advantage of asynchronous communication is two-fold. First, it doesn’t interrupt your current work. You can deal with it after you’ve completed the task you’re working on. That provides an environment that allows you to get in the flow and concentrate on the job at hand.

The second advantage is that rather than giving an instantaneous answer, you have time to consider your answer and write a more coherent response. The result is that both the answerer and asker benefit even if the response is a bit delayed.

Salihefendic notes that you don’t have to be a remote worker to enjoy these benefits. Any company can choose to implement an asynchronous communication culture. His own company, Doist, has done that even though they have mostly remote employees. Sometimes, he says, you need synchronous communication. Employees need to see each other face-to-face to build relationships and not feel isolated. Doist has regular company-wide meetings and arrange for one-on-one meeting between employees and their supervisors on a regular basis.

Sometimes, of course, an emergency comes up and a phone call or other direction communication is necessary but Doist considers these an exception to be used sparingly. It’s an excellent post with a novel take on remote work and what makes it work. Definitely worth reading.

Posted in General | Tagged , | Leave a comment

Navigating With Spacemacs

Over at the GDQuest YouTube Channel, Nathan Lovato has a very nice video on navigating with Spacemacs. Most of the video discusses the Spacemacs interface to the Avy package for jumping around in your code. I’m not a Spacemacs user but I do heavily use Avy for navigation. It is by far the best system I’ve come across for this sort of thing. Once you get used to it, you’ll hardly ever navigate by moving the cursor up and down a line at a time or backwards and forwards a character at a time. It’s just so much simpler and faster to get there with Avy.

My favorite commands are avy-goto-word-1 and avy-goto-char-timer. The first marks every word that begins with the character you specify and lets you choose which one to jump to. The second lets you enter as many characters as you like. When you stop, you can jump to any of the marked sequences. Both are very useful and I call them all the time. The video covers other commands, such as jumping directly to a line, as well. There’s also a short section on using imenu. Lovato shows you how to do all this in Spacemacs so if you’re a member of that Emacs sect you should definitely take a look. The video is 12 minutes long so it should be easy to fit into your schedule.

Posted in General | Tagged | Leave a comment

Zamansky 59: Markdown

Most people recognize that Emacs Org mode is superior to Markdown as a markup language. (Sorry Markdown partisans but it is1.) The problem with Org mode is that as a practical matter it’s restricted to Emacs users. Mostly that doesn’t matter since you’re usually interested in the final exported version of the document. Sometimes, though, you’re collaborating with someone who’s not an Emacs user and you need a markup language that you can both use. There are many possibilities, of course, but most people settle on Markdown as a sort of lingua franca. That makes sense because the exporters are not associated with any particular editor—John Gruber’s original implementation was a Perl script—so everyone can work on the same source document.

Mike Zamansky is a perfect example of this. He prefers to write in Org mode but sometimes, when collaborating, he’s forced to use Markdown. Emacs, of course, has excellent support for Markdown so Zamansky—and the rest of us—don’t have to leave the comfort of our preferred editor.

In the latest video of his Using Emacs Series, Zamansky considers some of the Emacs tools for Markdown. There is, of course, markdown-mode major mode to help you write the actual Markdown source but Zamansky also wanted an easy way to preview his document. It turns out that there are a lot of packages for that and the video discusses many of them. Zamansky finally settled on grip-mode. It’s a very nice previewer that provides live updates so you see your changes as you make them. That met Zamansky’s goal of making the process as frictionless as possible.

The video is 11 minutes, 47 seconds long so it should be easy to find time for it. If, like most Emacs users, you sometimes find yourself needing to write in Markdown for collaboration or other reasons, you should definitely watch this video. Like all of Zamansky’s videos, you’ll learn a lot.

Footnotes:

1

This is probably less true than it once was but it’s still true.

Posted in General | Tagged | Leave a comment

A Talk With Brian Kernighan

Back in March, John Mashey interviewed Brian Kernighan at Princeton about his career and technical work. It’s a wonderful video that covers his career from his undergraduage years to his current position as a professor at Princeton. We’ve heard some of the stories before but there was a lot in the video that I didn’t know.

If you’re a Unix-head you’ll enjoy the discussion of the extraordinary culture that the Bell Labs researchers enjoyed and how it changed for the worse after divestiture. If you’re into the Go language you’ll appreciate his take on the Go language and the things it got right that most languages haven’t.

If you’re an educator, you’ll be interested in what he has to say about teaching Computer Science classes today and some of the problems he has to deal with. Kernighan developed—and still teaches—what amounts to a “Computer Science for Poets” course. That grew out of his experience teaching a semester at Harvard during a sabbatical while he was still at Bell Labs. The class had students ranging from the wunderkind freshman who had—as Kernighan says—been programming from the time they were in utero to terrified Senior English majors trying to fulfill a science prerequisite. Kernighan felt that those English majors weren’t being well served and set out to change that when he got to Princeton.

The video is long, just short of an hour and 15 minutes but it’s very much worthwhile taking some time to watch. Kernighan is always interesting and is an inspiration. It also serves as a sort of snapshot of the history of our field because his career spans most of that history. Indeed, he helped make some of it himself.

Posted in General | Tagged , | Leave a comment

Emacs and MacOS Catalina

Last night I upgraded my MacBook Pro to macOS Catalina (macOS 10.15). I’d been holding off to see if there were reports of problems with Emacs on the new OS. That happened last time with the upgrade to Mojave because Apple stopped supporting the old display model and you couldn’t use Emacs in GUI mode until the Emacs devs generated a fix.

This time, there were reports of Emacs not being able to access (any of) the file system. The solution seemed pretty simple. The TL;DR is that Emacs was being loaded by a Ruby script so it was Ruby that needed to be given permissions. I hadn’t heard of the Ruby script before but assumed it was something new in Emacs 27. When I checked the above Stack Exchange entry, though, it said the poster was seeing the problem in Emacs 26.1.

In any event, after the upgrade Emacs worked just fine without me doing anything. I’m using the same binary (Emacs 26.3 compiled from source) as before so I haven’t tried recompiling Emacs yet but the old binary is working as it was previously without having to adjust permissions or anything else. My conclusion is that there’s no reason not to upgrade as far as Emacs is concerned. If you do experience problems with accessing the file system, take a look at the above link. Every report I saw about the problem said that the solution provided by Stack Exchange got things working again.

Added in editing:
Here’s a tweet that also describes the problem. The Stack Exchange link it contains is different from the one above so you should look at it too if you’re having problems.

Posted in General | Tagged , | Leave a comment

The Many Functions of a Smartphone

Remember back in the original Star Trek series how Spock carried around a tricorder? I always wanted one of those. Now, of course, I have something even better: my iPhone. Smartphones are general purpose devices that perform many functions, certainly more than the original tricorder. Today’s smartphones are actually more like the “terminals” from Iain M Banks’ Culture series.

I was reminded of all this by the recent XKCD Cell Phone Functions cartoon. The cartoon is a timeline of present and future functions subsumed by our phones. The most recent function to be assimilated is “car key.” Those functions not yet performed by the smartphones are all jokes: things like dog leash and band-aid.

That got me wondering what else we could have our phones do. They already provide an interface to the world’s knowledge—including things like the current state of the stock market and the weather—so any additions to that category aren’t really new. Smartphones are, of course, really computers first and communication devices second so again any additions to general computing or communication capabilities don’t count (although I can’t think of any communication function they don’t already perform).

The only obvious thing I can think of is suggested by the band-aid joke: health monitoring. Smartphones are already doing some of that and I’m sure we’ll see more such functionality in the near term. We could, I suppose, add some trivial sensors like a thermometer but I can’t think of any major functionality they don’t already have. What about you? Can you think of some plausible function smartphones could perform that they aren’t already doing?

Posted in General | Tagged | Leave a comment

More on Cashless

Surprisingly, to me, my post on the trend to becoming a virtually cashless society generated a lot of interest and comments. Given my nearly unblemished record on being unable to predict how popular a given Irreal post will be, I probably shouldn’t have been surprised. In any event, the interest prompted me to look into the trend a little more.

Back in May, CBS did a report on the backlash to going cashless. It’s not just the politicians. Many customers also object to having an establishment refuse to accept cash even if they do have a credit card. Some of that’s a concern for privacy and some of it’s probably just the typical American crankiness about being told they can’t do something they’ve always done. The biggest complaint, of course, is that the practice discriminates against the poor.

One thing the CBS report makes clear is how big a win it is for the merchants. Even the merchants who have voluntarily returned to taking cash emphasize how much cheaper, safer, and efficient it is to run a cash free business.

As I said in the previous post, it doesn’t matter much to the credit-card-using consumer. Theoretically, someone in front of you paying in cash can slow things down when you’re trying to pay but I, at least, haven’t found that to be an issue in practice. Despite the impression I apparently gave in the original post, I’m not yearning for a cashless society, I just want to be able to pay for things using my iPhone. I’m perfectly happy if others want to use cash.

Keeping cash may even be a benefit. Some of the commenters to the original post point out some of the dangers that come with a cashless society. In the long run, I expect that cash will go away but I don’t think it will happen in the near term. There are still too many problems to solve.

Posted in General | Tagged | Leave a comment