Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions cmd/gh-aw/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,7 @@ Use "` + string(constants.CLIExtensionPrefix) + ` help all" to show help for all
upgradeCmd := cli.NewUpgradeCommand()
completionCmd := cli.NewCompletionCommand()
hashCmd := cli.NewHashCommand()
projectCmd := cli.NewProjectCommand()

// Assign commands to groups
// Setup Commands
Expand Down Expand Up @@ -594,6 +595,7 @@ Use "` + string(constants.CLIExtensionPrefix) + ` help all" to show help for all
prCmd.GroupID = "utilities"
completionCmd.GroupID = "utilities"
hashCmd.GroupID = "utilities"
projectCmd.GroupID = "utilities"

// version command is intentionally left without a group (common practice)

Expand Down Expand Up @@ -622,6 +624,7 @@ Use "` + string(constants.CLIExtensionPrefix) + ` help all" to show help for all
rootCmd.AddCommand(fixCmd)
rootCmd.AddCommand(completionCmd)
rootCmd.AddCommand(hashCmd)
rootCmd.AddCommand(projectCmd)
}

func main() {
Expand Down
8 changes: 6 additions & 2 deletions docs/src/content/docs/reference/tokens.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ For GitHub Agentic Workflows, you only need to create a few **optional** secrets
| Copilot workflows (CLI, engine, agent sessions, etc.) | `COPILOT_GITHUB_TOKEN` | Needs Copilot Requests permission. For org-owned repos, needs org permissions: Members (read-only), GitHub Copilot Business (read-only). |
| Cross-repo Project Ops / remote GitHub tools | `GH_AW_GITHUB_TOKEN` | PAT or app token with cross-repo access. |
| Assigning agents/bots to issues or pull requests | `GH_AW_AGENT_TOKEN` | Used by `assign-to-agent` and Copilot assignee/reviewer flows. |
| Any GitHub Projects v2 operations | `GH_AW_PROJECT_GITHUB_TOKEN` | **Required** for `update-project`. Default `GITHUB_TOKEN` cannot access Projects v2 API. |
| Any GitHub Projects v2 operations | `GH_AW_PROJECT_GITHUB_TOKEN` | **Required** for `project new` CLI command, `create-project`, and `update-project`. Default `GITHUB_TOKEN` cannot access Projects v2 API. |
| Isolating Model Context Protocol (MCP) server permissions (advanced optional) | `GH_AW_GITHUB_MCP_SERVER_TOKEN` | Only if you want MCP to use a different token than other jobs. |

> [!TIP]
Expand Down Expand Up @@ -160,7 +160,11 @@ The compiler automatically sets `GITHUB_MCP_SERVER_TOKEN` and passes it as `GITH

**Type**: Personal Access Token (required for Projects v2 operations)

A specialized token for GitHub Projects v2 operations used by the [`update-project`](/gh-aw/reference/safe-outputs/#project-board-updates-update-project) safe output. **Required** because the default `GITHUB_TOKEN` cannot access the GitHub Projects v2 GraphQL API.
A specialized token for GitHub Projects v2 operations used by:
- The [`project new`](/gh-aw/setup/cli/#project-new) CLI command for creating projects
- The [`update-project`](/gh-aw/reference/safe-outputs/#project-board-updates-update-project) safe output for updating projects

**Required** because the default `GITHUB_TOKEN` cannot access the GitHub Projects v2 GraphQL API.

**When to use**:

Expand Down
30 changes: 30 additions & 0 deletions docs/src/content/docs/setup/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,36 @@ gh aw completion powershell # Generate powershell script

See [Shell Completions](#shell-completions) for detailed installation instructions.

#### `project`

Create and manage GitHub Projects V2 boards. Use this to create project boards for tracking issues, pull requests, and tasks.

##### `project new`

Create a new GitHub Project V2 owned by a user or organization. Optionally link the project to a specific repository.

```bash wrap
gh aw project new "My Project" --owner @me # Create user project
gh aw project new "Team Board" --owner myorg # Create org project
gh aw project new "Bugs" --owner myorg --link myorg/myrepo # Create and link to repo
```

**Options:**
- `--owner` (required): Project owner - use `@me` for current user or specify organization name
- `--link`: Repository to link project to (format: `owner/repo`)

**Token Requirements:**

> [!IMPORTANT]
> The default `GITHUB_TOKEN` cannot create projects. You must use a Personal Access Token (PAT) with Projects permissions:
>
> - **Classic PAT**: `project` scope (user projects) or `project` + `repo` (org projects)
> - **Fine-grained PAT**: Organization permissions → Projects: Read & Write
>
> Configure via `GH_AW_PROJECT_GITHUB_TOKEN` environment variable or use `gh auth login` with a suitable token.

**Related:** See [Tokens Reference](/gh-aw/reference/tokens/) for complete token configuration guide.

## Shell Completions

Enable tab completion for workflow names, engines, and paths.
Expand Down
Loading
Loading