mirror of
https://github.com/schpet/linear-cli.git
synced 2026-09-14 14:26:50 +08:00
77aa22b9d9
## Summary Adds comprehensive milestone management functionality to linear-cli, enabling full CRUD operations for Linear project milestones. ## Motivation The Linear API supports project milestones, but the CLI didn't expose this functionality. This PR adds milestone management commands to complement the existing project and issue commands. ## Changes ### New Commands - `linear milestone list --project <id>` - List milestones for a project - `linear milestone create` - Create new project milestones - `linear milestone update <id>` - Update existing milestones - `linear milestone delete <id>` - Delete milestones with confirmation - Short alias: `linear m` for all milestone commands ### Features - Full CRUD operations for project milestones - Table-formatted output for list command - Interactive confirmation prompts for deletion (with `--force` option to skip) - Support for milestone name, description, and target date - Follows existing CLI patterns and conventions ### Implementation - Uses GraphQL Code Generator for type-safe queries/mutations - Built with Cliffy for command structure and prompts - Leverages existing graphql client utilities - Includes spinner for loading states - Updated README with usage examples ## Testing All commands have been tested with the Linear API: - ✅ List milestones for a project (empty and populated) - ✅ Create milestones with name, description, target date - ✅ Update milestone properties - ✅ Delete milestones with confirmation prompt - ✅ Delete with `--force` flag (skip confirmation) ## Documentation Updated README.md with: - Milestone commands section - Usage examples for all operations - Command aliases ## Example Usage ```bash # List milestones linear milestone list --project abc123 linear m list --project abc123 # alias # Create a milestone linear milestone create --project abc123 --name "Q1 Goals" --target-date "2026-03-31" linear m create --project abc123 # interactive mode # Update a milestone linear milestone update xyz789 --name "Q1 Objectives" linear m update xyz789 --target-date "2026-04-15" # Delete a milestone linear milestone delete xyz789 linear m delete xyz789 --force # skip confirmation ```