planner-trunk.el helps you automatically group tasks according to a set of rules. It sorts and splits your tasks, adding a blank line between groups of tasks. For example, if today's page looks like this:
* Tasks #B _ Buy milk (GroceryShopping) #B _ Learn how to use planner-trunk (PlannerMode) #B _ Buy a notebook (Bookstore) #B _ Buy cereal (GroceryShopping) #B _ Set up my own planner-trunk rules (PlannerMode) #B _ Customize my stylesheet (MuseMode) #B _ Go for a health checkup (BetterHealth)
then you might want to group the tasks into: planner and muse,
shopping list, and other items. If you set up the appropriate rules by
customizing planner-trunk-rule-list
, planner-trunk.el
can automatically rewrite that section line this:
* Tasks #B _ Learn how to use planner-trunk (PlannerMode) #B _ Set up my own planner-trunk rules (PlannerMode) #B _ Customize my stylesheet (MuseMode) #B _ Buy milk (GroceryShopping) #B _ Buy a notebook (BookstoreShopping) #B _ Buy cereal (GroceryShopping) #B _ Go for a health checkup
In this case, you would set planner-trunk-rule-list
to (("." nil ("PlannerMode\\|MuseMode" "Shopping")))
.
You can load planner-trunk with M-x load-library RET
planner-trunk RET or add (require 'planner-trunk)
. If you're
not yet comfortable with Emacs Lisp, you can use M-x
customize-variable RET planner-trunk-rule-list RET to edit this rule
using an easy-to-use interface.
WARNING: Do not keep non-task information in the Tasks section. planner-trunk will delete all non-task lines from the Tasks section of your plan page in the process of grouping the tasks.
After you set up planner-trunk-rule-list
, use M-x
planner-trunk-tasks to try out your rules until you're satistfied.
If you want to do this automatically, you can use (add-hook
'planner-mode-hook 'planner-trunk-tasks)
to trigger it automatically
whenever you open a Planner page.