Emacs rec mode, an all-text database system

Lobsters Hottest Tools

Summary

A blog post introducing Emacs rec mode as a plain-text database system, used for tracking books and integrating with Org mode.

<p><a href="https://lobste.rs/s/p78ttt/emacs_rec_mode_all_text_database_system">Comments</a></p>
Original Article
View Cached Full Text

Cached at: 06/14/26, 07:37 AM

# Emacs carnival: rec mode, an all-text database system Source: [https://www.homepages.ucl.ac.uk/~ucecesf/blog/20260602.html](https://www.homepages.ucl.ac.uk/~ucecesf/blog/20260602.html) I use rec mode to keep track of my books\. Although I do use[calibre](https://calibre-ebook.com/)to manage my ebooks, in particular, I do not like interacting with calibre as it is mouse based\.[3](https://www.homepages.ucl.ac.uk/~ucecesf/blog/20260602.html#fn.3)I have a separate rec database which tracks which books I have acquired, am reading, have finished, or wish to buy\. A couple of typical entries look like this: ``` title: Safe Enough author: Lee Child status: finished Date: 2024-08-29 # collection of short stories, none about Reacher title: All systems red author: Martha Wells series: murderbot number: 1 status: finished Date: 2017-05-02 notes: library ``` Note that these two entries, although both referring to books, have different fields used\. As I'm writing about Emacs, the obvious question is: does org mode support rec files? The answer, as with all things Emacs, is "of course it does"\. With a src block: ``` #+begin_src rec :data my_books.rec author = 'Martha Wells' #+end_src ``` the outcome on evaluating is the following table: titleauthorseriesnumberstatusDatenotesAll systems redMartha Wellsmurderbot1finished2017\-05\-02libraryArtificial conditionMartha Wellsmurderbot2finished2018\-05\-08libraryRogue protocolMartha Wellsmurderbot3finished2018\-08\-07libraryExit strategyMartha Wellsmurderbot4finished2018\-10\-02libraryHomeMartha Wellsmurderbot4\.xfinished2021\-10\-01library, short storyFugitive telemetryMartha Wellsmurderbot4\.5finished2018\-10\-02libraryNetwork effectMartha Wellsmurderbot5finished2020\-05\-02librarySystem collapseMartha Wellsmurderbot6finished2026\-05\-06libraryThe best thing about rec mode is, to repeat myself, that it's all text\. There is no danger of corrupting a database or, at least, if somehow the database becomes corrupt, it should be easy to fix \(using Emacs, of course\)\. Being all text means that version control is trivially supported, which brings me to the final comments below\.

Similar Articles

Emacs Writing Machine

Lobsters Hottest

A blog post about repurposing an old ThinkPad as a dedicated writing machine running Debian and Emacs, inspired by Veronica Explains' writerdeck concept, with tips on configuration and file syncing via Git.

Annotate-in-Place Notes with Emacs and org-remark

Lobsters Hottest

A blog post describing org-remark, an Emacs package for annotating files in-place, addressing the decoupling problem in digital note-taking by keeping notes attached to their source.

Playing with Emacs

Lobsters Hottest

The author shares personal experiences with Emacs, emphasizing its playful and customizable nature, including ASCII art features and its integration into their daily computing workflow.

Emacs appearances in pop culture

Hacker News Top

A blog post cataloguing appearances of the Emacs text editor in films and TV, including The Social Network, Tron: Legacy, Arctic Blast, and Silicon Valley.