Recent Changes

Updates since 2023-05-29 18:39 UTC

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

2024-04-27

  • 06:39 UTC (new) (history) 2024-04-27 Emacs everywhere . . . . mbork A few years ago I mentioned that I use Textern so that I can easily edit input boxes and text areas in Emacs. While I still use it, it seems less and less great. More and more web apps do crazy JavaScript things with their input​s and textarea​s, and they sometimes interfere with Textern in unpredictable ways. Recently, I found something similar but possibly better: Emacs everywhere.

2024-04-22

  • 05:53 UTC (new) (history) 2024-04-22 Next-Error-Follow mode . . . . mbork A few weeks ago I wrote about Emacs’ Follow mode. It turns out that searching for follow-mode on my blog reveals an old post about Ibuffer which is very short and unfortunately a bit misleading. It seems that the mention of Follow mode there was really meant to mean Next-Error-Follow mode. It is a completely unrelated, but also useful concept.

2024-04-15

  • 17:23 UTC (new) (history) 2024-04-15 Improving recenter-top-bottom and reposition-window . . . . mbork If one can be a fan of an Emacs command, then I am a huge fan of recenter-top-bottom (C-l) and reposition-window (C-M-l). I use them all the time to see the context of what I’m editing at the moment. However, they are not always that useful. They are rather crude – recenter-top-bottom only has three “settings”, as the name suggests, and reposition-window has only two (it either puts the first line of a function, or the first line of a comment preceding the function at the top). As I mentioned a few weeks ago, I sometimes work with rather long functions – and sometimes I am in the second of two shorter ones, but I want to see the first one, too. Also, I don’t only edit code – I edit prose, too, where paragraph play the role of functions, and Org files, where there are even other structural elements – headlines, tables and source blocks in addition to paragraphs, for example. I decided to write a variation on the theme of reposition-window, which – instead of putting the first line of the function I’m in at the top, it tries to put the first line of a “section” I’m in at the top.

2024-04-08

  • 06:30 UTC (new) (history) 2024-04-08 Even more Magit tips . . . . mbork Almost five years ago I wrote a short post with some Magit tips. Well, why not write some more? Magit is slowly but constantly evolving, and recently I discovered something very useful I didn’t even know existed.

2024-04-01

  • 06:14 UTC (new) (history) 2024-03-31 Easter 2024 . . . . mbork Christ has risen from the dead! And so shall we all. I wish you the best for Easter! And of course, as the tradition dictates, I will pray a decade of Rosary for all readers (of both of my blogs). Happy Easter, rejoice!

2024-03-18

  • 16:52 UTC (new) (history) 2024-03-18 Follow mode . . . . mbork It is a fairly common opinion that a function should not be larger than your screen. The reality, though, is often different. And even if your functions are shorter, you may want to see more than one at a time. The problem is that our screen are usually not that high. (My laptop gives me 66 lines of text with normal font settings.) You can have an external monitor rotated vertically (I have that at work to see as much of the logs of the application I’m working on as possible), but Emacs gives us another solution – the Follow mode.
  • 16:51 UTC (new) (history) 2024-03-16 Follow mode . . . . mbork Deleted 2024-03-16_Follow_mode

2024-03-11

  • 05:35 UTC (new) (history) 2024-03-11 More psql tricks . . . . mbork As I mentioned many times, I am a PostgreSQL fan. I wrote several times about psql, the default PostgreSQL terminal client. A few days ago I gave a short talk in my company about the virtues of psql, and in preparation for that I looked at its manual (again). As is often the case, I discovered a few hidden gems I didn’t know about.

2024-03-02

  • 05:09 UTC (new) (history) 2024-03-02 Some tips about Emacs keyboard macros . . . . mbork Some time ago I had to create some rather repetitive code. These days I often use multiple cursors for such things, but for some reasons this time I decided to go the traditional route and use the built-in keyboard macros. Here’s the catch, though. When you want to use keyboard macros and insert an (incremented) number for every occurrence, you can type f3 (kmacro-start-macro-or-insert-counter) while recording the macro. What I needed, though, was to insert that number twice for every execution of the macro.

2024-02-28

2024-02-26

  • 17:48 UTC (new) (history) 2024-02-26 A simple trick with URL parsing in plain text emails . . . . mbork Today I only have a very short tip I thought up a few days ago. If you sometimes send URL via emails (like me), and you absolutely hate HTML emails (like me), there is a common and annoying problem. If the URL you send is the last thing in a sentence, and you want to be correct and end that sentence with a period (or other punctuation), a lot of email clients will treat that punctuation as part of the URL, and of course such “modified” URL won’t work for the recipient. I usually solved that by putting a space between the URL and the period – not 100% correct, but I could live with that. A few days ago it occurred to me that there is another, slightly hackish way to solve my issue. From now on I’m using a hash instead of a space. Assuming that the website I link to doesn’t have any element with the id~ of a period (or any other weird thing like an exclamation mark, of a period followed by a closing parenthesis etc.), the punctuation will be ignored by the browser, but I won’t need to put any space before the end-sentence period. You’re welcome!

2024-02-17

  • 16:30 UTC (new) (history) 2024-02-17 Opening external drives in Dired . . . . mbork I use external drives pretty often – for backups, for moving files between machines, and for storing mp4 files, for example. I’ve been using UDisks for quite some time now. It automounts an external drive under the /run/media/$USER/VolumeName directory (where VolumeName is different for each drive, of course). I also use Dired as my main file manager. As most Emacsers know, it’s far from shiny, but it’s incredibly powerful, especially combined with some other Emacs features. One problem I have is that when I insert a drive into one of the USB ports, I’d like to be able to open it in Dired.
  • 16:29 UTC (diff) (history) Comments on 2024-02-12 Finding Bible quotes . . . . mbork Ha, that's *very* interesting, thanks! I'm wondering if it's documented anywhere...

2024-02-12

  • 05:39 UTC (new) (history) 2024-02-12 Finding Bible quotes . . . . mbork I often have the need to find some particular quote of the Bible – either I am reading some religious text or I want to link to some passage on my blog. What I miss is the ability to quickly see the relevant passage, open it in a browser and create an Org mode link to it.

2024-02-05

  • 05:45 UTC (new) (history) 2023-02-05 From the kill ring to a register revisited . . . . mbork Two weeks ago I wrote about my little command to move the topmost (or some other) kill ring entry to a register. It turned out that this particular post – which I thought was rather niche – spurred more interest than apparently more useful posts I have. Go figure.

2024-01-26

2024-01-22

  • 04:18 UTC (new) (history) 2024-01-22 From the kill ring to a register . . . . mbork I am probably one of the five or six people on this planet who use Emacs registers. I mostly use them for text insertion (especially when I need to insert some boilerplate – and especially more than one piece of it – several times, but it’s not general enough to be put into Yasnippet), but I sometimes store window configurations in them, and I might have used them for other purposes once or twice. Sometimes, though, I kill some text to yank it elsewhere and only then realize that I’ll need to kill/yank some other fragments, too. Using the kill ring to do this one time is fine (with M-y or with browse-kill-ring); using it more times is rather inconvenient. Hence I decided to write a little command to copy the text from the kill ring to a specified register. And here it is.

2024-01-08

2023-12-25

  • 21:26 UTC (new) (history) 2023-12-25 Merry Christmas 2023 . . . . mbork As usual at this time of year, let me wish all of you Merry Christmas! And also as usual, I promise to say a decade of the Holy Rosary for everyone reading my blog.

2023-12-11

  • 17:05 UTC (new) (history) 2023-12-11 Replacing TeX control words behind the point . . . . mbork Two weeks ago, a friend from Polish TeX Users’ Group mailing list asked about an Emacs tool to replace control sequences with their Unicode counterparts. I also have this need from time to time, and I usually go with the TeX input method. He is not satisfied with it, though, because it replaces too much for him – for instance, he doesn’t want a_1 to get translated to a₁. He remembered some utility (written by another Polish TeX user) which replaces a TeX sequence with a Unicode equivalent, but only on demand. Since that one seems to be lost in the depths of time, he was left without a solution.

2023-11-27

  • 08:33 UTC (new) (history) 2023-11-27 Clocking in to parent entries . . . . mbork Like many, many Emacs users these days, I’m a heavy user of Org mode. In fact, both of my blogs are written in Org. And while this very blog usually has fairly short entries, my other blog has much longer posts, divided into subsections. This creates a minor problem for me. I track time I spend on writing, but I don’t want to track time spent on individual sections of a blog post. In other words, even if I am in some lower-level heading, when I clock in, I want Org to clock in in the parent heading. Emacs being Emacs, I figured there must be a way to make that happen automatically.

2023-11-13

  • 06:24 UTC (new) (history) 2023-11-13 Coloring CamelCase . . . . mbork Some time ago one of the members of the Emacs mailing list asked about coloring CamelCase identifiers. His idea is to define two faces and have all “even” words in a camel case indentifier colored with one of them, and the “odd” words colored with the other one. The question suggests using some code from Glasses mode, which is a lesser-known Emacs feature which inserts undescores between words in camel case identifiers (and it does it using overlays, so the underscores are not really part of the buffer, they just look like this). My general rule is to avoid camel case whenever I can, but I sometimes use Glasses mode, especially when I have to deal with jsx files, where camel case is the standard. It turns out that Glasses mode already has (almost) what is asked for.

2023-10-30

  • 18:52 UTC (new) (history) 2023-10-30 My plans for 2023 - October update . . . . mbork It’s been another two months since my last update, so here we are again! It’s been a busy two months for me, though some plans still are not brought to the forefront (which is a shame, I know, but I can’t do everything).

2023-10-14

  • 05:04 UTC (new) (history) TODO 2023-10-14 Avoiding repetitions . . . . mbork Deleted TODO_2023-10-14_Avoiding_repetitions
  • 05:03 UTC (new) (history) 2023-10-14 Avoiding repetitions . . . . mbork I write a lot of prose. That does not mean I’m good at it nor very creative – I haven’t written any novels or even short stories. By “prose” I mean writing in a natural language (mostly English nowadays). In fact, most of the writing I’ve done in my life is technical in nature (usually either about technology or about mathematics). And (as you obviously know) I’m also a technology geek and an Emacs user. An immediate thought is: how to make Emacs help me write better?

2023-09-30

  • 19:17 UTC (new) (history) 2023-09-30 Confirming potentially dangerous actions . . . . mbork A common situation is when I want to do something on my computer with possibly destructive consequences, like deleting a file, truncating a database table etc. One common approach to making sure this won’t happen accidentally is to require the user to press y or even type yes (this is what Emacs does with its y-or-n-p and yes-or-no-p functions). Some time ago I had a similar need in a shell script. I was afraid, however, that even requiring the user to type yes is not enough – it is easy to condition oneself to type a three-letter word without much thinking, after all.

2023-09-18

  • 18:41 UTC (new) (history) 2023-09-18 Making Anki flashcards from subtitles . . . . mbork Those of you who follow my blog know that one of my hobbies is translating subtitles. The main reason I do this is to watch stuff with my daughter, who doesn’t yet speak English fluently. Some time ago it dawned on me that I can use my translations twice. Not only can I watch films and tv series with her, but I can use them to help her learn English.

2023-09-02

  • 11:52 UTC (new) (history) 2023-09-02 Irregular recurring TODOs in Org mode, part I . . . . mbork Some time ago I mentioned a very peculiar type of TODOs I’d like to implement. These are things I’d like to do from time to time, but not necessarily on a regular basis. A canonical example is an inspirational blog post I’d like to reread once in a while. I admit that this idea is inspired by spaced repetition, where things I want to remember are presented to me repeatedly, but with increasing intervals. Here, however, the situation is a bit different.

2023-08-21

  • 17:47 UTC (new) (history) 2023-08-21 My plans for 2023 - August update . . . . mbork Since about two months have passed since the last blog post with my 2023 plans update, it’s time for another one. This time it is going to be a bit shorter, since not a lot of stuff has happened (or rather, a lot did, but it was mostly concentrated on one of the projects, which I think is… good?).

2023-08-05

2023-07-22

2023-07-15

  • 04:26 UTC (new) (history) 2023-07-15 Drawing ASCII art charts in Emacs buffers . . . . mbork Two months ago I wrote about how I track my weight in Emacs. I am still doing it, and dieting works quite well, but I had one problem with my setup: I really wanted to have a graphical representation of my weight data – in other words, a chart. After quickly assessing the existing solutions (the chart.el library included in Emacs and Org Plot, I decided that I need something else. I don’t want to have to run an external program (in this case, gnuplot), and I want to have a simple ASCII art scatter plot (but neither a bar chart nor just an additional column containing a histogram of the values in the table.

2023-07-08

  • 13:20 UTC (new) (history) 2023-07-08 Finding a common prefix of a set of strings . . . . mbork Some time ago I needed a very specific thing. Given two strings, I wanted to find their longest common (initial) substring. For example, given abc and abd, I wanted ab. I thought that Emacs Lisp must have something like this already, and I wasn’t wrong. It turns out there are even two functions which can do that!

2023-07-03

  • 05:24 UTC (new) (history) 2023-07-03 From mp3s to podcasts . . . . mbork Many years ago I used to listen to podcasts a lot. I had my two favorite ones, and they provided me with more than 90 minutes of interesting material to listen every week (and that is not counting several hundred archive episodes!). Recently, I decided to start listening again to interesting people while I commute. This time, though, I want to listen to webinars instead, and I have them in the form of mp3 files. Thing is, how do I get them on my smartphone?

2023-06-26

2023-06-19

2023-06-12

  • 18:08 UTC (new) (history) 2023-06-12 Counting time, backwards . . . . mbork Some time ago I thought that I would like to have a feature Org mode doesn’t seem to have. There are things I would like to do once in a while, but I don’t need a reminder with a hard deadline (like a repeating one) – I’d prefer a gentle nudge. What if I could display a list of things I select, each one with information how long ago I did it last?

2023-06-03

  • 10:31 UTC (new) (history) Comments on 2023-06-03 Org agenda clock check . . . . Anonymous You missed the very important and really helpful overlap check!
  • 05:30 UTC (new) (history) 2023-06-03 Org agenda clock check . . . . mbork Some time ago (well, a long time ago) someone posted an interesting discovery in Org mode agenda: “clockcheck mode”. I stored the link to that message with the intention of blogging about it and forgot about it. I rediscovered it some time ago and decided to take a look.

More...

Filters