Recent Changes

Updates in the last 90 days

1 | 3 | 7 | 30 | 90 days
List all changes Include rollbacks Include minor changes
List later changes RSS RSS with pages RSS with pages and diff

2022-01-17

  • 20:12 UTC (new) (history) 2022-01-17 Making code snippets in Org-mode easier to type . . . . mbork From time to time people tend to discuss the Org markup – some people want to extend it in one way or another, some people want to make it more Markdown-ish. I tend to agree that the selection of the tilde (~) to denote code is a bit inferior than Markdown’s choice of the backtick (`). But keep in mind this: I don’t have a problem with looking at my Org file and seeing (lots of) tildes. After all, font-lock does a good job of telling me that this is code. I have a problem with typing these tildes, since they require me pressing the shift key – and if I have a lot of small code snippets, this is not very comfortable. Add to this the fact that I happen to write in Markdown pretty often (when I use Markdown-based tools, like Slack or Jira), and I started wondering: why couldn’t I press the backtick in Org-mode to type a tilde (and vice versa so that I don’t lose the ability to type a backtick)?

2022-01-10

  • 21:59 UTC (new) (history) 2022-01-10 Simple tmux scripting revisited . . . . mbork Some time ago I wrote about my (very simple) tmux script. Since then I started to like tmux even more, and in fact I tend to create a similar script for every major project I work on. Last time, however, I noted how the sleep part is very fragile (and less than elegant). Since then I realized that I do not need any advanced scripting to run command Y in tmux window B when command X in window A finishes its job. In fact, this is very simple, and I’m ashamed I didn’t think about it earlier.

2022-01-03

2021-12-24

  • 09:44 UTC (new) (history) 2021-12-24 Merry Christmas . . . . mbork It seems that it is already a tradition that I wish Merry Christmas to all my readers! Of course, as old-timers surely know, I’ll offer a decade of Rosary for you.

2021-12-18

  • 12:44 UTC (new) (history) 2021-12-18 Automatically starting Firefox with a clean profile . . . . mbork I am currently working on a side project, which is a very specific web application. One of the requirements is that several users should be able to be logged in simultaneously and interact with each other in real time. For the “real time” part, I use websockets (with the Socket.IO library, which is quite nice to work with). Today, however, I wanted to say something about a different thing: testing. Not automated testing (I will probably blog about it later, too), but good old manual testing. The trouble is, how do I log in as two (or more) users at the same time? I can’t use separate browser tabs, since they share cookies and logging in or out in one of them logs me in or out in all of them. It turns out that if you open several “private browsing” windows in Firefox, they all share cookies and similar data, too – that wasn’t obvious for me, but this is how it works. I could use separate browsers (say, Firefox and Chromium), but that is far from comfortable – and obviously scales very poorly. Of course, Firefox profiles are exactly what is needed here. They have one drawback: it takes a lot of clicking to create a new profile. (Also, you have to name it, keep track of your profiles, delete the ones you don’t need anymore…) So, let’s script it.

2021-12-11

  • 10:53 UTC (new) (history) 2021-12-11 My productivity system - design . . . . mbork Note: this is another of those really long posts. It’s probably only interesting for some productivity geeks, since it describes my current system for beating procrastination and making most of my time (or rather, one layer of that system). In a future post I’m going to write about some (Org-mode-based) tools I use to actually implement it, but for now I just want to show the main ideas – in fact, this system was first implemented with pen and paper, and in fact it worked very well that way.

2021-12-04

  • 07:59 UTC (new) (history) 2021-12-04 Org timer once again . . . . mbork I’ve been writing about the Org timer about a month ago, and today I’m revisiting this topic because once I started using it, I discovered a cool feature which is, let’s say, half-documented.

2021-11-29

  • 13:00 UTC (new) (history) 2021-11-29 Counting the number of columns in PostgreSQL . . . . mbork So I had this pretty big PostgreSQL table, and I wanted to know how many columns it had. Should be simple enough, right? Remember about using psql to show how some comands are converted to SQL? Well it didn’t really help me that much.

2021-11-20

  • 09:14 UTC (new) (history) 2021-11-20 Tricks with GNU date . . . . mbork Date- and time-related computations are hard – we all know this. Sometimes the problem is that there are many edge cases, sometimes the issue is conceptually hard, and sometimes both. Recently, I had an instance of a problem which was conceptually hard (at least for my little brain).

2021-11-13

  • 04:44 UTC (new) (history) 2021-11-13 y-or-n-p but with RET meaning yes . . . . mbork Today, I had an extremely specific need. I wanted the Elisp function y-or-n-p (which asks the user a yes-or-no question, expecting a one-key answer of y or n), but I wanted to interpret RET (or “Enter”) as “yes”. It turns out that by default it means “exit”, which is because y-or-n-p-map has no binding for RET, and y-or-n-p falls back on query-replace-map (in a rather convoluted way). So, here is one way I could change it:

2021-11-06

  • 05:05 UTC (new) (history) 2021-11-06 The Emacs Lisp book is finished . . . . mbork So, it’s done! I am very proud to say that after about 10 months of work I finished writing my Emacs Lisp book. If you haven’t heard of it yet, it’s called “Hacking your way around in Emacs” and it is an intermediate-level textbook on Emacs Lisp, showing a lot of useful things on about 100 pages.

2021-11-01

  • 19:23 UTC (new) (history) 2021-11-01 Org timer with sound . . . . mbork For today I have another tip. I often need to know when some amount of time has passed. I know about org-timer-set-timer, but I never got to using it because it only gives a screen notification, so it’s useless when you don’t look at the screen. Or so I thought. It turns out that you can set the variable org-clock-sound and have Org play the given file when the timer runs out. Great!

2021-10-25

  • 17:56 UTC (new) (history) 2021-10-25 debug-on-variable-change . . . . mbork Yet another short tip for today. (Don’t worry, longer, more involved posts will still happen here;-)!) A few years ago I wrote about a few useful debugging features of Emacs. A few days ago I learned that there are more of them now! About two years after I published that post, Emacs learned how to invoke the debugger every time some variable changes its value.

More...

Filters