Symbol lookup / search engine CLI
Project description
Pluk
Git-commit–aware symbol lookup & impact analysis engine
Pluk gives developers “go-to-definition”, “find-all-references”, and “blast-radius” impact queries across one or more Git repositories. Heavy lifting (indexing, querying, storage) runs in isolated Docker containers; a lightweight host CLI bootstraps and delegates commands.
Key Features
- symbol search (
pluk search) and definition lookup (pluk define) - Impact analysis (
pluk impact) to trace downstream dependents via recursive CTEs & caching - Commit-aware indexing: evolves symbol graph across Git history (
pluk diff) - Zero-friction install:
pip install pluk+ Docker & Compose - Containerized backend: PostgreSQL for the graph, Redis for cache
- Single Python codebase: host shim (
pluk.bootstrap) + container CLI (pluk.cli)
Quickstart
-
Install
pip install pluk
Ensure Docker & Docker Compose are installed and your user can run
docker. -
Bootstrap & index
pluk init /path/to/your/repo
Sets up containers and indexes the repo.
-
Run queries
pluk search MyClass # search definitions & refs pluk define my_function # show definition location pluk impact computeFoo # trace downstream dependents pluk diff abc123 def456 # symbol changes between commits
-
Manage services
pluk start # launch FastAPI server + worker pluk cleanup # teardown Docker Compose stack
All commands run on the host; Pluk manages Docker Compose under ~/.pluk/docker-compose.yml by default.
Data Flow
Pluk’s host shim (pluk) writes a Compose file and delegates commands into the container CLI (plukd). Inside the container, plukd interacts with Postgres and Redis; results stream back to your terminal.
Architecture
[Host CLI: pluk] ── docker-compose ──▶ [Container: plukd]
│
├─▶ Postgres (symbol graph)
└─▶ Redis (cache)
-
pluk(host shim)- Writes and manages
docker-compose.ymlunder~/.pluk/ - Forwards user commands into the container via
docker compose exec
- Writes and manages
-
plukd(container CLI)- Implements
init,search,define,impact,diff,start,cleanup - Parses repos, builds AST index, executes queries with SQL & Python
- Implements
-
Postgres stores commits, symbol definitions, and reference links
-
Redis caches expensive recursive queries for sub-second responses
Development
# Clone & install in editable mode
git clone https://github.com/Jorstors/pluk.git
cd pluk
pip install -e .
-
Project layout (
src/pluk):bootstrap.py— host shim entrypoint (pluk)cli.py— container CLI (plukd)
-
Entry points in
pyproject.toml:[project.scripts] pluk = "pluk.bootstrap:main" plukd = "pluk.cli:main"
Testing
- Unit tests for argument parsing and shim logic (
pytest) - Integration tests invoking
pluk initon a sample repo
pytest tests/
Note: Docker daemon must be running locally.
🔖 Versioning
We use bumpver for semantic versioning:
bumpver patch # 0.1.0 → 0.1.1
bumpver minor # 0.1.1 → 0.2.0
bumpver major # 0.2.0 → 1.0.0
📄 License
Distributed under the MIT License. See LICENSE for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pluk-0.3.5.tar.gz.
File metadata
- Download URL: pluk-0.3.5.tar.gz
- Upload date:
- Size: 9.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
612db44848efa12a3d9af42ce1a5e635f53db68a3cf1f563c6d017ea87143857
|
|
| MD5 |
c9764e85a7726410fe6862696facef9f
|
|
| BLAKE2b-256 |
b71ec9c6617f0f8adf994eac03ba07d2b5061047aedae61fb2a55c0b586b1218
|
File details
Details for the file pluk-0.3.5-py3-none-any.whl.
File metadata
- Download URL: pluk-0.3.5-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e004824e9e2a8e0d51e5e92cae4204b7fba48a984f3ef745fe287d6ad70a1a8
|
|
| MD5 |
cfc08ce5cae3fdca9bc39e078fe8e170
|
|
| BLAKE2b-256 |
be7c9e978d198793ec4c63cec22a530ea7cccfc0fbb0930327390b139b8c8fb1
|