Since upgrading to Ubuntu 15.04, I’ve been living with systemd. I’ve been a Debian user mainly and was wary of the doom-and-gloom comments about systemd but actually, I’ve been a bit impressed with it so far. One thing that is undeniably easier with systemd is writing what System V init sytems called init scripts. In systemd they are known as service files.
Anyway, I usually run emacs as daemon and I had the idea that emacs could run as a systemd service! Immediately I fell into the trap that Umberto Eco describes:
there are two laws no human being can escape: the first idea that comes into a person’s mind will be the most obvious one; and, having had an obvious idea, nobody ever thinks that others may have had the same idea before.
So yes, there plenty of systmed emacs service files out there, but this one is mine.
ExecStop=/usr/bin/emacsclient --eval "(progn (setq kill-emacs-hook 'nil) (kill-emacs))"
The main difference from my config is that I’ve added the
GPG_AGENT_INFO data so that emacs can uses GPG agent. I run
keychain so my ssh-agent and gpg-agent are launched at login. There are probably nicer ways to pass the environment variables. This only works if you user ID is 1000, which it most likely will be if you are the first user. Just check the output of
id -u and change the 1000 to whatever it says and it will probably work.
Lastly, I run this service as a user so I put the file in
~/.config/systemd/user/emacs.service and then did:
systemctl --user enable emacs.service
systemctl --user start emacs.service
emacsclient to connect to the server, which I’ve aliased to just
e, so I’ll type
e -nc to open a new instance for example.
A person who pulls something apart; a person who divides or separates something.
Brit. /dɪˈsəːptə/ , U.S. /dᵻˈsərptər/
Etymology: Probably partly < post-classical Latin discerptor person who separates something (1748 in the passage translated in quot. 1854; already in 14th cent. in sense ’adversary’), and partly directly < classical Latin discerpt-, past participial stem of discerpere discerp v. + -or suffix.(Show Less)
From, The Novel in Analog: Joshua Cohen’s Book of Numbers
As Cohen’s work reminds us, printed books are mostly private pleasures, lonely ones even. Unlike so much media today, they don’t target, watch, or measure us; they don’t flatter us with personalized stories based on accumulated data profiles (not yet, at least). But even as this essentially analog quality has convinced us that novels are doomed to be political dead zones, it has become one of their newfound attractions. “If you’re reading this on a screen, fuck off,” goes Book of Numbers’ opening line.
By the way, if you don’t have the EFF’s Privacy Badger extension installed, go install it. Privacy badger does care.
Let’s say you like to read the NYTimes but you may find that the 10 article limit per month to be a bit restrictive. After all, you go to your local library and read the gray lady there but sometimes well, you also re-read them online. But instead of reading the article you receive a bunch of indistinguishable-from-malware popups about reading more than 10 articles per month. How to get rid of them?
Well, you can just go clear your cookies in Chrome/Chromium. But chrome stores cookies in a SQLite database so you could make a script to go into the database, and remove offending entries. If you were to go and do that, say on Linux, you might end up with a SQL file like this:
delete from cookies where host_key LIKE '%nytimes%';
If that file was called
nomnomnom.sql, you could have a script called
nomnomnom.sql that did
sqlite3 $CHROME_COOKIES < ~/bin/nomnomnom.sql
Then you could add this to your crontab to say, get rid of the nytimes cookies everyday. As an example.
This Tuesday, I’m on a panel with John Hawley, the community manager of the MinnowBoard Max, where we’ll be discussing the future of open source hardware. Spoilers, I think the future looks good. With the panel upcoming, I decided to dust off my MinnowBoard Max (MBM) for a little project–I wanted to run Tails on the device.
Continue reading “Run Tails from the MinnowBoard Max”
It’s been a while since I published anything personal on here. Not that I ever really did that, but I’ve been having some blogging guilt lately. I present the following unorganized list of things going on which you may, or more likely may-not find interesting. I tend to get introspective around birthdays that are divisible by five. This is a complete random collection of items. You have been warned.
Continue reading “A list of random things going on in my life”