-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
71 lines (58 loc) · 1.52 KB
/
Copy pathMakefile
File metadata and controls
71 lines (58 loc) · 1.52 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
.PHONY: usage
usage:
@echo "Usage: make [target]"
@echo
@echo "Targets:"
@echo " clean Remove all generated files"
@echo " lint Run ruff format, check and uv sync"
@echo " commit Run cz commit"
@echo " build Build the project"
@echo
@echo " help Run tripit-tools help"
@echo " version Run tripit-tools version"
@echo " flights Run tripit-tools flights"
@echo " profiles Run tripit-tools profiles"
@echo " trips Run tripit-tools trips"
@echo
.PHONY: clean
clean:
@git clean -Xdf
@mkdir -p .git/hooks
@rm -f .git/hooks/*.sample
@find .git/hooks/ -type f | while read i; do chmod +x $$i; done
.PHONY: lint
lint:
@uv run --quiet deptry src --experimental-namespace-package
@uv run --quiet ruff format src
@uv run --quiet ruff check src --quiet
@uv sync --quiet
.PHONY: commit
commit: lint
@uv run --quiet cz commit
.PHONY: build
build: lint
@uv build
.PHONY: help
help: lint
@uv run --quiet tripit-tools --help
.PHONY: version
version: lint
@uv run --quiet tripit-tools --version
.PHONY: flights
flights: lint
@uv run --quiet tripit-tools flights
.PHONY: flights.json
flights.json: lint
@uv run --quiet tripit-tools flights --json | jq > $@
.PHONY: profiles
profiles: lint
@uv run --quiet tripit-tools profiles
.PHONY: profiles.json
profiles.json: lint
@uv run --quiet tripit-tools profiles --json | jq > $@
.PHONY: trips
trips: lint
@uv run --quiet tripit-tools trips
.PHONY: trips.json
trips.json: lint
@uv run --quiet tripit-tools trips --json | jq > $@