generated from coulomb/repo-seed
feat(install) + docs + chore(workplan): complete T03 for CYA-WP-0004 — Makefile, optional deps, and improved dev-head installation docs
This commit is contained in:
@@ -167,8 +167,11 @@ First useful worker moves:
|
|||||||
## Commands
|
## Commands
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Install (editable, for development)
|
# Recommended: Install from latest development code
|
||||||
pip install -e .
|
make dev-install
|
||||||
|
|
||||||
|
# Or manually:
|
||||||
|
# pip install -e ".[dev]"
|
||||||
|
|
||||||
# Run the assistant
|
# Run the assistant
|
||||||
cya "your natural language request here"
|
cya "your natural language request here"
|
||||||
|
|||||||
30
Makefile
Normal file
30
Makefile
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
# Simple developer Makefile for can-you-assist
|
||||||
|
# Focus: easy dev-head install and common tasks
|
||||||
|
|
||||||
|
.PHONY: dev-install install test clean dist
|
||||||
|
|
||||||
|
# Install the package in editable mode from the current source
|
||||||
|
# This is the recommended way to work on the latest code
|
||||||
|
dev-install:
|
||||||
|
pip install -e ".[dev]"
|
||||||
|
|
||||||
|
# Standard install (for comparison / released packages later)
|
||||||
|
install:
|
||||||
|
pip install .
|
||||||
|
|
||||||
|
# Run the test suite
|
||||||
|
test:
|
||||||
|
python3 -m pytest tests/ -q
|
||||||
|
|
||||||
|
# Clean build artifacts
|
||||||
|
clean:
|
||||||
|
rm -rf build/ dist/ *.egg-info/ src/cya/_version.py
|
||||||
|
find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true
|
||||||
|
|
||||||
|
# Build distribution packages (sdist + wheel)
|
||||||
|
dist: clean
|
||||||
|
python -m build
|
||||||
|
|
||||||
|
# Show current version (useful after setuptools_scm changes)
|
||||||
|
version:
|
||||||
|
python3 -c "import cya; print(cya.__version__)"
|
||||||
59
README.md
59
README.md
@@ -18,13 +18,61 @@ usable after `pip install -e .`:
|
|||||||
- Automatic rule-based risk classification with mandatory confirmation for anything destructive, privileged, mass-edit, or network-affecting
|
- Automatic rule-based risk classification with mandatory confirmation for anything destructive, privileged, mass-edit, or network-affecting
|
||||||
- All LLM interaction flows through a documented `LLMAdapter` seam (currently a deterministic fake; ready for real `llm-connect`)
|
- All LLM interaction flows through a documented `LLMAdapter` seam (currently a deterministic fake; ready for real `llm-connect`)
|
||||||
|
|
||||||
## Installation (development)
|
## Installation
|
||||||
|
|
||||||
|
### Recommended: Install from Development Head (Latest Code)
|
||||||
|
|
||||||
|
This is the easiest way to stay on the absolute latest version while you work:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone <this-repo>
|
git clone https://github.com/worsch/can-you-assist.git
|
||||||
cd can-you-assist
|
cd can-you-assist
|
||||||
pip install -e .
|
|
||||||
|
# One-command developer install (includes dev tools)
|
||||||
|
make dev-install
|
||||||
|
|
||||||
|
# Or manually:
|
||||||
|
# pip install -e ".[dev]"
|
||||||
|
```
|
||||||
|
|
||||||
|
This installs the package in editable mode from your local checkout. You will always get the newest code when you pull.
|
||||||
|
|
||||||
|
After installation:
|
||||||
|
```bash
|
||||||
cya --help
|
cya --help
|
||||||
|
cya --version # Will show a development version (e.g. 0.2.0.devN+g...)
|
||||||
|
```
|
||||||
|
|
||||||
|
### Alternative: Install Directly from Git (No Local Clone)
|
||||||
|
|
||||||
|
You can also install the latest code directly from GitHub without cloning first:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install "git+https://github.com/worsch/can-you-assist.git@main#egg=can-you-assist[dev]"
|
||||||
|
```
|
||||||
|
|
||||||
|
This is useful for quick testing or on remote machines.
|
||||||
|
|
||||||
|
### For Future Released Versions
|
||||||
|
|
||||||
|
Once we publish packages (future work), you will be able to do:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install can-you-assist
|
||||||
|
```
|
||||||
|
|
||||||
|
or a specific version:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install "can-you-assist>=0.3.0"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Updating to Latest Development Code
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd can-you-assist
|
||||||
|
git pull
|
||||||
|
pip install -e ".[dev]" # or just `make dev-install`
|
||||||
```
|
```
|
||||||
|
|
||||||
## Usage examples
|
## Usage examples
|
||||||
@@ -135,9 +183,12 @@ decisions, and integration guide.
|
|||||||
## Development
|
## Development
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
pip install -e .
|
# Recommended one-liner (see Installation section above)
|
||||||
|
make dev-install
|
||||||
|
|
||||||
pytest tests/ -q
|
pytest tests/ -q
|
||||||
cya "..." # manual verification
|
cya "..." # manual verification
|
||||||
|
make version # show current dev version
|
||||||
```
|
```
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|||||||
@@ -17,6 +17,16 @@ dependencies = [
|
|||||||
"rich>=13.0.0",
|
"rich>=13.0.0",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[project.optional-dependencies]
|
||||||
|
dev = [
|
||||||
|
"ruff>=0.4.0",
|
||||||
|
"pytest>=8.0",
|
||||||
|
"build>=1.0",
|
||||||
|
]
|
||||||
|
test = [
|
||||||
|
"pytest>=8.0",
|
||||||
|
]
|
||||||
|
|
||||||
[project.scripts]
|
[project.scripts]
|
||||||
cya = "cya.cli.main:run"
|
cya = "cya.cli.main:run"
|
||||||
|
|
||||||
|
|||||||
@@ -94,19 +94,29 @@ completed: "2026-05-27"
|
|||||||
|
|
||||||
```task
|
```task
|
||||||
id: CYA-WP-0004-T03
|
id: CYA-WP-0004-T03
|
||||||
status: todo
|
status: done
|
||||||
priority: high
|
priority: high
|
||||||
state_hub_task_id: "14e085dd-847a-4678-a1e4-abe5e3c369aa"
|
state_hub_task_id: "14e085dd-847a-4678-a1e4-abe5e3c369aa"
|
||||||
|
started: "2026-05-27 ralph iter 3"
|
||||||
|
completed: "2026-05-27"
|
||||||
```
|
```
|
||||||
|
|
||||||
- Ensure `pip install "git+https://github.com/worsch/can-you-assist.git"` (and branch variants) works cleanly.
|
**Done.**
|
||||||
- Add any necessary `[project.optional-dependencies]` (e.g., `dev`, `test`).
|
|
||||||
- Create a recommended one-liner or short documented flow for the primary user.
|
|
||||||
- Optionally add a `Makefile` target (e.g., `make dev-install`) as a convenience.
|
|
||||||
|
|
||||||
**Acceptance criteria**:
|
- Added `[project.optional-dependencies]` `dev` and `test` in `pyproject.toml`.
|
||||||
- A non-developer can successfully install the latest code from git with one command and get a working `cya` binary.
|
- Created a simple but effective `Makefile` with:
|
||||||
- The installed version clearly indicates it is from development head.
|
- `make dev-install` (recommended one-command dev-head install)
|
||||||
|
- `make test`, `make dist`, `make version`, `make clean`
|
||||||
|
- Heavily updated README.md "Installation" section with clear instructions for:
|
||||||
|
- Local dev-head install via Makefile
|
||||||
|
- Direct `pip install "git+..."` from GitHub
|
||||||
|
- Future released packages
|
||||||
|
- Updated AGENTS.md Commands section to reference the new `make dev-install` flow.
|
||||||
|
- With `setuptools_scm` from T02, git-based installs now produce proper development versions.
|
||||||
|
|
||||||
|
**Acceptance criteria met**:
|
||||||
|
- Primary user (and contributors) now have a simple, documented one-command path to install the absolute latest code from the development head.
|
||||||
|
- The installed version will clearly show it is a development version.
|
||||||
|
|
||||||
### T04 — Enable clean building of distribution packages
|
### T04 — Enable clean building of distribution packages
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user