Texting from inside Emacs


A few weeks ago I discovered that one can actually send text messages from inside Emacs!  The trick is you need to have a JMP account.  JMP.chat is free software VoIP provider that costs $3 a month to use.  Once you have a JMP account, you sent texts with XMPP.  Since,  Emacs supports XMPP (jabber), Emacs can now send text messages!


I heard about jmp.chat recently, and I decided to give it a go.  It’s a cellular provider that sends all communication over wifi, and it’s freedom software!   You can pay jmp for this service, or you could install your own jmp server and run it yourself!

So why use JMP?  Do you want to support freedom software?  Do you like the idea of sending and receiving communication via freedom software?  If you do then give it a try.  You’ll learn about XMPP, which is a federated instant messaging protocol.  You’ll also save a lot on your phone bill, because JMP only costs $3 a month!

Emacs Errors


This morning, I was rummaging through my emacs init files, and I was noticing that as emacs started up, it seemed to be opening a lot of files.

“Hmmm, am I using desktop-save-mode?”  I wondered.

Desktop-save-mode is an emacs mode that saves your emacs session.  It remembers, which files you had opened, point’s location in the files, etc.   When you open emacs again, emacs opens just the way you had it the last time. It can be kind of nice, but it can also make emacs slow to start.

So I was noticing that when I started emacs, it was taking opening a ton of files, and wasting a lot of time doing so.  So I looked through my init file and found that I was NOT using desktop-save-mode.  So something else was causing this.

I had to find the error the hard way: I commented more than half of my init file. Then I shut down emacs.  Restarted.  Then I un-commented out one line.  Shut off emacs restarted. Repeat.  I finally found the culprit:

(add-hook ‘after-init-hook ‘org-agenda-list)

Basically after my Emacs load, org-mode is opening lots of files to build the agenda.  It had to open 15 files!  And I only needed two of those files to build the agenda!  So I removed several files from the org-agenda-files variable and that solved the problem.  Onto the next issue with my emacs config files!

Doing whatever I wanted

So today I had a full day of just doing whatever I wanted.  Here’s a recap of the cool things that I was able to do:

  • I got one of my websites to use let’s encrypt:  www.gnusites.com.  As an interesting sidenote, https://www.gnucode.me now points to www.gnusites.com.  That’s not intentional.  I’ll have to fix that another day.
  • I fixed a really annoying error with gnus, which is an email client for emacs.  Basically it was trying to access a server that didn’t exist.  (nntp “news”).  Every time I started gnus, it would try to access this fake server and fail.  A simple (setq gnus-select-method ‘(nnnil “”)) solved the problem.
  • I made this site serve images from a CDN (allegedly).  I’ll have to verify that it actually is.
  • get org babel sh code working on remote machines!  This actually works!  I wish I was writing this post in org-mode so I could properly show it off.  Basically I have a file on my local machine.  And in Emacs I have a file that looks like this:

#+BEGIN_SRC sh :results output :exports both :dir /ssh:joshua@richardrahl:/home/joshua

: dead.letter grep

Emacs is using tramp to ssh onto my remote machine, and show the contents.  Nifty eh?

This basically amounted to me modifying /etc/hosts/ to make richardrahl point to my linode.  I also used ssh-copy-id to copy my gpg key to that linode.  It’s pretty spectacular!


IRC stands for internet relay chat, and it is an instant message protocol that is older than your great granddaddy, probably.  It is where hackers and programmers hang out (remember that a programmer is a hacker).    This past week I finally learned why it’s soo much fun to hang out in IRC.  To start using irc, one needs an irc client, and a room to join.  IRC users generally hang out in chat rooms to talk about that room’s topic.  There’s rooms for #php, #emacs, #wordpress, etc.  But before I can continue my story, I first need to explain emacs.

So I use the text editor Emacs (and it’s sad that I am not using Emacs to write this blog post).  Emacs started out as Richard Stallman‘s programming editor, but it has since morphed into an email client, web browser, documentation viewer, word processor, accounting software, music player, calendar, etc.  Basically it is a one stop shop for all of your computing needs.

Naturally, Emacs has an irc client: erc.  I’ve been using erc for a few years, but it’s hard to configure (honestly Pidgin is a better beginner irc client).  For some reason erc would not authenticate me to irc.freenode.net.  It would let me chat sure, but it would not let me use my chosen nickname.   grrr.

This is a problem, because some chat rooms won’t let you join, unless you are authenticated!  So I could not join the #emacs room to complain about #erc.

“So how can I fix this?”  I ask myself.

Since I was alone at the time, I also answered myself, “I know! M-x helm-info-erc RET t”

This let me open the info documentation for erc inside Emacs.  After a bit of searching I found this:


— User Option: erc-prompt-for-password
If non-‘nil’ (the default), ‘M-x erc’ prompts for a password.

If you prefer, you can set this option to ‘nil’ and use the
‘auth-source’ mechanism to store your password. For instance, if you
use ‘~/.authinfo’ as your auth-source backend, then put something like the following in that file:

machine irc.example.net login “#emacs” password sEcReT

So naturally I added these lines to my .authinfo.gpg.   And I still could not get authenticated to irc.  Sure, I could do a M-x erc and manually enter in my username and password each time, but that’s too tedious.  So I asked around on the irc room, and someone recommended that I change the lines to:

machine irc.freenode.net password PASSWORD port 6667
machine irc.freenode.net password PASSWORD port 6697

Then miraculously erc worked flawlessly!  I’m really grateful to the people on erc, who were so helpful!

Installing WordPress

Installing WordPress from a linode account can be a bit of a chore, but I’ve done it again!

The main issue that I had was that WordPress wouldn’t automatically update for me.  I’ve remembered running into this issue before, and WordPress has a section on it on their codex. Essentially:

WordPress determines what method it will use to connect to the filesystem of your server based on the file ownership of your WordPress files. If the files are owned by the owner of the current process (i.e., the user under which the web server is running), and new files created by WordPress will also be owned by that user, WordPress will directly modify the files all by itself, without asking you for credentials.

So all I had to do was figure out what worker process nginx was running under.  After chatting on #debian or irc.freenode.net for a second, a user said that their worker process was www-data.  And indeed cat /etc/passwd shows that there is a user www-data on my system.  And /etc/nginx.conf said

user www-data;

All I had to do to get it to work was a

cd /var/html/www/;  sudo chown -R www-data .

And now WordPress will handle updates automatically!  Coolio!

nx was running under.  After chatting on #debian or irc.freenode.net for a second, a user said that their worker process was www-data.  And indeed cat /etc/passwd shows that there is a user www-data on my system.  And /etc/nginx.conf said

user www-data;

All I had to do to get it to work was a

cd /var/html/www/;  sudo chown -R www-data .

And now WordPress will handle updates automatically!  Coolio!