linear-cli
A fast, comprehensive command-line interface for Linear built in Rust. Manage issues, projects, cycles, sprints, documents, and more -- entirely from your terminal.
Installation
# From crates.io
# With OS keyring support (Keychain, Credential Manager, Secret Service)
# From source
&&
Pre-built binaries are available at GitHub Releases.
Quick Start
# 1. Set your API key (get one at https://linear.app/settings/api)
# Or use OAuth 2.0 (browser-based, auto-refreshing)
# 2. List your issues
# 3. Start working on an issue (assigns to you, sets In Progress, creates branch)
# 4. When done, mark complete and create a PR
Commands
Issues
Full issue lifecycle management with 16 subcommands.
List flags: --mine, --team, --state, --assignee, --project, --label, --since, --view, --group-by (state/priority/assignee/project), --count-only, --archived
Projects
Full project CRUD with label management and archiving.
Project Updates
Track project health with status updates (onTrack, atRisk, offTrack).
Teams
Cycles
Sprint Planning
Plan and manage cycle-based sprints with progress visualization, burndown charts, and velocity tracking.
Documents, Labels, Comments
# Documents
# Labels
# Comments
Milestones, Roadmaps, Initiatives
# Milestones
# Roadmaps
# Initiatives
Custom Views
Relations
Attachments
Templates
Local templates and Linear workspace (remote) templates.
# Local templates
# Linear workspace templates
Notifications
Statuses & Time Tracking
# Statuses
# Time tracking
Favorites
Users
Webhooks
Full CRUD plus a local listener with HMAC-SHA256 signature verification.
Watch Mode
Poll for real-time changes to issues, projects, or teams.
Triage
Bulk Operations
Git Integration
Works with both Git and Jujutsu (jj).
Import / Export
Round-trip CSV and JSON import/export with field resolution for status, assignee, and labels.
# Import
# Export
Search & Context
Raw GraphQL
Direct API access for anything not covered by built-in commands.
Other Commands
Authentication
Two authentication methods are supported. Both can be used per-profile.
API Key
# Set directly
# Or interactive login
# Store in OS keyring (requires --features secure-storage)
# Or use environment variable (highest priority)
OAuth 2.0
Browser-based Authorization Code + PKCE flow with automatic token refresh.
Auth priority: LINEAR_API_KEY env var > OS keyring > OAuth tokens > config file API key.
Configuration
Config is stored at ~/.config/linear-cli/config.toml (Linux/macOS) or %APPDATA%\linear-cli\config.toml (Windows).
# Multiple workspaces
# Per-invocation profile override
Setup & Diagnostics
Shell Completions
Static Completions
Generate tab completions for command names and flags.
# Bash
# Zsh
# Fish
# PowerShell
Dynamic Completions
Context-aware completions that query the Linear API for team names, project names, issue identifiers, statuses, and more.
Legacy alias: linear-cli config completions <shell> also generates static completions.
Agent & Automation Usage
linear-cli is designed to work well with AI agents and scripts. Every command supports machine-readable output.
Output Flags
| Flag | Purpose |
|---|---|
--output json |
JSON output (also ndjson) |
--compact |
Compact JSON (no pretty-printing) |
--fields a,b,c |
Limit JSON to specific fields (dot paths supported) |
--sort field |
Sort JSON arrays by field |
--order asc|desc |
Sort direction |
--quiet |
Suppress decorative output |
--id-only |
Only output resource ID (for chaining) |
--format tpl |
Template output, e.g. "{{identifier}} {{title}}" |
--filter f=v |
Client-side filter (=, !=, ~=; dot paths; case-insensitive) |
--fail-on-empty |
Non-zero exit when list is empty |
--dry-run |
Preview without making changes |
--yes |
Auto-confirm all prompts |
--no-pager |
Disable auto-paging |
--no-cache |
Bypass cache |
Scripting Examples
# Get issue ID for chaining
ID=
# JSON output for programmatic consumption
# Pipe description from file
|
# JSON input for structured create/update
|
# Default JSON for entire session
# Batch get with structured output
Exit Codes
| Code | Meaning |
|---|---|
0 |
Success |
1 |
General error |
2 |
Not found |
3 |
Auth error |
4 |
Rate limited |
Pagination
Agent Skills
linear-cli includes Agent Skills for AI coding assistants (Claude Code, Cursor, Codex, etc.).
# Install all skills
# Install specific skill
27 skills covering issues, git, planning, organization, operations, and tracking. Skills are 10-50x more token-efficient than MCP tools. See docs/skills.md for details.
Key Features
- 50+ commands across 30+ command groups with short aliases
- OAuth 2.0 + PKCE authentication alongside API key auth
- Dynamic shell completions for bash, zsh, fish, and PowerShell
- Import/Export with round-trip CSV and JSON support
- Sprint planning with progress bars, burndown charts, velocity tracking, and carry-over between cycles
- Webhook listener with HMAC-SHA256 signature verification
- Watch mode for real-time polling on issues, projects, and teams
- Custom views that can be applied to issue and project lists
- Bulk operations for updating, assigning, and labeling multiple issues
- Git and Jujutsu (jj) support for branch management and PR creation
- Interactive TUI for browsing and managing issues
- Template system with both local and Linear workspace templates
- Auto-paging output through
lesson Unix terminals - Multiple workspaces with named profiles and seamless switching
- Reliable networking with HTTP timeouts, jittered retries, and atomic cache writes
Documentation
- Agent Skills -- 27 skills for AI agents
- AI Agent Integration -- Setup for Claude Code, Cursor, Codex
- Usage Examples -- Detailed command examples
- Workflows -- Common workflow patterns
- JSON Samples -- Example JSON output shapes
- Shell Completions -- Tab completion setup
Comparison with Other CLIs
| Feature | @linear/cli | linear-go | linear-cli |
|---|---|---|---|
| Last updated | 2021 | 2023 | 2026 |
| Commands | ~10 | ~10 | 50+ |
| Agent Skills | No | No | 27 skills |
| OAuth 2.0 (PKCE) | No | No | Yes |
| Sprint planning | No | No | status, progress, burndown, velocity, carry-over |
| Import/Export | No | No | CSV, JSON, Markdown |
| Webhooks + listener | No | No | CRUD + HMAC-SHA256 listener |
| Custom views | No | No | Full CRUD + apply |
| Project updates | No | No | CRUD + health status |
| Templates (local + remote) | No | No | Full CRUD |
| Dynamic completions | No | No | bash/zsh/fish/pwsh |
| Issue workflow actions | No | No | assign, move, transfer, close, archive |
| Bulk operations | No | No | Yes |
| Watch mode | No | No | issue, project, team |
| Raw GraphQL API | No | No | query + mutate |
| Git + jj support | No | No | Yes |
| Interactive TUI | No | No | Yes |
| Multiple workspaces | No | No | Yes |
| JSON output | No | Yes | JSON, NDJSON, templates |
Contributing
Contributions welcome! Please open an issue or submit a pull request.