On Tue, Jan 23, 2018, 5:24 AM Karl Voit <devn...@karl-voit.at> wrote:

> 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.

> --

Kaushal Modi

Reply via email to