From: Cletip Cletip <clement020302@gmail.com>
To: Ihor Radchenko <yantar92@gmail.com>
Cc: "Daniel Fleischer" <danflscr@gmail.com>,
"Juan Manuel Macías" <maciaschain@posteo.net>,
orgmode <emacs-orgmode@gnu.org>
Subject: Re: Have all the tags of a heading, with a tag hierarchy
Date: Wed, 31 Aug 2022 13:31:48 +0200 [thread overview]
Message-ID: <CAPHku6O2a_CeSai5EJo55aokKDgdzokFO-bp7AUPxYbFbgg4xQ@mail.gmail.com> (raw)
In-Reply-To: <CAPHku6MzQDJN4RZnoTXScO-1O_ixEkx00XhfVteJ9U++87aWdg@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2541 bytes --]
Just one last clarification to be sure: there is no native function in
org-mode to have the list of tags with a hierarchy? I have to write my
function with the two functions
org-get-tags and org-tags-expand
to get the result I want : a list of tags that takes into account the
hierarchy defined by the "org-tag-alist" variable
Le mer. 31 août 2022 à 13:25, Cletip Cletip <clement020302@gmail.com> a
écrit :
> Sorry, I found the solution : i must just give one argument non-nil to the
> function "org-tags-expand".
> Like this :
> (org-tags-expand "GTD" t)
>
> It's perfect, thanks a lot for your help !
>
> Le mer. 31 août 2022 à 11:01, Cletip Cletip <clement020302@gmail.com> a
> écrit :
>
>> Thank you for your answer, and sorry for the late reply
>>
>> Ok I think I understood the mechanism, but I don't understand how to use
>> this regular expression (the one given by, for example,
>> (org-tags-expand "GTD")
>> which gives me the regular expression "with the other tags"
>> )
>>
>> I see perfectly the idea : a search is done with org-agenda with this
>> regular expression. But I can't use it.
>>
>> The problem is that I don't know how to use this regular expression with
>> a function that returns the tags. Do you have any clue (piece of code where
>> it is already used ? A function allowing me to translate this regular
>> expression into a simple tag? Do I just have to convert this regular
>> expression into a list of tags? Is it possible? I'm asking myself all these
>> questions because I just don't know where to go ^^)
>>
>> Thanks in advance for your future answer.
>>
>>
>> Le lun. 29 août 2022 à 13:57, Ihor Radchenko <yantar92@gmail.com> a
>> écrit :
>>
>>> Cletip Cletip <clement020302@gmail.com> writes:
>>>
>>> > Yes I understand both perfectly. I think some people (like me) would
>>> like
>>> > to connect them, others would not want to bring them together.
>>> > But how to get the hierarchy (or the families) used by org agenda with
>>> a
>>> > function like "org-get-tags" ?
>>>
>>> You will probably need to combine org-get-tags output with regexp
>>> generated by org-tags-expand. Tag hierarchy in Org is a just a search
>>> wrapper - no real tags are changed in the file; only the matching.
>>>
>>> --
>>> Ihor Radchenko,
>>> Org mode contributor,
>>> Learn more about Org mode at https://orgmode.org/.
>>> Support Org development at https://liberapay.com/org-mode,
>>> or support my work at https://liberapay.com/yantar92
>>>
>>
[-- Attachment #2: Type: text/html, Size: 3772 bytes --]
next prev parent reply other threads:[~2022-08-31 11:33 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-28 15:37 Have all the tags of a heading, with a tag hierarchy Cletip Cletip
2022-08-28 16:21 ` Juan Manuel Macías
2022-08-28 16:34 ` Cletip Cletip
2022-08-28 19:15 ` Daniel Fleischer
2022-08-29 11:41 ` Cletip Cletip
2022-08-29 11:58 ` Ihor Radchenko
2022-08-31 9:01 ` Cletip Cletip
2022-08-31 11:25 ` Cletip Cletip
2022-08-31 11:31 ` Cletip Cletip [this message]
2022-09-01 7:04 ` Ihor Radchenko
2022-09-02 12:47 ` Cletip Cletip
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAPHku6O2a_CeSai5EJo55aokKDgdzokFO-bp7AUPxYbFbgg4xQ@mail.gmail.com \
--to=clement020302@gmail.com \
--cc=danflscr@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=maciaschain@posteo.net \
--cc=yantar92@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).