Emacs workflow: EXWM and magit-clone

I was watching Tony Aldon’s video about refactoring in Emacs. Went to his website and noticed that he has a git repository of all his posts in org-mode format. Cool, this will be a nice and interesting way to dig through his knowledge of this tool.

My whole computer life is inside this “text editor”. I use it as my WM, code editor, productivity tool, note-taking tool, file browser, etc, etc. This gives me cool powers. Everything is a buffer, even my browser is an Emacs buffer. Another, intriguing feature of EXWM are simulation keys. What they do is very simple – they translate one key binding to another in non-emacs buffers. This allows me to use M-w for coping in Firefox or LibreOffice. No more mental switching between Emacs and rest of the world.

Going back to original thought behind this post. I wanted to clone repository. Normally this involves coping a link in browser, opening terminal, going to the proper folder and finally cloning the repo. In my case it was just, copy the link, then just M-x magit-clone, paste link, select the root directory and boom. Done. Here is a bonus – if I wanted to, I could change all of this into one function and add key binding to it.

That was the first simple workflow. Then I though: hey this could be a nice short post on my blog, you know, then one you never write on. Quick C-x f (find-file), type in path and I’m ready to write post in Markdown. Emacs noticed me, that the file is in a non-existing directory. Right, I never did create a folder for posts on this blog. M-x mkdir, enter, and we’re done.

There are a lot of those small tools that make Emacs my third hand. Yes, it is cumbersome at moments. It’s an old geezer and has its mood, requires a lot of tinkering, but in the end I cannot live without him. Everything else seems to be…


PS. What do you think? Should I write more of those short posts, showing workflows in Emacs and EXWM?

Leave a Reply

Your email address will not be published. Required fields are marked *