All skills
wdm0006 avatar

/project-setup

@04f39a5

Sets up professional Python library projects with modern tooling (pyproject.toml, uv, ruff, pytest, pre-commit, GitHub Actions). Use when creating new Python libraries, modernizing existing projects to pyproject.toml, configuring linting/testing/CI, or setting up Makefiles and pre-commit hooks.

  • 5 files
  • 26.5 KB
  • Updated 3 months ago
  • GitHub

Use this Skill: https://skilld.dev/gh/wdm0006/python-skills/project-setup

This session only. Nothing lands on disk.

MAKEFILE.md

≈329 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Makefile Reference

Standard Makefile

.PHONY: help install dev test lint format type-check clean build publish

help:
	@echo "Commands: dev test lint format type-check clean build publish"

dev:
	uv sync --extra dev --extra docs
	pre-commit install

test:
	pytest

# lint must stay read-only and mirror CI exactly — no --fix here (that belongs in
# `format`). An auto-fixing lint target mutates files and exits 0, hiding real
# violations that CI's read-only check then fails on.
lint:
	ruff check src tests
	ruff format --check src tests   # formatting is NOT covered by ruff check

format:
	ruff format src tests
	ruff check --fix src tests

type-check:
	mypy src

clean:
	rm -rf build dist *.egg-info .pytest_cache .mypy_cache .ruff_cache .coverage htmlcov
	find . -type d -name __pycache__ -exec rm -rf {} +

build: clean
	uv build

publish: build
	twine upload dist/*

With uv (faster)

dev:
	uv pip install -e ".[dev,docs]"
	pre-commit install

install:
	uv pip install .

Additional Targets

# Documentation
docs:
	cd docs && make html

docs-serve:
	uv run python -m http.server --directory docs/_build/html

# Coverage report
coverage:
	pytest --cov-report=html
	open htmlcov/index.html

# Security scanning
security:
	bandit -r src/
	pip-audit

Source: SKILL.md on GitHub

No third-party reports yet.

Signed by skilld at 04f39a5. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 weeks ago.

Activeupdated 3 months ago

README badge

README badge for wdm0006/python-skills/project-setup