-
Notifications
You must be signed in to change notification settings - Fork 6
Description
This great-big feature request seeks to answer the question
"where should I find the wikified version of this task?".
It rests on a number of suppositions
- users of this plugin have a $TASKDATA environment variable, usually ~/.task.
- it is desirable to keep task data together, for ease of use and portability.
- wiki-tasks is different enough from vimwiki, that it should not use ~/vimwiki/ by default.
- a real-world project may need it's own files directory and/or it's own sub-wiki.
- a (sub)project can have it's own folder (../foo/index.wiki) or wiki (../foo.wiki) but not both
- wikified tasks could be in any wiki, and in multiples, no problem, but
- a known or anticipated location for each task within a wiki would be preferable.
So considering all of that, it's still not immediately obvious where a specific task should be found within an automatically-generated wiki hierarchy, but it's possible.
Let me start with the $TASKDATA/index.wiki and $TASKDATA/project/index.wiki and work from there. Like the subject-line says, this is a "project-centric" idea, and presumes a hierarchy that follows a tree of projects and subprojects. A project or sub-project will only get it's own folder or wiki if the user creates it, but if it does exist, we can follow a convention, and work down the tree logically, from the highest branches to the trunk.
As a more complex example, let's locate the proper wiki entry/ file for the following task;
task add proj:tw.web.ui choose initial color scheme
Where should this go?
We'll start from the most granular possibility, and work towards the simplest;
(the first one that exists is the correct place for this task)
- if exists $TASKDATA/project/tw/web/ui/index.wiki
then the ui sub-sub-project has it's own folder
- if exists $TASKDATA/project/tw/web/ui.wiki
then the ui sub-sub-project has it's own wiki
- if exists $TASKDATA/project/tw/web/index.wiki
then the web sub-project has a folder, look under heading == ui ==
- if exists $TASKDATA/project/tw/web.wiki
then the subproject has a wiki, look under heading == ui ==
- if exists $TASKDATA/project/tw/index.wiki
then the project has a folder, look under == web, === ui sub heading
*if exists $TASKDATA/project/tw.wiki
the project has a wiki, look under == web, === ui sub heading
- if exists $TASKDATA/project/index.wiki (and it will exist, or be created)
the project has no folder or wikis, look under == tw, === web, ==== ui heading.
Without any sub-folders or sub-wikis, all tasks with projects will be listed under project-driven headeings and sub-headings in $TASKDATA/project/index.wiki.
Tasks with no project are all listed in $TASKDATA/index.wiki (the root of the taskwiki tree)
This scheme allows for things to start small, and if a project or sub-project needs to add a folder full of related files, or it's own sub-wiki, then related tasks can be automatically moved to the right place, inter-wiki links are automagically (re)generated.
thanks for reading through all of this, I hope at least some of it makes sense :)