GitHub CLI Agent Task Extension
The gh agent-task CLI extension enables creating GitHub Copilot coding agent tasks through the command line. An agent task is a specialized GitHub issue that triggers GitHub Copilot to perform automated code changes based on natural language instructions.
Repository: https://github.com/github/agent-task (internal GitHub extension)
Agent tasks are GitHub issues that:
Install via GitHub CLI:
gh extension install github/agent-task
Note: This extension requires authentication with a Personal Access Token (PAT) that has appropriate permissions for creating issues and pull requests.
Create a new agent task from a description:
# Create task with inline description
gh agent-task create "Fix the bug in authentication flow"
# Create task from file
gh agent-task create --from-file task-description.md
# Specify base branch
gh agent-task create --base develop "Implement new feature"
# Create in different repository
gh agent-task create --repo owner/repo "Update documentation"
Command Parameters:
--from-file <path>: Read task description from file--base <branch>: Base branch for the pull request (default: repository default branch)--repo <owner/repo>: Target repository (default: current repository)Output Format: The command outputs the URL of the created agent task: