en un clic
agkan-run-direct
Use when starting a development session to pick the highest priority Todo task from agkan, implement it directly without PR/branch, and mark it done.
Menu
Use when starting a development session to pick the highest priority Todo task from agkan, implement it directly without PR/branch, and mark it done.
Use when managing tasks with the agkan CLI tool - creating, listing, updating tasks, managing tags, blocking relationships, or tracking project progress with the kanban board.
Use when reviewing backlog tasks to assess decomposition, implementation readiness, and priority ordering before development begins.
Use when starting a development session to pick the highest priority Todo task from agkan, implement it, create a pull request, and mark it done.
Use when a task has been selected and you need to implement it directly without PR/branch creation - handles in_progress update, implementation, and marking done.
Use when a task has been selected and you need to implement it in an isolated (forked) context - handles in_progress update, branch creation, implementation, PR creation, and marking review.
Use when checking review tasks against GitHub PR status to automatically move them to done or closed.
| name | agkan-run-direct |
| description | Use when starting a development session to pick the highest priority Todo task from agkan, implement it directly without PR/branch, and mark it done. |
A workflow to select the highest priority ready task from agkan, implement it directly without creating a branch or PR, and mark it as done.
Retrieve the agkan configuration and extract model/effort settings for the sub-agent:
CONFIG=$(agkan config get --json 2>/dev/null || echo '{}')
RUN_MODEL=$(echo "$CONFIG" | jq -r '.config.models.run.model // "sonnet"')
RUN_EFFORT=$(echo "$CONFIG" | jq -r '.config.models.run.effort // "medium"')
These values are passed to the sub-agent in Step 6.
This skill is designed to commit directly to the current branch (default branch or topic branch).
Therefore, only execute git pull -p (unlike agkan-run, there is no need to create a new branch from the default branch).
# Get the default branch name dynamically
DEFAULT_BRANCH=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@') && \
[ -z "$DEFAULT_BRANCH" ] && DEFAULT_BRANCH=$(gh repo view --json defaultBranchRef -q '.defaultBranchRef.name' 2>/dev/null)
# Then pull
git pull -p
agkan task list --status ready --json
Evaluate tasks using the following criteria in descending order and select the top one:
Skip tasks with will-do-later tag:
Tasks with the will-do-later tag are intentionally deferred tasks. Skip them unless they are in ready status — a task promoted to ready is executable regardless of the tag.
Priority (read from metadata field in the list JSON response):
Critical > High > Medium > Low
Tags (used when priority is the same):
bug > security > improvement > test > performance > refactor > docs
When there are subtasks or blocker tasks Prioritize the target subtasks or blocker tasks (using the same importance and tag criteria)
agkan task block list <id> --json
If incomplete tasks exist in blockedBy, do not select that task; instead, select a different task or process the blocker tasks first.
agkan task update <id> status in_progress
Use the Task tool (general-purpose sub-agent) to implement.
Task(
subagent_type="general-purpose",
model="<RUN_MODEL>",
description="Implement task #<id>",
prompt="""
Please implement the following task.
Invoke the key-guidelines skill using the Skill tool: Skill("key-guidelines")
## Task Information
- ID: <id>
- Title: <title>
- Body: <body>
## Procedure
Invoke the agkan-subtask-direct skill using the Skill tool: Skill("agkan-subtask-direct")
## Error Handling
If a critical error occurs during implementation (git push failure, commit failure,
permission denied, etc.), do NOT update the task status to done. Leave the task as
`in_progress` and record the error in the task body:
```bash
agkan task get <id> --json
agkan task update <id> body "<existing body>\n\nError: <error description>"
Only update to done if implementation and all commits/pushes succeeded.
Thoroughness level for this session: <RUN_EFFORT>
### 7. Verify Task Status After Sub-Agent Completes
After the sub-agent completes, check whether the task has been moved out of `in_progress`:
```bash
agkan task get <id> --json
Scope note: The interruption guard below applies only to this status transition decision — not to the sub-agent's implementation steps. If the sub-agent was interrupted during implementation and the interruption has since been resolved, ensure the sub-agent completes its implementation steps (commit, push) before evaluating the guard below.
If the status is still in_progress, determine whether the sub-agent encountered a critical error (git push failure, commit failure, permission error). Check the task body for any recorded error messages.
done. Leave the task as in_progress so the issue can be resolved manually.done. Leave the task as in_progress.done. Leave the task as in_progress.git commit was made and pushed) but the sub-agent forgot to update the status, verify with git log --oneline -1 and update manually only if a commit exists:# Verify a commit was actually made before marking done
git log --oneline -1
# Only if a commit is confirmed:
agkan task update <id> status done
The following do NOT qualify as implementation success:
agkan task comment add (comment additions only)agkan task update --body / --file (body/metadata updates only)After the sub-agent completes, re-fetch the task list to pick up any newly added ready tasks:
agkan task list --status ready --json
If there is no instruction to end from the user and ready tasks exist (including newly added ones), select the next task and repeat from step 3 of the same workflow.
If no ready tasks remain, end the session.
Ready task list
↓
Sort by priority (Critical → High → Medium → Low)
↓
Multiple tasks with same priority?
Yes → Sort by tag priority (bug → security → ... → docs)
No → Select the top task
↓
Select one task and start
See the canonical definition in agkan/SKILL.md (Tag Priority section).