Skip to main content

Jira CLI

A command-line interface for interacting with Jira.

This project uses UV for dependency management.

Installation

pip install cac-jira

Authentication

On first-run, you'll be prompted for a Jira API token; generate one here. This will be stored in your system credential store (e.g. Keychain on Mac OS) in an item called cac-jira.

Configuration

On first-run, a configuration file will be generated at ~/.config/cac_jira/config.yaml. In this file you'll need to replace the values of server and username with appropriate values.

server: https://your-jira-instance.atlassian.net
project: YOUR_PROJECT_KEY  # Optional default project
username: your.email@example.com

Usage

The Jira CLI follows a command-action pattern for all operations:

jira <command> <action> [options]

Global Options

  • --verbose: Enable debug output
  • --output [table|json]: Control output format (default table)
  • --help: Show command help

Examples

Issue Commands

List issues in a project:

jira issue list --project PROJ

List issues with additional filtering:

jira issue list --project PROJ

Create a new issue:

jira issue create --project PROJ --type Task --title "Fix login bug" --description "Users can't log in"

Create a new issue of a type that requires custom fields:

#
# This assumes the name of the custom fields is "Custom Field One" and "Custom Field Two";
# the field name will be swapped to lower-case, and spaces replaced with underscores
#
jira issue create --project PROJ --type Custom\ Issue\ Type --title "Issue Title" --description "Issue description" \
  --field custom_field_one custom_field_value \
  --field custom_field_two custom_field_value

Create and assign to yourself:

jira issue create --project PROJ --type Bug --title "Server crash" --assign

Create and immediately start work:

jira issue create --project PROJ --type Story --title "Add login feature" --begin

Add an issue to an epic:

jira issue create --project PROJ --type Task --title "Subtask" --epic PROJ-100

Label an issue:

jira issue label --issue ISSUE_KEY --labels label1,label2

Transition an issue:

jira issue begin --issue ISSUE_KEY    # Start work
jira issue close --issue ISSUE_KEY    # Mark as complete

Project Commands

List all projects:

jira project list

Show a project:

jira project show --name PROJ-123

Advanced Examples

Update an issue's title or description:

jira issue update --issue ISSUE_KEY --title "New issue title" --description "new issue description"

Add a comment to an issue:

jira issue comment --issue ISSUE_KEY --comment "This is a comment."

List all issue IDs matching a label:

jira issue list --output json | jq -r '.[] | select(.Labels | contains("production")) | .ID'

Development

Setup Development Environment

# Install dependencies including dev dependencies
uv sync

# Activate the venv
source .venv/bin/activate

# Run tests
uv run pytest

Please note that tests are still WIP

Project Structure

  • cac_jira/commands/ - Command implementations
    • issue/ - Issue-related commands
    • project/ - Project-related commands
  • cac_jira/cli/ - CLI entry point and argument parsing

Adding New Commands

  1. Create a new action module in the appropriate command directory.
  2. Define a class that inherits from the command's base class.
  3. Implement define_arguments() and execute() methods.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cac_jira-0.7.0.tar.gz (94.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cac_jira-0.7.0-py3-none-any.whl (29.4 kB view details)

Uploaded Python 3

File details

Details for the file cac_jira-0.7.0.tar.gz.

File metadata

  • Download URL: cac_jira-0.7.0.tar.gz
  • Upload date:
  • Size: 94.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for cac_jira-0.7.0.tar.gz
Algorithm Hash digest
SHA256 c499c94460304485e4cd49a19757cb1b9c7d200f38e0eac922f4ce878aa5036a
MD5 b383bcd507f037757b328d5029ea857a
BLAKE2b-256 a4dfd8e2925ab0c1f4ba877c09bb1c5829577ecce0ddd5c9e1442c079e97c208

See more details on using hashes here.

Provenance

The following attestation bundles were made for cac_jira-0.7.0.tar.gz:

Publisher: create_artifacts_and_publish.yaml on rpunt/cac-jira

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cac_jira-0.7.0-py3-none-any.whl.

File metadata

  • Download URL: cac_jira-0.7.0-py3-none-any.whl
  • Upload date:
  • Size: 29.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for cac_jira-0.7.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e711d7e039bdac93ceb168415a418b3182e350798a4bab881a2f9d6986210e0a
MD5 ab2962242276a3967399240f87524a47
BLAKE2b-256 ad0a85b7e481c956e966c1dc6a8662c94fe5ff0161c6cce1b2e7174354703a4f

See more details on using hashes here.

Provenance

The following attestation bundles were made for cac_jira-0.7.0-py3-none-any.whl:

Publisher: create_artifacts_and_publish.yaml on rpunt/cac-jira

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

1.2.0

2 files

1.1.0

2 files

1.0.0

2 files

This release

0.7.0 This release

2 files

0.6.11

2 files

0.6.10

2 files

0.6.9

2 files

0.6.6

2 files

0.6.5

2 files

0.6.3

2 files

0.6.1

2 files

0.6.0

2 files

0.5.5

2 files

0.5.4

2 files

0.5.3

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.0

2 files

0.3.4

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page