emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-agenda todos list sorted by earliest deadline first
@ 2022-04-02 16:24 Sébastien Gendre
  2022-04-02 21:16 ` Samuel Wales
  0 siblings, 1 reply; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-02 16:24 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 267 bytes --]

Hello.

In org-agenda, for the todos list, I try to have tasks with deadlines at top. With earliest deadline first.

But, when I customize the variable "org-agenda-sorting-strategy" by adding "deadline-up" for "todo" and "tags", it has no effect. 

Any advice ?

[-- Attachment #2: Type: text/html, Size: 320 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-02 16:24 org-agenda todos list sorted by earliest deadline first Sébastien Gendre
@ 2022-04-02 21:16 ` Samuel Wales
  2022-04-02 23:02   ` Sébastien Gendre
  0 siblings, 1 reply; 12+ messages in thread
From: Samuel Wales @ 2022-04-02 21:16 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: emacs-orgmode

perhaps try including your code and the emacs and org versins.  i
think there have been recentish changes insorting strategy.

might also try paradoxically deadline-down etc.

On 4/2/22, Sébastien Gendre <seb@k-7.ch> wrote:
> Hello.
>
> In org-agenda, for the todos list, I try to have tasks with deadlines at
> top. With earliest deadline first.
>
> But, when I customize the variable "org-agenda-sorting-strategy" by adding
> "deadline-up" for "todo" and "tags", it has no effect.
>
> Any advice ?


-- 
The Kafka Pandemic

A blog about science, health, human rights, and misopathy:
https://thekafkapandemic.blogspot.com


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-02 21:16 ` Samuel Wales
@ 2022-04-02 23:02   ` Sébastien Gendre
  2022-04-04 11:42     ` Ihor Radchenko
  0 siblings, 1 reply; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-02 23:02 UTC (permalink / raw)
  To: Samuel Wales; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1033 bytes --]

My Emacs version is 27.2 and Org is 9.4.4.

The value of "org-agenda-sorting-strategy" is:

((agenda habit-down time-up priority-down category-keep)
 (todo priority-down category-keep deadline-up)
 (tags priority-down category-keep deadline-up)
 (search category-keep))

Le 2 avril 2022 23:16:23 GMT+02:00, Samuel Wales <samologist@gmail.com> a écrit :
>perhaps try including your code and the emacs and org versins.  i
>think there have been recentish changes insorting strategy.
>
>might also try paradoxically deadline-down etc.
>
>On 4/2/22, Sébastien Gendre <seb@k-7.ch> wrote:
>> Hello.
>>
>> In org-agenda, for the todos list, I try to have tasks with deadlines at
>> top. With earliest deadline first.
>>
>> But, when I customize the variable "org-agenda-sorting-strategy" by adding
>> "deadline-up" for "todo" and "tags", it has no effect.
>>
>> Any advice ?
>
>
>-- 
>The Kafka Pandemic
>
>A blog about science, health, human rights, and misopathy:
>https://thekafkapandemic.blogspot.com

[-- Attachment #2: Type: text/html, Size: 1544 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-02 23:02   ` Sébastien Gendre
@ 2022-04-04 11:42     ` Ihor Radchenko
  2022-04-04 16:02       ` Sébastien Gendre
  2022-04-04 16:07       ` Sébastien Gendre
  0 siblings, 2 replies; 12+ messages in thread
From: Ihor Radchenko @ 2022-04-04 11:42 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: emacs-orgmode

Sébastien Gendre <seb@k-7.ch> writes:

> My Emacs version is 27.2 and Org is 9.4.4.
>
> The value of "org-agenda-sorting-strategy" is:
>
> ((agenda habit-down time-up priority-down category-keep)
>  (todo priority-down category-keep deadline-up)
>  (tags priority-down category-keep deadline-up)
>  (search category-keep))

Try to move deadline-up to beginning of the lists:

((agenda habit-down time-up priority-down category-keep)
 (todo deadline-up priority-down category-keep)
 (tags deadline-up priority-down category-keep)
 (search category-keep))

Best,
Ihor


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-04 11:42     ` Ihor Radchenko
@ 2022-04-04 16:02       ` Sébastien Gendre
  2022-04-04 16:07       ` Sébastien Gendre
  1 sibling, 0 replies; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-04 16:02 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 766 bytes --]

I've done it, but tasks with no deadlines are still on top of the list

Le 4 avril 2022 13:42:26 GMT+02:00, Ihor Radchenko <yantar92@gmail.com> a écrit :
>Sébastien Gendre <seb@k-7.ch> writes:
>
>> My Emacs version is 27.2 and Org is 9.4.4.
>>
>> The value of "org-agenda-sorting-strategy" is:
>>
>> ((agenda habit-down time-up priority-down category-keep)
>>  (todo priority-down category-keep deadline-up)
>>  (tags priority-down category-keep deadline-up)
>>  (search category-keep))
>
>Try to move deadline-up to beginning of the lists:
>
>((agenda habit-down time-up priority-down category-keep)
> (todo deadline-up priority-down category-keep)
> (tags deadline-up priority-down category-keep)
> (search category-keep))
>
>Best,
>Ihor

[-- Attachment #2: Type: text/html, Size: 1174 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-04 11:42     ` Ihor Radchenko
  2022-04-04 16:02       ` Sébastien Gendre
@ 2022-04-04 16:07       ` Sébastien Gendre
  2022-04-05  5:44         ` Ihor Radchenko
  1 sibling, 1 reply; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-04 16:07 UTC (permalink / raw)
  To: Ihor Radchenko; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 773 bytes --]

I've tested it, but the tasks with no deadlines are still on top of the list.

Le 4 avril 2022 13:42:26 GMT+02:00, Ihor Radchenko <yantar92@gmail.com> a écrit :
>Sébastien Gendre <seb@k-7.ch> writes:
>
>> My Emacs version is 27.2 and Org is 9.4.4.
>>
>> The value of "org-agenda-sorting-strategy" is:
>>
>> ((agenda habit-down time-up priority-down category-keep)
>>  (todo priority-down category-keep deadline-up)
>>  (tags priority-down category-keep deadline-up)
>>  (search category-keep))
>
>Try to move deadline-up to beginning of the lists:
>
>((agenda habit-down time-up priority-down category-keep)
> (todo deadline-up priority-down category-keep)
> (tags deadline-up priority-down category-keep)
> (search category-keep))
>
>Best,
>Ihor

[-- Attachment #2: Type: text/html, Size: 1181 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-04 16:07       ` Sébastien Gendre
@ 2022-04-05  5:44         ` Ihor Radchenko
  2022-04-05  6:47           ` Sébastien Gendre
  0 siblings, 1 reply; 12+ messages in thread
From: Ihor Radchenko @ 2022-04-05  5:44 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: emacs-orgmode

Sébastien Gendre <seb@k-7.ch> writes:

> I've tested it, but the tasks with no deadlines are still on top of the list.

I am unable to reproduce on my side using latest stable Org.
I used the following example org file:

----
* TODO test1
* TODO test2
* TODO test3
DEADLINE: <2022-04-04 Mon>
* TODO test4
DEADLINE: <2022-04-06 Wed>
------

(setq org-agenda-sorting-strategy '((agenda deadline-down time-up habit-up priority-down timestamp-down category-keep)
				    (todo deadline-up priority-down category-keep)
				    (tags priority-down category-keep)
				    (search category-keep)))

The todo agenda buffer looks like:

Global list of TODO items of type: ALL
Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[ALL] (1)TODO (2)DONE
  bug:        TODO test3
  bug:        TODO test4
  bug:        TODO test1
  bug:        TODO test2


Best,
Ihor


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-05  5:44         ` Ihor Radchenko
@ 2022-04-05  6:47           ` Sébastien Gendre
  2022-04-05  7:14             ` Ihor Radchenko
  0 siblings, 1 reply; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-05  6:47 UTC (permalink / raw)
  To: Ihor Radchenko; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]

If I evaluate the same setq and define the same tasks, my result withe org-agenda tasks list are:

Global list of TODO items of type: ALL
Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[A$
                      (1)TODO (2)DONE
  test:       TODO test1
  test:       TODO test2
  test:       TODO test3
  test:       TODO test4

I tested at this moment with Org version 9.5.2 on Emacs version 27.2

Le 5 avril 2022 07:44:25 GMT+02:00, Ihor Radchenko <yantar92@gmail.com> a écrit :
>Sébastien Gendre <seb@k-7.ch> writes:
>
>> I've tested it, but the tasks with no deadlines are still on top of the list.
>
>I am unable to reproduce on my side using latest stable Org.
>I used the following example org file:
>
>----
>* TODO test1
>* TODO test2
>* TODO test3
>DEADLINE: <2022-04-04 Mon>
>* TODO test4
>DEADLINE: <2022-04-06 Wed>
>------
>
>(setq org-agenda-sorting-strategy '((agenda deadline-down time-up habit-up priority-down timestamp-down category-keep)
>				    (todo deadline-up priority-down category-keep)
>				    (tags priority-down category-keep)
>				    (search category-keep)))
>
>The todo agenda buffer looks like:
>
>Global list of TODO items of type: ALL
>Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[ALL] (1)TODO (2)DONE
>  bug:        TODO test3
>  bug:        TODO test4
>  bug:        TODO test1
>  bug:        TODO test2
>
>
>Best,
>Ihor

[-- Attachment #2: Type: text/html, Size: 1855 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-05  6:47           ` Sébastien Gendre
@ 2022-04-05  7:14             ` Ihor Radchenko
  2022-04-05  7:20               ` Sébastien Gendre
  2022-05-10 23:00               ` Sébastien Gendre
  0 siblings, 2 replies; 12+ messages in thread
From: Ihor Radchenko @ 2022-04-05  7:14 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: emacs-orgmode

Sébastien Gendre <seb@k-7.ch> writes:

> If I evaluate the same setq and define the same tasks, my result withe org-agenda tasks list are:
>
> Global list of TODO items of type: ALL
> Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[A$
>                       (1)TODO (2)DONE
>   test:       TODO test1
>   test:       TODO test2
>   test:       TODO test3
>   test:       TODO test4
>
> I tested at this moment with Org version 9.5.2 on Emacs version 27.2

I am unable to reproduce using Emacs 27.2 + latest Org main or bugfix.
Can you try to reproduce starting from emacs -Q?
See https://orgmode.org/manual/Feedback.html or
https://open.tube/videos/watch/4d819114-43bf-42df-af94-f94fc53dd0d9 for
detailed instructions.

Best,
Ihor


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-05  7:14             ` Ihor Radchenko
@ 2022-04-05  7:20               ` Sébastien Gendre
  2022-05-10 23:00               ` Sébastien Gendre
  1 sibling, 0 replies; 12+ messages in thread
From: Sébastien Gendre @ 2022-04-05  7:20 UTC (permalink / raw)
  To: Ihor Radchenko; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 922 bytes --]

Tested with "emacs -q", I got the same result.



Le 5 avril 2022 09:14:43 GMT+02:00, Ihor Radchenko <yantar92@gmail.com> a écrit :
>Sébastien Gendre <seb@k-7.ch> writes:
>
>> If I evaluate the same setq and define the same tasks, my result withe org-agenda tasks list are:
>>
>> Global list of TODO items of type: ALL
>> Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[A$
>>                       (1)TODO (2)DONE
>>   test:       TODO test1
>>   test:       TODO test2
>>   test:       TODO test3
>>   test:       TODO test4
>>
>> I tested at this moment with Org version 9.5.2 on Emacs version 27.2
>
>I am unable to reproduce using Emacs 27.2 + latest Org main or bugfix.
>Can you try to reproduce starting from emacs -Q?
>See https://orgmode.org/manual/Feedback.html or
>https://open.tube/videos/watch/4d819114-43bf-42df-af94-f94fc53dd0d9 for
>detailed instructions.
>
>Best,
>Ihor

[-- Attachment #2: Type: text/html, Size: 1470 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-04-05  7:14             ` Ihor Radchenko
  2022-04-05  7:20               ` Sébastien Gendre
@ 2022-05-10 23:00               ` Sébastien Gendre
  2022-05-11 13:24                 ` Ihor Radchenko
  1 sibling, 1 reply; 12+ messages in thread
From: Sébastien Gendre @ 2022-05-10 23:00 UTC (permalink / raw)
  To: Ihor Radchenko; +Cc: emacs-orgmode


So, I updated to Org-mode 9.5.3 from ELPA and the problem is gone.

Now, I get the tasks in the agenda in the correct order: Earliest
deadlines firsts, on top of the tasks list, then the tasks without
deadlines.

The only option I have to set is:
```
(setq org-agenda-sorting-strategy '((agenda deadline-down time-up habit-up priority-down timestamp-down category-keep)
				    (todo deadline-up priority-down category-keep)
				    (tags priority-down category-keep)
				    (search category-keep)))
```

Do the `deadline-up` option will apply to all todo lists in the agenda ?
Even the ones in custom views ?





Ihor Radchenko <yantar92@gmail.com> writes:

> Sébastien Gendre <seb@k-7.ch> writes:
>
>> If I evaluate the same setq and define the same tasks, my result withe org-agenda tasks list are:
>>
>> Global list of TODO items of type: ALL
>> Press ‘N r’ (e.g. ‘0 r’) to search again: (0)[A$
>>                       (1)TODO (2)DONE
>>   test:       TODO test1
>>   test:       TODO test2
>>   test:       TODO test3
>>   test:       TODO test4
>>
>> I tested at this moment with Org version 9.5.2 on Emacs version 27.2
>
> I am unable to reproduce using Emacs 27.2 + latest Org main or bugfix.
> Can you try to reproduce starting from emacs -Q?
> See https://orgmode.org/manual/Feedback.html or
> https://open.tube/videos/watch/4d819114-43bf-42df-af94-f94fc53dd0d9 for
> detailed instructions.
>
> Best,
> Ihor



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: org-agenda todos list sorted by earliest deadline first
  2022-05-10 23:00               ` Sébastien Gendre
@ 2022-05-11 13:24                 ` Ihor Radchenko
  0 siblings, 0 replies; 12+ messages in thread
From: Ihor Radchenko @ 2022-05-11 13:24 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: emacs-orgmode

Sébastien Gendre <seb@k-7.ch> writes:

> The only option I have to set is:
> ```
> (setq org-agenda-sorting-strategy '((agenda deadline-down time-up habit-up priority-down timestamp-down category-keep)
> 				    (todo deadline-up priority-down category-keep)
> 				    (tags priority-down category-keep)
> 				    (search category-keep)))
> ```
>
> Do the `deadline-up` option will apply to all todo lists in the agenda ?
> Even the ones in custom views ?

Yes. (setq org-agenda-sorting-strategy ...) is global setting.
However, you can also set it locally inside custom agenda command if you
wish. See the docstring of org-agenda-custom-commands:

>> settings  A list of option settings, similar to that in a let form, so like
>>          this: ((opt1 val1) (opt2 val2) ...).   The values will be
>>          evaluated at the moment of execution, so quote them when needed.

optN can be org-agenda-sort-strategy.

Best,
Ihor


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-05-11 13:24 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-04-02 16:24 org-agenda todos list sorted by earliest deadline first Sébastien Gendre
2022-04-02 21:16 ` Samuel Wales
2022-04-02 23:02   ` Sébastien Gendre
2022-04-04 11:42     ` Ihor Radchenko
2022-04-04 16:02       ` Sébastien Gendre
2022-04-04 16:07       ` Sébastien Gendre
2022-04-05  5:44         ` Ihor Radchenko
2022-04-05  6:47           ` Sébastien Gendre
2022-04-05  7:14             ` Ihor Radchenko
2022-04-05  7:20               ` Sébastien Gendre
2022-05-10 23:00               ` Sébastien Gendre
2022-05-11 13:24                 ` Ihor Radchenko

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