Support for Sort Random and Limit #330
Replies: 5 comments 8 replies
-
Sorting randomly probably wouldn't work the way you want. With a naive implementation, the randomly selected task would change every time you edit, create, or delete any task anywhere in your vault. I am not sure whether that helps. On the other hand, implementing it so that the randomly chosen tasks is "fixed" is probably too much effort, sorry. A limit is already possible, please check the readme. |
Beta Was this translation helpful? Give feedback.
-
One workaround for a single random task is with the Dice Roller plugin. Random task: |
Beta Was this translation helpful? Give feedback.
-
Just to set expectations, if this were implemented in Tasks, every time an edit was made to any line that affected the data stored for a task, all displayed tasks lists with I would think it might be quite disorienting, but assume that this is what is being requested. |
Beta Was this translation helpful? Give feedback.
-
@claremacrae I'd also like to see support for a random task sort. I have a list of 'aspirational' tasks appended at the end of my real tasks. This way, when I finish my daily tasks and want to continue, I can work on an 'aspirational' task. Currently, with the limit set to 1, the same task is always chosen (unless already completed). While I agree that a random task change on every edit could be disorienting, I propose implementing it by using the current date as a seed. The plugin would run it through a deterministic one-way function, generating a random but consistent sort order for that day. This way, edits would maintain a consistent order for the day, but opening the task list the next day would yield a different sort order due to the changed date/seed. Additionally, I suggest making the seed optionally configurable. This way, users can derive the sort order not just from the date, but also from date+hour and date+hour+minute if they wanted the sort order changed more often. I'm not much of a JavaScript programmer, so I'm sorry if this is nonsense, but unless I'm mistaken, something like this could be implemented using node.js' crypto library, maybe with the createHash function? |
Beta Was this translation helpful? Give feedback.
-
Tasks have priority, but sometimes these tasks have a very similar priority and impact on a project. With many tasks, it can feel daunting to figure out which one to focus on. I usually just either choose the top or bottom, but then the tasks in the center don't see any work until much later.
Having support for Random Sort can make sure all tasks are completed evenly, freshen the mindset, and bring some fun. A limit might also help to for mitigating decision paralysis.
Beta Was this translation helpful? Give feedback.
All reactions