Another Emacs/GCal Solution

Last month, I had three (1, 2, 3) posts on how people are integrating their Google Calendars with Emacs. The common idea was to be able to see some or all of the calendar items in Emacs. Mike Zmansky’s solution goes further and allows you to move data in both directions so that you can add data to your Google Calendar from Emacs.

James Williams has his own take on the problem. Like Zamansky, he uses org-gcal to move entries between Emacs and GCal. He also uses emacs-calfw to get a nice calendar-like display.

Even if you’re not a GCal user, you may be interested in emacs-calfw. It can be configured for use with Org, Emacs diary, iCalendar (GCal, iCal, etc.), and howm.

These four solutions for integrating GCal show again how easily you can adapt Emacs to your workflow. And, of course, how you can spend most of your time in Emacs.

Posted in General | Tagged | Leave a comment

Migrating Notes from Evernote to Org

I use Evernote to keep copies of resources that I think may disappear over time and I’m pretty happy with it. Recently, they’ve introduced a new fee structure and there’s been some grumbling about finding another platform. As I say, I’m happy with them for now but if you’re looking for a way to migrate off Evernote and you’re an Org mode user, Karl Voit tells us one way to do it

Everorg was written by Mario Martelli to migrate his Evernote data to Org mode because of the new pricing policy. It appears to be pretty complete—see the README—but if you have special needs you may have to do part of the migration by hand.

Again, I’m happy with Evernote for the time being so I haven’t used EverOrg but if you’re looking for a migration solution EverOrg is the best I’ve seen.

Posted in General | Tagged , | 1 Comment

Starting with Scheme

Mike Zamansky has an interesting post on using Scheme as a first language for CS instruction. That’s not a new idea, of course. MIT’s famed 6.001 course (Entry Level Computing) used Scheme and SICP for years. Their course was adopted by over a hundred other universities and still has a die-hard following.

What makes Zamansky’s post a bit different is that he is talking about using it for a first High School course in computing. Many folks are surprised by this because they think of Scheme as being esoteric and hard—it’s Lisp, after all—but the reverse is actually true. Scheme’s trivial syntax makes the language mostly easy to learn and understand. I remember either Abelson or Sussman (I don’t recall which) remarking that in 6.001 they didn’t even bother to formally cover Scheme. The students just picked it up as they went along.

You can see that approach in action in Abelson’s and Sussman’s astounding video lectures based on SICP (here’s YouTube if you prefer). They talk about Scheme and it’s features as they come up in the lectures and don’t bother devoting a separate block to it. (If you haven’t watched these lectures, stop whatever you’re doing and start. I watched them after years of experience and was amazed at how much I learned.)

You can read why Zamansky thinks Scheme is often a good idea for a first course. I mostly agree with him. The only thing I found surprising was that he got some push back from parents for using such a non-mainstream language. It’s encouraging, I guess, that the parents are knowledgeable enough to comment on the choice.

Posted in Programming | Tagged , | Leave a comment

ESR Evaluates Go

Last month I wrote about Eric Raymond’s (ESR) work on NTPsec and his comparison of Go and Rust with a view of replacing C with one of them as an implementation language. As part of his work on that comparison, he undertook a nontrivial project in Go.

That project was to rewrite (and improve) David Wheeler’s SLOCcount program. Counting program lines may not sound like much of a challenge but it turns out to involve more than just wc. ESR recounts his work and findings in his blog post Grappling with Go. Even if you don’t know Go, it’s interesting and worth a read. I especially liked the way he leveraged the Communicating Sequential Processes model (CSP) to handle synchronization between threads. I remember reading about CSP years ago and I even downloaded some AT&T code to play with it but I’ve never seen it used in a real application.

The project page for ESR’s SLOCcount replacement is here if you want to try it out or you can see the code at the project’s Gitlab page. Even if you’re not conversant with Go, it’s sufficiently C-like that you should be able to understand most of the program if you’re familiar with a C-like language.

Posted in Programming | Tagged | Leave a comment

Digital Workflow: Pocket Carry Edition

The other day, I wrote about my digital workflow and scanning and then I saw an article about putting ATM cards on our smartphones. This isn’t just pie in the sky. JPMorgan Chase already has a pilot program in four cities and Bank of America and Wells Fargo plan to introduce it to all their ATMs by the end of the year.

After reading the article, I realized that, at least for me, the point of having a digital workflow is to simplify my life. Having my ATM card on my iPhone is a great example of this. It’s one less card I have to carry around and usually not have when I need it.

Why wouldn’t I have it? Because I’m trying to simplify my life and that means, among other things, carrying around as little as possible. Here, for example, is my wallet. I usually carry a bit of cash, my drivers license, a credit card, and my insurance card. Instead of a fat, overstuffed wallet bulging in my back pocket, I carry a small lightweight wallet in my front pocket. It’s more secure and doesn’t cause back problems.

What else can we do to reduce our everyday pocket carry? One thing is to get rid of all those keys. I carry a house key and a mailbox key. Really, what else do you use regularly? I’m looking into a keyless entry solution for the house, which would mean I could stop carrying keys except for when I drive. In the U.S., at least, some states are replacing drivers licenses with a smart phone app. If that happens here in Florida and Apple Pay becomes a bit more ubiquitous, I could stop carrying a wallet at all.

Again, none of this is pie in the sky. These things are already happening and will probably be common in a very few years. The end state for me is that I would carry only my smart phone and it would replace all that other junk I’m carrying around now.

Posted in General | Tagged | 1 Comment

A Security PSA

Who would do this? Even worse is when they ask you to put sudo in front of it.

You can make the case, I guess, that it’s really no worse than downloading and running an installer but this method is just asking for trouble. At least with an installer you can usually check a signature.

Posted in General | Tagged | 1 Comment

Paperless

As I’ve written before, I maintain an almost exclusively digital workflow. About 8 years ago I banished pads, pens, and pencils from my desk and started taking notes and doing other record keeping chores on my computers and iOS devices. I write very few checks and other than signing charge slips—when Apple Pay isn’t available—I hardly ever write anything.

Somewhere along the line, I replaced my slow and tedious flatbed scanner with a snappy Fujitsu ScanSnap S1500M scanner and even allowed a pen back on my desk for those rare checks. Almost all our bills are paid online through our bank. Whatever paper we do get is scanned and shredded.

In my post linked above, I point to a post by Steve Losh in which he describes how he deals with his scanned documents. His idea is to run OCR on the documents, throw them all into a single directory and use his system’s search capabilities to find the ones he wants. This is simple and has the advantage that everything but the actual scanning can be automated. My ScanSnap takes care of the OCR for me but I still have to deal with filing the scanned documents. Because a lot of my scanned documents are tax related, I like to keep them filed by tax year. Other than a few other specialized documents the scans are mostly filed in a scanned-documents directory.

The fact that there’s more than one destination for them means that it’s hard to automate the task as Losh did. It turns out there’s a nice Emacs solution for this. Anthony Green has the Paperless app (also available on Melpa) that almost automates the filing process. You dump the scanned documents in a staging directory and paperless gives you a list of documents and target destinations. You can display the document if you need to before choosing a destination.

My only complaint is that all the target destinations have to live in a single hierarchy in which all the files are possible targets. That’s not an insurmountable problem, of course, even for someone like me who has an existing setup. If you’re interested in this sort of thing, take a look at the README on Github to get the details. This is, I think, a really nice solution and moves one more chore into Emacs. What’s not to like?

UPDATE [2017-02-15 Wed 19:49]: Karl Voit, who I think can be fairly characterized as a researcher in digital workflow, has a comment below that contains some links to his solutions to the problems discussed in this post. I’ve read most of these before and can testify that they’re well worth your time.

UPDATE [2017-02-22 Wed 15:01]: you’re → your.

Posted in General | Tagged | 11 Comments

Another Recommendation for Which-key

A few days ago I wrote about Mike Zamansky’s video on rectangles. Most of my commentary involved ways of dealing with the difficulty of remembering the rectangle commands and their key chords. One of the solutions I discussed was which-key, a good solution requiring only that you remember that the prefix for rectangle shortcuts is Ctrl+x r.

Since there’s a new version of which-key out

this seems like a good time to repeat how much I like it. I’m still using the default configuration and it’s working really well for me. If I pause while typing a shortcut, which-key automatically pops up a buffer showing all the completions. Once I type some more, the popup disappears so it’s pretty unobtrusive.

All this makes which-key ideal for commands like those involving rectangles that you probably don’t use that often. You can, of course, type Ctrl+h after the prefix to see the completions but I like that which-key automatically provides them if I stop to think in the middle of a key sequence. I also like that the which-key popup disappears automatically unlike the buffer you get with Ctrl+h.

If you don’t have which-key installed, give it a try. It pretty much stays out of your way until you need it. Definitely recommended.

Posted in General | Tagged | 4 Comments

Resetting a defvar Value

Apropos of yesterday’s post, I came across this query on Reddit and learned a new keystroke. One of the counterintuitive peculiarities of Elisp—and Lisps in general—is that a value defined by defvar or defcustom is immutable: once set it can’t be changed without restarting the process.

It turns out, though, that that’s not quite right. If you evaluate an expression such as

(defvar user "Jim")

with Ctrl+Meta+x instead of, say, Ctrl+x Ctrl+e you can change the value. I usually want to do this when I’m in the development phase an need to tweek a parameter. If you’re not an Elisp developer you won’t need to know this and even if you are, you probably won’t use it very often but it’s a really handy thing to know. And further proof that our Emacs education is never complete.

Posted in General | Tagged | 3 Comments

When Will I Learn All of Emacs?

Never, apparently

Posted in General | Tagged | 2 Comments