-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.doql.css
More file actions
191 lines (164 loc) · 6.25 KB
/
Copy pathapp.doql.css
File metadata and controls
191 lines (164 loc) · 6.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
app {
name: "regix";
version: "0.1.12";
}
interface[type="cli"] {
framework: argparse;
}
interface[type="cli"] page[name="regix"] {
}
workflow[name="install"] {
trigger: "manual";
step-1: run cmd=pip install .;
}
workflow[name="dev"] {
trigger: "manual";
step-1: run cmd=pip install -e ".[dev]";
}
workflow[name="test"] {
trigger: "manual";
step-1: run cmd=python -m pytest -q;
}
workflow[name="build"] {
trigger: "manual";
step-1: run cmd=python -m pip install --upgrade build twine;
step-2: run cmd=python -m build --sdist --wheel;
}
workflow[name="publish"] {
trigger: "manual";
step-1: run cmd=python -m twine upload dist/*;
}
workflow[name="clean"] {
trigger: "manual";
step-1: run cmd=rm -rf dist build *.egg-info .pytest_cache __pycache__ goal/__pycache__;
}
workflow[name="push"] {
trigger: "manual";
step-1: run cmd=if command -v goal &> /dev/null; then \;
step-2: run cmd=goal push; \;
step-3: run cmd=else \;
step-4: run cmd=echo "Goal not installed. Run 'make install' first."; \;
step-5: run cmd=fi;
}
workflow[name="benchmark"] {
trigger: "manual";
step-1: run cmd=$(PYTHON) -m regix.benchmark;
}
workflow[name="benchmark-ci"] {
trigger: "manual";
step-1: run cmd=$(PYTHON) -m regix.benchmark --plain --threshold 30.0;
}
workflow[name="benchmark-json"] {
trigger: "manual";
step-1: run cmd=$(PYTHON) -m regix.benchmark --json > .pyqual/benchmark.json;
}
workflow[name="docker-matrix"] {
trigger: "manual";
step-1: run cmd=bash integration/run_docker_matrix.sh;
}
workflow[name="deps-cache"] {
trigger: "manual";
step-1: run cmd=echo "${YELLOW}Downloading all deps to local wheel cache...${RESET}";
step-2: run cmd=mkdir -p $(WHEEL_CACHE);
step-3: run cmd=$(PIP) download -d $(WHEEL_CACHE) -e ".[dev]";
step-4: run cmd=echo "${GREEN}Cached $$(ls $(WHEEL_CACHE) | wc -l) wheels in $(WHEEL_CACHE)/${RESET}";
}
workflow[name="deps-lock"] {
trigger: "manual";
step-1: run cmd=echo "${YELLOW}Freezing current versions...${RESET}";
step-2: run cmd=$(PIP) freeze --exclude-editable > requirements-lock.txt;
step-3: run cmd=echo "${GREEN}Wrote requirements-lock.txt${RESET}";
}
workflow[name="test-offline"] {
trigger: "manual";
step-1: run cmd=echo "${YELLOW}Running tests offline (no network)...${RESET}";
step-2: run cmd=$(PYTHON) -m pytest tests/ -q --tb=short -p no:cacheprovider;
step-3: run cmd=echo "${GREEN}Offline tests complete${RESET}";
}
workflow[name="install-offline"] {
trigger: "manual";
step-1: run cmd=if [ ! -d "$(WHEEL_CACHE)" ]; then \;
step-2: run cmd=echo "${YELLOW}No wheel cache found. Run 'make deps-cache' first.${RESET}"; \;
step-3: run cmd=exit 1; \;
step-4: run cmd=fi;
step-5: run cmd=$(PIP) install --no-index --find-links=$(WHEEL_CACHE) -e ".[dev]";
}
workflow[name="bump-version"] {
trigger: "manual";
step-1: run cmd=if [ -z "$(PART)" ]; then \;
step-2: run cmd=echo "${YELLOW}Error: PART variable not set. Usage: make bump-version PART=<major|minor|patch>${RESET}"; \;
step-3: run cmd=exit 1; \;
step-4: run cmd=fi;
step-5: run cmd=echo "${YELLOW}Bumping $(PART) version...${RESET}";
step-6: run cmd=current_version=$$(grep '^version = ' pyproject.toml | head -1 | sed 's/version = "\(.*\)"/\1/'); \;
step-7: run cmd=echo "Current version: $$current_version"; \;
step-8: run cmd=IFS='.' read -r major minor patch <<< "$$current_version"; \;
step-9: run cmd=case "$(PART)" in \;
step-10: run cmd=major) major=$$((major + 1)); minor=0; patch=0 ;; \;
step-11: run cmd=minor) minor=$$((minor + 1)); patch=0 ;; \;
step-12: run cmd=patch) patch=$$((patch + 1)) ;; \;
step-13: run cmd=*) echo "${YELLOW}Error: PART must be major, minor, or patch${RESET}"; exit 1 ;; \;
step-14: run cmd=esac; \;
step-15: run cmd=new_version="$${major}.$${minor}.$${patch}"; \;
step-16: run cmd=sed -i "s/^version = \"$$current_version\"/version = \"$$new_version\"/" pyproject.toml; \;
step-17: run cmd=echo "${GREEN}Version bumped to $$new_version${RESET}"; \;
step-18: run cmd=git add pyproject.toml; \;
step-19: run cmd=git commit -m "Bump version to $$new_version"; \;
step-20: run cmd=if git rev-parse "v$$new_version" >/dev/null 2>&1; then \;
step-21: run cmd=echo "${YELLOW}Error: tag 'v$$new_version' already exists${RESET}"; \;
step-22: run cmd=exit 1; \;
step-23: run cmd=fi; \;
step-24: run cmd=git tag -a "v$$new_version" -m "Version $$new_version"; \;
step-25: run cmd=echo "${GREEN}Created tag v$$new_version${RESET}";
}
workflow[name="health"] {
trigger: "manual";
step-1: run cmd=docker compose ps;
step-2: run cmd=docker compose exec app echo "Health check passed";
}
workflow[name="import-makefile-hint"] {
trigger: "manual";
step-1: run cmd=echo 'Run: taskfile import Makefile to import existing targets.';
}
workflow[name="help"] {
trigger: "manual";
step-1: run cmd=echo "Targets:";
step-2: run cmd=echo " make install - install goal locally";
step-3: run cmd=echo " make dev - install in development mode";
step-4: run cmd=echo " make test - run tests";
step-5: run cmd=echo " make build - build package for PyPI";
step-6: run cmd=echo " make publish - build and upload to PyPI";
step-7: run cmd=echo " make clean - remove build artifacts";
step-8: run cmd=echo " make push - use goal to push changes";
step-9: run cmd=echo " make benchmark - run performance benchmark";
step-10: run cmd=echo " make benchmark-ci - benchmark for CI (plain, threshold)";
step-11: run cmd=echo " make benchmark-json - benchmark JSON output";
step-12: run cmd=echo " make deps-cache - download all deps to local wheel cache";
step-13: run cmd=echo " make deps-lock - freeze current versions to requirements-lock.txt";
step-14: run cmd=echo " make test-offline - run tests without network (uses cached deps)";
}
deploy {
target: makefile;
}
environment[name="local"] {
runtime: makefile;
env_file: ".env";
}
workflow[name="all"] {
trigger: "manual";
step-1: run cmd=taskfile run install;
step-2: run cmd=taskfile run lint;
step-3: run cmd=taskfile run test;
}
workflow[name="lint"] {
trigger: "manual";
step-1: run cmd=ruff check .;
}
workflow[name="fmt"] {
trigger: "manual";
step-1: run cmd=ruff format .;
}
workflow[name="format"] {
trigger: "manual";
step-1: run cmd=ruff format .;
}