Category Archives: Software

Migrating from autojump to fasd

fasd is an autojump clone with some nice extra goodies.

In case you don’t know either (let aside any of their many variants, like z, v, …), they all are shell hooks that learn from your filesystem browsing habits, by keeping a database of the paths you access with cd along with their frequency of visit.

This data comes particularly handy when used together with a (generally single letter) command that lets you fuzzy match against a path name, guess the most likely occurence, and send you automatically to it.

For instance, a lengthy cd ~/Developments/MyFavoriteLang/TheProjectType/MyHotProject can often be replaced by j d mhp which is arguably a huge keystroke, time and mind saver. One really has to try it to seize the full benefit.

Anyway, most of the value of such a tool boils down to the completeness and relevance of the underlying paths database, which makes switching from a tool to the alternative very tedious and counter-productive. Hopefully the file format is so simple that in case of a transition from autojump to fasd, it’s as simple as running the following:

cat ~/.local/share/autojump/autojump.txt | pyle -e "words[1]+'|'+words[0]+'|'+str("$(date +%s)")" > ~/.fasd

As to the reasons that pushed me towards fasd, well, the main one is that it also remember files (on top of directories), so it’s possible to use it to invoke vim or xdg-open on recent or frequently accessed files.

Donate Dogecoins: DJi4fgSMxcq5vRjytvCEq9A1TVsDZevd7c Whats This?

Use a Let’s Encrypt certificate with ejabberd

If you want to use a custom certificate on your ejabberd instance, here is how to make it in a way which is understandable by your server.

Ejabberd requires the key, the certificate, and the chain all together in a single file (in this order).
So, if you are obtaining your certificate from let’s encrypt, you can simply:

cd /etc/letsencrypt/live/<the domain>
cat privkey.pem fullchain.pem > server.pem
chown ejabberd server.pem && cp server.pem <ejabberd certificate location>
Donate Dogecoins: DJi4fgSMxcq5vRjytvCEq9A1TVsDZevd7c Whats This?