AgentSkillsCN

taskfile

当用户询问可用任务、项目流程,或想了解如何在本项目中完成某项操作时,可使用此功能——系统会读取 Taskfile.yml 文件,自动发现并执行相应任务。

SKILL.md
--- frontmatter
name: taskfile
description: Use when user asks about available tasks, project workflows, or how to do something in this project - reads Taskfile.yml to discover and execute tasks

Working with Taskfile Tasks

Overview

This project uses Taskfile for task automation. All available tasks are defined in Taskfile.yml at the project root.

When to use this skill:

  • User asks "what can I do?" or "how do I...?"
  • User wants to run a project task
  • You need to understand available workflows

Discovering Tasks

  1. Read Taskfile.yml to see all task definitions
  2. Each task has a desc: field explaining what it does
  3. Tasks are grouped by prefix for organization

Quick list: Run task --list to see all tasks with descriptions.

Running Tasks

Non-interactive tasks: Run directly with task <name>

bash
task format
task build
task test

Interactive tasks: Either run interactively OR pass variables:

bash
# Interactive (prompts for input)
task new

# Non-interactive (pass variable)
task new NAME=my-project

Handling Interactive Tasks

When user wants to run an interactive task:

  1. Check if they provided the required variable
  2. If not, ask for it conversationally
  3. Run with the variable set

Example conversation:

code
User: Create a new component
Agent: What should I name it? (e.g., MyComponent)
User: UserProfile
Agent: *runs: task new NAME=UserProfile*

Key Commands

  • task --list - Show all available tasks
  • task <task-name> - Run specific task
  • task --help - Get help on Taskfile usage

Integration with Other Skills

This skill often works with:

  • devenv: For environment-related tasks
  • git-workflow: For version control tasks
  • format: For code formatting tasks