Skip to main content

CLI for Huly project management

Project description

huly-cli

Python CLI for interacting with a Huly workspace from the terminal.

Status

This repo is currently a Python typer CLI, not a Node or pnpm project.

It has been checked against hcengineering/platform@v0.6.504 and smoke-tested against https://huly.example.com workspace my-ws.

What is verified today:

  • Authentication flow via /_accounts
  • Read access for projects, issues, components, documents, templates, members, labels, and issue descriptions
  • Live CRUD for issues, documents, components, and milestones on https://huly.example.com workspace my-ws
  • Live template description update and restore flow
  • Workspace-specific issue status display and status filtering
  • Local unit/CLI test suite
  • CI-equivalent local checks: uv sync --extra dev, uv run ruff check ., uv run ruff format --check ., uv run pytest tests/ -v, uv run python -m build, and uv run twine check dist/*

What is not fully verified yet:

  • Automated live-workspace CI has not been added
  • You should still prefer a disposable project or disposable teamspace for release-time live smoke tests

Known live compatibility gaps at the time of writing:

  • No known read-path breakage remains from the v0.6.504 comparison and smoke tests
  • No known CLI CRUD gap remains on the currently implemented issue, document, component, and milestone surfaces
  • The test suite now patches auth correctly; it no longer depends on a developer's local cached login state

Compatibility Target

  • Huly platform tag: v0.6.504
  • Example workspace URL used during verification: https://huly.example.com/workbench/my-ws/tracker/PROJECT_ID/issues

Important distinction:

  • my-ws is the workspace slug
  • DEMO is the project identifier in that workspace

If you run huly issues list --project MY-WS, it will fail because MY-WS is not a project ID.

Prerequisites

  • Python 3.11+
  • uv (only needed for source-checkout development)
  • A Huly account with access to the target workspace

Install

Option 1: Install from PyPI

Use this if you only want the CLI and are not modifying the source.

The package name is huly-cli. The executable is huly.

Recommended: pipx (standalone CLI install)

pipx is the recommended installer for standalone Python CLI tools. It creates an isolated environment per tool, puts the executable on PATH automatically, and works out of the box on PEP 668 environments (including modern macOS with Homebrew-managed Python, where bare pip install is blocked with externally-managed-environment).

pipx install huly-cli
huly --help

Upgrade an existing install:

pipx upgrade huly-cli

Alternative: pip (virtualenv or CI)

Use pip if you are installing into an existing virtualenv or a controlled CI environment:

pip install huly-cli
huly --help

Upgrade an existing install:

pip install --upgrade huly-cli

If huly is not found after a user-site pip install, the install directory may not be on your PATH (e.g. ~/.local/bin on macOS/Linux or %APPDATA%\Python\PythonXY\Scripts on Windows). Either add that directory to PATH, or switch to pipx, which handles PATH automatically.

Option 2: Use from a source checkout

Use this if you are developing in this repository:

  1. Install dependencies, including dev tools:
uv sync --extra dev
  1. Copy the example environment file:
cp .env.example .env
  1. Edit .env with at least:
  • HULY_URL
  • HULY_WORKSPACE
  1. Choose one auth approach:
  • Interactive login: preferred for local use
  • Environment-based login: useful for non-interactive runs and token refresh

Environment Variables

The CLI loads config in this order:

  1. CLI flags
  2. Environment variables
  3. .env in the current directory
  4. ~/.config/huly/config.toml

Supported variables:

  • HULY_URL
  • HULY_WORKSPACE
  • HULY_EMAIL
  • HULY_PASSWORD

Auth cache location:

  • Config: ~/.config/huly/config.toml
  • Tokens: ~/.config/huly/auth.json

The token cache is reused automatically. If the cached token expires, the CLI needs HULY_EMAIL and HULY_PASSWORD available in order to re-authenticate automatically.

Login Walkthrough

Source checkout? Replace huly below with uv run huly.

Option 1: Interactive login

This is the simplest flow if you are testing locally and do not want to keep your password in .env.

huly --url https://huly.example.com --workspace my-ws auth login

You will be prompted for:

  • Email
  • Password
  • Workspace slug, if it was not passed on the command line or set in .env

Then confirm auth is valid:

huly auth status

Option 2: Login using .env

Put all four values in .env:

HULY_URL=https://huly.example.com
HULY_WORKSPACE=my-ws
HULY_EMAIL=you@example.com
HULY_PASSWORD=your-password

Then run:

huly auth login
huly auth status

Agent Skill

This repo includes a Codex skill for agents that need to install or operate the CLI:

  • skill path: skills/huly-cli
  • explicit invocation: $huly-cli

If you want to install that skill into a Codex skills directory outside this repo, copy or symlink it into ${CODEX_HOME:-$HOME/.codex}/skills:

mkdir -p "${CODEX_HOME:-$HOME/.codex}/skills"
ln -s "$(pwd)/skills/huly-cli" "${CODEX_HOME:-$HOME/.codex}/skills/huly-cli"

If you prefer a copy instead of a symlink:

mkdir -p "${CODEX_HOME:-$HOME/.codex}/skills"
cp -R skills/huly-cli "${CODEX_HOME:-$HOME/.codex}/skills/"

Hands-On Smoke Test

Source checkout? Replace huly below with uv run huly. The repo also has an automated smoke runner: uv run python scripts/live_smoke.py (add --allow-writes for CRUD checks with automatic cleanup).

  1. Confirm auth:
huly auth status
  1. List projects:
huly projects list
  1. Inspect a project:
huly projects get DEMO
  1. List a few issues from that project:
huly issues list --project DEMO --limit 5
  1. Inspect one issue:
huly issues get DEMO-1
  1. Read the issue description:
huly issues describe DEMO-1
  1. List project components:
huly components list --project DEMO --limit 5
  1. Inspect a component by internal ID:
huly components get COMPONENT_ID
  1. List a few documents:
huly documents list --limit 5
  1. List issue templates:
huly templates list --limit 5
  1. Verify status filtering:
huly issues list --status backlog --limit 5
  1. List workspace members:
huly members list
  1. List labels:
huly labels list

JSON mode

If you want machine-readable output for quick inspection:

huly --json projects list
huly --json issues list --project DEMO --limit 5
huly --json auth status

Commands That Currently Need Caution

The CLI write paths were exercised live during verification, but you should still prefer a disposable project or disposable teamspace when doing release-time smoke tests against a real workspace.

Local Test Suite

Run the unit and CLI regression tests with:

uv run --extra dev pytest -q

Expected result at the time of verification:

  • 155 passed

Packaging And PyPI

The package is published on PyPI as huly-cli.

Install it with pipx (recommended for end-users):

pipx install huly-cli

Or with pip (for virtualenvs or CI):

pip install huly-cli

The repo also builds a wheel and sdist cleanly and CI validates the distribution metadata.

For the maintainer release checklist and publisher configuration notes, see RELEASE.md.

CLI Help

Top-level help:

huly --help

Auth help:

huly auth login --help

License

MIT

Project details


Download files

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

Source Distribution

huly_cli-0.1.5.tar.gz (112.8 kB view details)

Uploaded Source

Built Distribution

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

huly_cli-0.1.5-py3-none-any.whl (48.1 kB view details)

Uploaded Python 3

File details

Details for the file huly_cli-0.1.5.tar.gz.

File metadata

  • Download URL: huly_cli-0.1.5.tar.gz
  • Upload date:
  • Size: 112.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for huly_cli-0.1.5.tar.gz
Algorithm Hash digest
SHA256 69ceae54d1a4a35ce5a82c86f5fd743484b39e630b93ccef5093fac7e2b0d29a
MD5 9eb4b905d8c7de5c7cda896506cc34c1
BLAKE2b-256 3dbc9fac33fcfaef4430d2f464f490beb900920c3334a467d8162e2db8adbbd0

See more details on using hashes here.

Provenance

The following attestation bundles were made for huly_cli-0.1.5.tar.gz:

Publisher: publish-pypi.yml on teslakoile/huly-cli

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

File details

Details for the file huly_cli-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: huly_cli-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 48.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for huly_cli-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 1dfbe45aacfa2aa03335c9fa801252b475ccdbf97958807296092d1767b41718
MD5 ee031baf29205f8079ece1848c192b49
BLAKE2b-256 c7af1e7cfc82a3ab35a7120fad89caaf333c42bc3940ca7612ba32f74e55f0e7

See more details on using hashes here.

Provenance

The following attestation bundles were made for huly_cli-0.1.5-py3-none-any.whl:

Publisher: publish-pypi.yml on teslakoile/huly-cli

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

Supported by

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