From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kaushal Modi Subject: Re: Make tag inheritance explicit Date: Tue, 23 Jan 2018 15:15:13 +0000 Message-ID: References: <2018-01-23T11-18-52@devnull.Karl-Voit.at> <2018-01-23T15-38-21@devnull.Karl-Voit.at> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="94eb2c19b446229cca056373046b" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:55080) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ee0IJ-00016P-IA for emacs-orgmode@gnu.org; Tue, 23 Jan 2018 10:15:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ee0II-0001lg-F3 for emacs-orgmode@gnu.org; Tue, 23 Jan 2018 10:15:27 -0500 Received: from mail-yb0-x243.google.com ([2607:f8b0:4002:c09::243]:35403) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ee0II-0001lB-3i for emacs-orgmode@gnu.org; Tue, 23 Jan 2018 10:15:26 -0500 Received: by mail-yb0-x243.google.com with SMTP id b18so302087ybn.2 for ; Tue, 23 Jan 2018 07:15:26 -0800 (PST) In-Reply-To: <2018-01-23T15-38-21@devnull.Karl-Voit.at> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Karl Voit Cc: emacs-orgmode@gnu.org --94eb2c19b446229cca056373046b Content-Type: text/plain; charset="UTF-8" On Tue, Jan 23, 2018 at 9:45 AM Karl Voit wrote: > > > 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. > > You mean for developing a custom-made function that provides the > feature I was asking for? > By "feature", you mean copying all the inherited tags to the heading at point? My suggestion implied that you can skip that copying step altogether and directly use org-get-tags-at to gets all the inherited tags for the current heading. That way, you wouldn't need to add redundant information to your Org file. > Yes, this helps a lot to me. > Great! :) First, I wanted to get a confirmation that this feature is not > already part of Org-mode because (as usual) this seemed obvious to > me when using export functionality ;-) > It's not clear what you mean by "feature is not already part of Org-mode". Org mode provides `org-get-tags-at', which any Org exporter can use. How that function is used is, I think, very subjective. The way I use it in ox-hugo is probably not used in other exporters. -- Kaushal Modi --94eb2c19b446229cca056373046b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Tue, Jan 23= , 2018 at 9:45 AM Karl Voit <dev= null@karl-voit.at> wrote:
> 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 headin= g.
> `org-get-tags-at' returns inherited tags too.

You mean for developing a custom-made function that provides the
feature I was asking for?

By "feat= ure", you mean copying all the inherited tags to the heading at point?=

My suggestion implied that you can skip that copy= ing step altogether and directly use org-get-tags-at to gets all the inheri= ted tags for the current heading. That way, you wouldn't need to add re= dundant information to your Org file.
=C2=A0
Yes, this helps a lot to me.

Great! :)<= /div>

First, I wanted to get a confirmation that this feature is not
already part of Org-mode because (as usual) this seemed obvious to
me when using export functionality ;-)

= It's not clear what you mean by "feature is not already part of Or= g-mode". Org mode provides `org-get-tags-at', which any Org export= er can use. How that function is used is, I think, very subjective. The way= I use it in ox-hugo is probably not used in other exporters.


--

Kaushal Modi

--94eb2c19b446229cca056373046b--