sort-tasks

Sort tasks by dependencies and detect circular references.

Updated Jan 23, 2026
One-click install
npx skills add https://github.com/cooper538/eshop-demo --skill sort-tasks
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: sort-tasks
Source: https://github.com/cooper538/eshop-demo/tree/main/.claude/skills/sort-tasks
Command: npx skills add https://github.com/cooper538/eshop-demo --skill sort-tasks

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill sorts tasks by their dependencies to establish a safe and efficient execution order, reducing confusion and manual re-sequencing.

Core Features & Use Cases

  • Topological sorting: determines an execution order that respects all dependencies between tasks.
  • Circular dependency detection: identifies and reports cycles to prevent infinite loops.
  • Dependency validation: checks references to ensure all dependencies exist and are resolvable.
  • Output options: supports human-readable lists and programmatic outputs (JSON/Markdown).

Quick Start

Use the sort-tasks skill to arrange tasks in a phase folder and verify the resulting order.

  1. Run the default sort in the current phase /sort-tasks
  2. Sort a specific path /sort-tasks <path>
  3. Get JSON output /sort-tasks --json
  4. Get Markdown table output /sort-tasks --markdown

Frequently Asked Questions about sort-tasks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I sort tasks by dependencies to determine a safe execution order?

Topological sorting arranges tasks by dependencies to determine a safe execution order. It validates references, flags entry points with no dependencies, and outputs a sequence that prevents manual re-sequencing confusion.

Can I detect circular dependencies in my task workflow?

Yes, circular dependency detection identifies and reports cycles to prevent infinite loops. The tool validates references during the topological sort to ensure all dependencies exist and are resolvable before producing the ordered sequence.

How do I output sorted task lists as JSON or Markdown?

You can output sorted task lists as JSON or Markdown using command flags. Running the sort command with the JSON flag returns programmatic output, while the Markdown flag generates a human-readable table of the ordered task sequence.

What's the best way to validate missing task dependencies before execution?

Dependency validation checks references to ensure all dependencies exist and are resolvable. By applying a topological sort to your task metadata, it flags missing or unknown dependencies and identifies entry points that have no dependencies.

Does this topological sort tool work with specific project path folders?

Yes, the tool works with specific project path folders. You can run the default sort in the current phase or specify a custom path to read task metadata and apply the topological sort to that directory.