- Configure Ruff for linting and formatting with pre-commit hooks - Add Makefile with convenient commands for development workflow - Create build and upload scripts for Gitea package registry - Update README with documentation for new features - Fix code quality issues identified by Ruff - Add development dependencies (ruff, pre-commit) to pyproject.toml - Update Python version requirement to >=3.9 - Add template for Gitea PyPI configuration - Bump version to 0.3.0 - All tests passing and code properly formatted
49 lines
1.0 KiB
Makefile
49 lines
1.0 KiB
Makefile
# Makefile for building and uploading paroles-net-scraper package
|
|
|
|
.PHONY: build upload clean help lint format check test install-dev
|
|
|
|
# Default target
|
|
help:
|
|
@echo "Available targets:"
|
|
@echo " build - Build the package"
|
|
@echo " upload - Build and upload package to Gitea"
|
|
@echo " clean - Clean build artifacts"
|
|
@echo " lint - Lint Python code with Ruff"
|
|
@echo " format - Format Python code with Ruff"
|
|
@echo " check - Check Python code with Ruff"
|
|
@echo " test - Run tests"
|
|
@echo " install-dev - Install development dependencies"
|
|
@echo " help - Show this help message"
|
|
|
|
# Build the package
|
|
build:
|
|
uv build
|
|
|
|
# Upload package to Gitea
|
|
upload:
|
|
./scripts/build_and_upload.sh
|
|
|
|
# Clean build artifacts
|
|
clean:
|
|
rm -rf dist/ *.egg-info/
|
|
|
|
# Install development dependencies
|
|
install-dev:
|
|
uv pip install -e .[test]
|
|
|
|
# Run tests
|
|
test:
|
|
uv run pytest tests/ -v
|
|
|
|
# Lint Python code with Ruff
|
|
lint:
|
|
ruff check . --fix
|
|
|
|
# Format Python code with Ruff
|
|
format:
|
|
ruff format .
|
|
|
|
# Check Python code with Ruff
|
|
check:
|
|
ruff check .
|