[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Make tag inheritance explicit
From: |
Kaushal Modi |
Subject: |
Re: [O] Make tag inheritance explicit |
Date: |
Tue, 23 Jan 2018 12:16:17 +0000 |
Org-mode has perfect tag inheritance but unfortunately
the export methods I am using do export the tags only to the
headings they are assigned to and not to their sub-headings via
inheritance.
Hello,
I am curious how you are exporting. Are you exporting using subtree scope? I am asking because I am using the exact same style of tagging for my posts, and I export using subtree scopes using ox-hugo,.. and I faced the exact same challenge.
The trick is to:
1. Set org-use-tag-inheritance to t (temporarily in let so that it doesn't populate the user-set global value).
2. Use `org-get-tags-at' with point on "Task 1" heading in your example. `org-get-tags' returns a list of tags *only* at the current heading. `org-get-tags-at' returns inherited tags too.
Hope this helps.
--