Skip to main content

Reusable environment detection, activation, and wrapper tooling for developer CLIs.

Project description

dekk

Make project CLIs runnable with one config and zero manual activation.

Install

pipx install dekk

Fallback:

python -m pip install --upgrade dekk

Minimal Setup

dekk install ./tools/cli.py

If .dekk.toml is missing, dekk install and dekk wrap create a starter file from the repo context first.

Explicit template-driven setup is still available:

dekk init --example conda
eval "$(dekk activate --shell bash)"

Optional (no activation after this):

dekk wrap myapp ./tools/cli.py

Worktree-safe default:

dekk install ./tools/cli.py        # no shell rc PATH edits by default
dekk install ./tools/cli.py --update-shell

Project Command Routing

All project commands go through dekk <appname>, which finds the nearest .dekk.toml and runs with cwd set to that project root:

dekk myapp                   # project-aware help
dekk myapp --help
dekk myapp server --port 8080
dekk myapp build
dekk myapp test

This is worktree-friendly by default:

  • dekk walks up from your current directory to find the nearest .dekk.toml
  • the app name must match [project].name
  • the command runs with cwd set to that project root, not whatever nested directory you happened to be in
  • activation is scoped to that project config before the command runs

That means dekk myapp server works correctly from a repo root, a nested subpackage, or a separate Git worktree for the same project, without relying on global shell state.

Built-in Project Tools

Built-in tools (setup, agents, worktree) are project-scoped — they require the app name so dekk knows which project context to use:

dekk myapp setup
dekk myapp agents init
dekk myapp agents generate --target all
dekk myapp worktree create feature-x --base main
dekk myapp worktree list

Why the app name? Because dekk resolves paths from your current directory. The app name selects the project (validates against [project].name in .dekk.toml), and all paths resolve relative to that project root. This makes every command worktree-safe — it works correctly from any checkout.

Agents

Source of truth: .agents/

dekk myapp agents init
dekk myapp agents generate --target all
dekk myapp agents clean --target codex
dekk myapp agents install        # optional (installs Codex skills to ~/.codex/skills)

Generated files: AGENTS.md, CLAUDE.md, .cursorrules, .github/copilot-instructions.md, .agents.json

Worktrees

dekk myapp worktree create feature-x --base main
dekk myapp worktree list
dekk myapp worktree remove feature-x
dekk myapp worktree prune

Worktrees with .dekk.toml get automatic environment setup on creation. Auto-scaffolded as an agent skill via dekk myapp agents init for git repos.

Inheriting Tools in Downstream CLIs

CLIs built with dekk.Typer can also inherit these tools directly, useful when worktree isolation is not a concern:

from dekk import Typer

app = Typer(
    name="myapp",
    auto_activate=True,
    add_doctor_command=True,
    add_version_command=True,
    add_worktree_command=True,
    add_agents_command=True,
)

Docs

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

dekk-1.5.1.tar.gz (245.3 kB view details)

Uploaded Source

Built Distribution

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

dekk-1.5.1-py3-none-any.whl (188.0 kB view details)

Uploaded Python 3

File details

Details for the file dekk-1.5.1.tar.gz.

File metadata

  • Download URL: dekk-1.5.1.tar.gz
  • Upload date:
  • Size: 245.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for dekk-1.5.1.tar.gz
Algorithm Hash digest
SHA256 14b5c75c81776bbf1c002d40806156e9cdb54c60739a312cb2f20f051ad53e92
MD5 f82a5453b51c1cc6e99f2cb6b2f14062
BLAKE2b-256 0fae7c3120019ab0c64499b9f811a5a6ff2bd30943198c53404eaf1eab44fcbf

See more details on using hashes here.

Provenance

The following attestation bundles were made for dekk-1.5.1.tar.gz:

Publisher: python-publish.yml on randreshg/dekk

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

File details

Details for the file dekk-1.5.1-py3-none-any.whl.

File metadata

  • Download URL: dekk-1.5.1-py3-none-any.whl
  • Upload date:
  • Size: 188.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for dekk-1.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 976830532cb0a006a4db6aa7630131b3f9c741ea43e82d0bfc5d6f8384fa6678
MD5 9c3dddfa0db89152199b0f3e3d5c2f45
BLAKE2b-256 c2ab19b755583836ad9da7434207d15ddbabc4150a3e47c8de28c9d8b52c3f73

See more details on using hashes here.

Provenance

The following attestation bundles were made for dekk-1.5.1-py3-none-any.whl:

Publisher: python-publish.yml on randreshg/dekk

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