-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathMakefile
More file actions
139 lines (114 loc) · 4.78 KB
/
Copy pathMakefile
File metadata and controls
139 lines (114 loc) · 4.78 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
# EDS 217 pre-launch. One place for everything you run between now and Day 1.
#
# make this list
# make status what is left on the punch list
# make next the next item you can start
# make board rebuild the dashboard and open it
# make preview live preview of the whole site
# make preview PAGE=day3 live preview of one page
# make render render the pages whose source changed
# make render-full rebuild every page, for a layout or _quarto.yml change
# make verify render, run every cell, resolve every URL, run the gates
# make publish guarded push to both remotes
#
# Every target runs in the eds217_2026 conda environment. Nothing here commits
# or pushes except `publish`, which asks first.
SHELL := /bin/bash
# Every python target runs inside eds217_2026. See tools/run.sh for why.
RUN := bash tools/run.sh
PAGE ?=
DAY ?=
.DEFAULT_GOAL := help
.PHONY: help status next show board dashboard preview render render-full verify verify-live \
gates cells cache check certify publish env clean-preview
help:
@echo ""
@echo " EDS 217 pre-launch"
@echo ""
@echo " Where things stand"
@echo " make status the punch list, open items only"
@echo " make status-all the punch list, everything"
@echo " make next the next item you can start, in full"
@echo " make show ID=D6 one item in full"
@echo " make board rebuild the dashboard and open it"
@echo ""
@echo " Reading and editing"
@echo " make preview live preview (writes into docs/)"
@echo " make preview PAGE=day3 live preview of one page"
@echo ""
@echo " Verifying"
@echo " make check run every punch-list verification"
@echo " make gates the six quality gates"
@echo " make cells execute every code cell in the 2026 corpus"
@echo " make keys check every key against its own output"
@echo " make keys PAIR=eod-day3 check one handout and key pair"
@echo " make keys-tasks key structure only, no execution"
@echo " make cache confirm every data URL resolves"
@echo " make render render only the pages whose source changed"
@echo " make render-full rebuild every page (layout or _quarto.yml changes)"
@echo " make verify render plus all of the above"
@echo " make verify-live check the published site"
@echo ""
@echo " Signing off and publishing"
@echo " make certify ID=D6 NOTE=\"what you confirmed\""
@echo " make publish guarded push to origin and live"
@echo ""
@echo " When git says another process is running"
@echo " make unlock clear the lock files a session left behind"
@echo ""
status:
@$(RUN) python tools/prelaunch.py status
status-all:
@$(RUN) python tools/prelaunch.py status --all
next:
@$(RUN) python tools/prelaunch.py next
show:
@test -n "$(ID)" || { echo "usage: make show ID=D6"; exit 1; }
@$(RUN) python tools/prelaunch.py show $(ID)
dashboard:
@$(RUN) python tools/prelaunch.py dashboard
board:
@$(RUN) python tools/prelaunch.py dashboard --open
preview:
@bash tools/preview.sh $(PAGE)
render:
@$(RUN) python build_docs.py
render-full:
@$(RUN) python build_docs.py --full
check:
@$(RUN) python tools/prelaunch.py check --all
@$(RUN) python tools/prelaunch.py dashboard
gates:
@bash tools/gates.sh
cells:
@$(RUN) python tools/run_cells.py $$($(RUN) python tools/prelaunch_checks.py --render-set | grep '\.qmd$$')
cache:
@$(RUN) python tools/warm_cache.py
keys:
@$(RUN) python tools/key_check.py $(PAIR)
keys-tasks:
@$(RUN) python tools/key_check.py --tasks-only
verify:
@bash tools/render-check.sh
verify-live:
@$(RUN) python tools/prelaunch_checks.py d8_live_site
certify:
@test -n "$(ID)" || { echo "usage: make certify ID=D6 NOTE=\"...\""; exit 1; }
@test -n "$(NOTE)" || { echo "a sign-off needs a NOTE saying what you confirmed"; exit 1; }
@$(RUN) python tools/prelaunch.py certify $(ID) -n "$(NOTE)"
@$(RUN) python tools/prelaunch.py dashboard
unlock:
@bash tools/unlock.sh
publish:
@bash tools/publish.sh
# The env label goes through the wrapper like everything else. Echoed from the
# outer shell, it named whatever environment happened to invoke make while the
# versions below it came from eds217_2026, so the one target whose job is to
# name the environment named the wrong one.
env:
@$(RUN) bash -c 'echo "conda env: $${CONDA_DEFAULT_ENV:-none}"'
@$(RUN) python -c "import sys, pandas, numpy, matplotlib, seaborn; \
print('python', sys.version.split()[0]); \
print('pandas', pandas.__version__); print('numpy', numpy.__version__); \
print('matplotlib', matplotlib.__version__); print('seaborn', seaborn.__version__)"
@quarto --version | sed 's/^/quarto /'