Skip to content

Feat/new machine setup and features doc

cbaker requested to merge feat/new-machine-setup-and-features-doc into main

Summary

  • New-machine setup (make setup now handles everything): expands Makefile to run uv sync, approve .envrc (with graceful fallback if direnv isn't installed), and install prek hooks in one command. README and CONTRIBUTING both document the Windows path (manual uv sync + prek install steps, Git Bash note).
  • Feature inventory (FEATURES.md): new file in the repo root cataloguing every practice baked into the template — what each feature does, which files it touches, and how to retrofit it into an existing project. Intended both for AI tools asked to migrate template features and for developers adopting practices selectively.
  • Hatchling src layout cleanup: replaces [tool.hatch.build.targets.wheel] packages = ["src/{{ ... }}"] with [tool.hatch.build] sources = ["src"] — cleaner, no Jinja2 expression in pyproject.toml.
  • openBIS scripts removed: replaced by DVC registry approach.

Resolves

  • "make sure that if a person gets a new computer and clones a cookiecutter-created repo that the docs explain how to re-init everything (perhaps with a script)"make setup is now the single command for macOS/Linux; Windows manual steps are documented in both README and CONTRIBUTING.
  • "make sure that there's a clearly defined set of features in the cookiecutter template to help an AI tool and/or user migrate cookiecutter features to an existing project" — covered by FEATURES.md.

Test plan

  • Generate a standard project from the branch and run make setup on a clean clone — confirm uv sync, direnv approval, and prek hooks all complete
  • Generate a data_project and confirm post-checkout hook installs correctly via make setup
  • Verify uv run pytest and uv run prek run --all-files work in a generated project (confirms sources = ["src"] is picked up correctly)
Edited by cbaker

Merge request reports

Loading