Re: Add new word before an org-agenda entry (like "MODIFIED")

2023-10-14 Thread Ihor Radchenko
Cletip Cletip  writes:

> I know how to create a custom agenda block, but how insert this ? Can I
> just have some leads ?

No, I did not mean custom agenda block. I meant custom agenda block
_type_ (just like agenda, alltodo, tags, etc).

Implementing a new custom block type involves writing a lot of Elisp.
Basically, you will need to write a custom version of, for example,
`org-tags-view' function that will collect, insert, and format text into
agenda buffer. It is the most generic, lowest level customization of Org
agenda.

After you have such function, you can use it in
`org-agenda-custom-commands' as

("key" "Agenda name" my-custom-agenda-type-function "Argument passed to your 
function"
  ...)

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: Add new word before an org-agenda entry (like "MODIFIED")

2023-10-14 Thread Cletip Cletip
I know how to create a custom agenda block, but how insert this ? Can I
just have some leads ?

Le jeu. 12 oct. 2023 à 13:39, Ihor Radchenko  a écrit :

> Cletip Cletip  writes:
>
> > Here's an example for clarification:
> > Consider this line in org-agenda:
> >
> > 14:08-14:10 Clocked: (0:02) name-of-the-heading
> >
> > I want exactly the same thing, but not with the "Clocked" word !
>
> This is not easy. The supported log types are hard-coded in
> `org-agenda-get-progress'.
>
> You may need to implement a custom agenda block type to achieve what you
> want.
>
> --
> Ihor Radchenko // yantar92,
> Org mode contributor,
> Learn more about Org mode at .
> Support Org development at ,
> or support my work at 
>


Re: Add new word before an org-agenda entry (like "MODIFIED")

2023-10-12 Thread Ihor Radchenko
Cletip Cletip  writes:

> Here's an example for clarification:
> Consider this line in org-agenda:
>
> 14:08-14:10 Clocked: (0:02) name-of-the-heading
>
> I want exactly the same thing, but not with the "Clocked" word !

This is not easy. The supported log types are hard-coded in
`org-agenda-get-progress'.

You may need to implement a custom agenda block type to achieve what you
want.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Add new word before an org-agenda entry (like "MODIFIED")

2023-10-03 Thread Cletip Cletip
Hello, everyone! I have a question that may be complex to answer. I
apologize in advance for my limited vocabulary; I will use an example to
elucidate my question better.

Objective: I wish to track when a heading is modified using org-agenda. To
achieve this, I automatically insert an inactive timestamp in the LOGBOOK
drawer whenever a note is modified. However, how can I display the item in
org-agenda with the prefix "MODIFIED:" or another indicator before the
heading to show that I made a modification ?

Here's an example for clarification:
Consider this line in org-agenda:

14:08-14:10 Clocked: (0:02) name-of-the-heading

I want exactly the same thing, but not with the "Clocked" word !

Another example : I would like this entry/heading/item :

** An example
:PROPERTIES:
:CREATED: [2023-09-29 Fri 23:07]
:END:
:LOGBOOK:
MODIFIED: [2023-10-01 Sun 14:09]--[2023-10-01 Sun 14:35]
CLOCK: [2023-09-30 Sat 23:19]--[2023-09-30 Sat 23:25] => 0:06
MODIFIED: [2023-09-30 Sat 14:08]--[2023-09-30 Sat 14:20]
:END:

with the word "MODIFIED:" precede the entry in the org-agenda.

Is this feasible? Can you suggest alternative methods?

Thanks in advance for your futur answer :)