forked from drt-hub/drt
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
79 lines (63 loc) · 2.69 KB
/
Copy pathMakefile
File metadata and controls
79 lines (63 loc) · 2.69 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
.PHONY: install dev lint fmt test clean sync-skills check-skills check-i18n sync-version release-check topics sync-labels
# ── Development ────────────────────────────────────────────────────────────────
install:
uv pip install -e .
dev:
uv pip install -e ".[dev,bigquery]"
lint:
ruff check drt tests
mypy drt
fmt:
ruff format drt tests
ruff check --fix drt tests
test:
pytest
clean:
rm -rf dist build .eggs *.egg-info
find . -type d -name __pycache__ -exec rm -rf {} +
find . -type d -name .pytest_cache -exec rm -rf {} +
# ── SSoT automation ────────────────────────────────────────────────────────────
sync-skills: ## Copy skills/drt/skills/*/SKILL.md → .claude/commands/ (strip frontmatter)
@for skill in skills/drt/skills/*/SKILL.md; do \
name=$$(basename $$(dirname $$skill)); \
awk 'BEGIN{skip=0} /^---$$/{skip++;next} skip<2{next} {print}' $$skill \
> .claude/commands/$$name.md; \
echo " synced $$name"; \
done
@echo "✓ Skills synced (maintainer-only commands untouched)"
check-skills: ## Verify .claude/commands/ matches skills (CI gate)
@fail=0; \
for skill in skills/drt/skills/*/SKILL.md; do \
name=$$(basename $$(dirname $$skill)); \
expected=$$(awk 'BEGIN{skip=0} /^---$$/{skip++;next} skip<2{next} {print}' $$skill); \
actual=$$(cat .claude/commands/$$name.md 2>/dev/null || echo ""); \
if [ "$$expected" != "$$actual" ]; then \
echo "✗ $$name.md is out of sync with SKILL.md"; \
fail=1; \
fi; \
done; \
if [ $$fail -eq 1 ]; then \
echo "Run 'make sync-skills' to fix."; \
exit 1; \
fi; \
echo "✓ All skills in sync"
check-i18n: ## Check if translated *.{lang}.md files are in sync with English base
@bash scripts/check-i18n-sync.sh
sync-version: ## Propagate version from pyproject.toml to all plugin JSONs
@python3 scripts/sync-version.py
release-check: ## Run automated release consistency checks
@bash scripts/release-check.sh
# ── Repo maintenance (maintainer only) ───────────────────────────────────────
topics: ## Sync repository topics to GitHub
gh repo edit drt-hub/drt \
--add-topic reverse-etl \
--add-topic dbt \
--add-topic bigquery \
--add-topic duckdb \
--add-topic python \
--add-topic cli \
--add-topic etl \
--add-topic data-engineering \
--add-topic postgres
sync-labels: ## Trigger label sync workflow on GitHub
gh workflow run sync-labels.yml --repo drt-hub/drt