0

How can I introduce hierarchical sections in org-mode without requiring the tasks within those sections to have a large number of asterisks?

To context is that I'm looking for a standardized plaintext format for todo lists that I can use to collaborate with non-technical team members who only use plaintext editors, while still providing software support to those of us willing to install special software. Goals:

  1. the list can be divided into hierarchical sections
  2. the prefix of each task within these sections does not vary based on its nesting level (so, for example, tasks nested 4 levels deep could have a prefix of '*' or '-' but not '****', and not required indentation that varies with nesting level)
  3. tasks can have notes (that is, each task has a title but also possibly body text associated with it)

For example, in org-mode I can write:

* Shopping tasks
** buy milk

* Apartment tasks

** urgent apartment tasks
*** bedroom
**** bathroom in bedroom
***** fix leak
remember to turn off water first!

** not urgent apartment tasks
*** kitchen
**** clean out fridge
*** bedroom
**** bathroom in bedroom
***** buy more toilet paper
***** clean floor
***** clean sink

But now the actual tasks have a ridiculous number of asterisks in front of them. This is difficult to read and write for my teammembers using plaintext editors, and it's difficult for them to introduce new sections, delete sections, or move tasks between sections.

This can be improved by using '-' lists instead of tasks:

* Shopping tasks
 - buy milk
* Apartment tasks

** urgent apartment tasks
** bedroom
*** bathroom in bedroom
 - fix leak
   remember to turn off water first!

** not urgent apartment tasks
*** kitchen
 - clean out fridge
*** bedroom
**** bathroom in bedroom
 - buy more toilet paper
 - clean floor
 - clean sink

but now org-mode doesn't treat tasks as tasks, which makes a lot of its todo features unusable. Maybe I could use an extension in emacs but often I am using iOS or Android org-mode clients. The org-inlinetask extension is unusable for another reason too, that is that all tasks have 15 asterisks which is, again, tedious when using a plaintext editor.

So, my question is, is there another way to introduce section headings that does not force you to put many asterisks as the prefix for tasks within the sections? Something like this:

= Shopping tasks
* buy milk

----

= Apartment tasks

== urgent apartment tasks
=== bedroom
==== bathroom in bedroom
* fix leak
remember to turn off water first!

== not urgent apartment tasks
=== kitchen
*  clean out fridge
=== bedroom
==== bathroom in bedroom
* buy more toilet paper
* clean floor
* clean sink

(in the wished-for example, I also used '----' to break up the document into major parts). If something like this is not possible in org-mode, then what do you recommend? Some things I've heard of include TaskPaper, but I think it requires variable indentation (which is much easier to read than asterisks, but still a little bit of a pain to edit in plaintext). I could also use Markdown and one of the Markdown-compatible todo lists tools, or just use Asciidoc with no todo-specific support. I use emacs on the computer and various apps on Android and iOS, and some of my teammates will be using a plaintext editor (like Windows Notepad).

1
  • 1
    I use the + sign for a main list heading and - for everything (lists) underneath that main list heading. I also sometimes use all caps for the list heading with a + sign, and maybe a colon at the end before using the sublists of - underneath that. "Unordered list items start with -, +, or * as bullets ...": orgmode.org/manual/Plain-lists.html I see nothing about using an equal sign ...; however, I use them as dividers to break up the lists into different sections; e.g., ====================. I have added a regex to the font-lock stuff to highlight the + / -.
    – lawlist
    Commented Aug 18, 2019 at 0:39

2 Answers 2

2

For situations like this you could set up your tasks with subtasks. You use asterisks to identify major tasks, with associated subtasks nested underneath with checkboxes:

* TODO Task One
* TODO Task Two [ / ]
- [ ] subtask 2.1
- [ ] subtask 2.2

The manual describes all the options supporting this:

https://orgmode.org/manual/Checkboxes.html#Checkboxes

0

There may not be a way to do this within org-mode. I defined a subset of Markdown that I call mdtd (Markdown todo), and created a Python script to translate mdtd files into either todo.txt or org-mode:

https://gitlab.com/bshanks/mdtd

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.