59 lines
1.3 KiB
Rust
59 lines
1.3 KiB
Rust
use clap::Parser;
|
|
|
|
#[derive(Parser)]
|
|
#[command(name = "worklane")]
|
|
#[command(about = "A CLI tool for managing project status")]
|
|
pub struct Cli {
|
|
#[command(subcommand)]
|
|
pub command: Command,
|
|
}
|
|
|
|
#[derive(clap::Subcommand)]
|
|
pub enum Command {
|
|
/// Initialize worklane in the current project
|
|
Init,
|
|
|
|
/// Add a new ticket to the backlog
|
|
Add {
|
|
/// Ticket title
|
|
#[arg(short, long)]
|
|
title: String,
|
|
|
|
/// Ticket description
|
|
#[arg(short, long)]
|
|
description: Option<String>,
|
|
|
|
/// Acceptance criteria (comma-separated)
|
|
#[arg(short, long)]
|
|
acceptance: Vec<String>,
|
|
|
|
/// Implementation plan (comma-separated steps)
|
|
#[arg(short, long)]
|
|
plan: Vec<String>,
|
|
|
|
/// Tags (comma-separated)
|
|
#[arg(short = 'g', long)]
|
|
tags: Vec<String>,
|
|
|
|
/// Due date (YYYY-MM-DD)
|
|
#[arg(long)]
|
|
due: Option<String>,
|
|
|
|
/// Owner
|
|
#[arg(short, long)]
|
|
owner: Option<String>,
|
|
},
|
|
|
|
/// List tickets, optionally filtered by status
|
|
Ls {
|
|
/// Filter by status (backlog, committed, reviewing, done)
|
|
status: Option<String>,
|
|
},
|
|
|
|
/// Show a ticket by UUID or title
|
|
Show {
|
|
/// Ticket UUID or title to search for
|
|
id: String,
|
|
},
|
|
}
|