Consolidate task location: always .automaton/tasks/
Both framework and project tasks now live in .automaton/tasks/.
Every project has a .automaton/ directory, so no need for special
scope-based path logic. Removed the dual-convention gap.
Changes:
- Dashboard _find_tasks_dir() and _get_review_path() always use
{root}/.automaton/tasks/ — no scope branching
- migrate-project.sh: moves tasks/ -> .automaton/tasks/ during upgrade
- Orchestrator prompt: all task path references updated to
{project}/.automaton/tasks/
This commit is contained in:
+12
-10
@@ -107,16 +107,18 @@ while IFS= read -r -d '' project_file; do
|
||||
fi
|
||||
done < <(find "$PROJECT_AUTOMATON" -maxdepth 1 -type f -name "*.md" -o -name "*.sh" -print0 2>/dev/null || true)
|
||||
|
||||
# Task directory — old model stored tasks in .automaton/tasks/, new model uses tasks/
|
||||
OLD_TASKS="$PROJECT_AUTOMATON/tasks"
|
||||
NEW_TASKS="$PROJECT_DIR/tasks"
|
||||
if [ -d "$OLD_TASKS" ] && [ ! -e "$NEW_TASKS" ]; then
|
||||
echo " MOVING .automaton/tasks/ → tasks/ (tasks should be at project root)"
|
||||
mv "$OLD_TASKS" "$NEW_TASKS"
|
||||
MOVED+=(".automaton/tasks/ -> tasks/")
|
||||
elif [ -d "$OLD_TASKS" ] && [ -d "$NEW_TASKS" ]; then
|
||||
echo " NOTICE Both .automaton/tasks/ and tasks/ exist — keeping both"
|
||||
KEPT+=(".automaton/tasks/ and tasks/")
|
||||
# Task directory — tasks always live in .automaton/tasks/ for all modes
|
||||
ROOT_TASKS="$PROJECT_DIR/tasks"
|
||||
AUTOMATON_TASKS="$PROJECT_AUTOMATON/tasks"
|
||||
if [ -d "$ROOT_TASKS" ] && [ ! -e "$AUTOMATON_TASKS" ]; then
|
||||
echo " MOVING tasks/ → .automaton/tasks/ (tasks belong in .automaton/)"
|
||||
mv "$ROOT_TASKS" "$AUTOMATON_TASKS"
|
||||
MOVED+=("tasks/ -> .automaton/tasks/")
|
||||
elif [ -d "$ROOT_TASKS" ] && [ -d "$AUTOMATON_TASKS" ]; then
|
||||
echo " MERGING tasks/ contents into .automaton/tasks/"
|
||||
cp -r "$ROOT_TASKS"/* "$AUTOMATON_TASKS/" 2>/dev/null || true
|
||||
rm -rf "$ROOT_TASKS"
|
||||
MOVED+=("tasks/ merged -> .automaton/tasks/")
|
||||
fi
|
||||
|
||||
# Report
|
||||
|
||||
Reference in New Issue
Block a user