John Kitchin <jkitc...@andrew.cmu.edu> writes: > Marcin Borkowski <mb...@wmi.amu.edu.pl> writes: > > > Check the last element of org-heading-components. > > * Headline :tag1: > > #+BEGIN_SRC emacs-lisp > (org-heading-components) > #+END_SRC > > #+RESULTS: > | 1 | 1 | nil | nil | Headline | :tag1: | > > > > >> Hi list, >> >> I'd like to implement splitting an org file at tagged entries in my >> org-one-to-many library (as requested on the list by Daniel Clemente). >> How do I check whether a specific headline (say, one a point is at) has >> some tag (but not inherited)? >> >> TIA,
alternatively you could use: * Headline :tag1: #+BEGIN_SRC emacs-lisp (let ((org-use-tag-inheritance nil)) (save-excursion (outline-previous-heading) (org-element-property :tags (org-element-at-point)))) #+END_SRC #+results: | tag1 | -- cheers, Thorsten