This repository was archived by the owner on Aug 5, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
55 lines (37 loc) · 1.25 KB
/
Copy pathMakefile
File metadata and controls
55 lines (37 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
.DEFAULT_GOAL := help
SHELL := /bin/bash
.PHONY: install ## install required dependencies on bare metal
install:
uv sync --refresh
.PHONY: format ## Run the formatter on bare metal
format:
uv run tox -e format
.PHONY: lint ## run the linter on bare metal
lint:
uv run tox -e lint
.PHONY: test ## run unit tests on bare metal
test:
uv run tox -e test
.PHONY: clean-docker ## Purge / remove related docker entities
clean-docker:
docker compose down --remove-orphans
.PHONY: build-docker ## Build the main image in docker
build-docker:
docker compose build
.PHONY: run-docker ## Runs containers with watching
run-docker:
docker compose up -d
.PHONY: test-docker ## run unit tests in docker
test-docker:
docker compose run --remove-orphans --entrypoint uv service run tox -e test
.PHONY: publish ## Build & publish the package to Nexus. Ensure to have UV_PUBLISH_USERNAME & UV_PUBLISH_PASSWORD environment variables set.
publish:
@version=$$(grep '^version *= *' pyproject.toml | head -1 | sed 's/version *= *"\(.*\)"/\1/'); \
echo "Current version: $$version"; \
read -p "Publish version $$version? (y/n): " confirm; \
if [ "$$confirm" = "y" ]; then \
uv build --no-sources && \
uv publish --verbose; \
else \
echo "Publish cancelled."; \
fi