File tree Expand file tree Collapse file tree 3 files changed +18
-14
lines changed
Expand file tree Collapse file tree 3 files changed +18
-14
lines changed Original file line number Diff line number Diff line change 1919 runs-on : ubuntu-latest
2020 steps :
2121 - uses : actions/checkout@v3
22+ - uses : actions/setup-python@v5
2223 - name : Build
2324 run : make
2425 - name : Deploy
Original file line number Diff line number Diff line change 1- out
1+ /out
2+ /venv
Original file line number Diff line number Diff line change @@ -5,18 +5,20 @@ OUT_DIR ?= out
55
66all : $(OUT_DIR ) /index.html validator
77
8- $(OUT_DIR ) /index.html : index.bs $(OUT_DIR )
9- @ (HTTP_STATUS=$$ (curl https://api.csswg.org/bikeshed/ \
10- --output $@ \
11- --write-out '%{http_code}' \
12- --header 'Accept: text/plain, text/html' \
13- -F die-on=warning \
14- -F file=@$<) && \
15- [[ "$$HTTP_STATUS" -eq "200" ]]) || ( \
16- echo ""; cat $@; echo ""; \
17- rm $@; \
18- exit 22 \
19- );
8+ venv-marker := venv/.make
9+ bikeshed := venv/bin/bikeshed
10+ venv : $(venv-marker )
11+
12+ $(venv-marker ) : Makefile
13+ python3 -m venv venv
14+ @touch $@
15+
16+ $(bikeshed ) : $(venv-marker ) Makefile
17+ venv/bin/pip install $(notdir $@ )
18+ @touch $@
19+
20+ $(OUT_DIR ) /index.html : index.bs $(OUT_DIR ) $(bikeshed )
21+ $(bikeshed ) --die-on=warning spec $< $@
2022
2123validator : $(OUT_DIR ) /validate-headers.html $(OUT_DIR ) /validate-headers.js $(OUT_DIR ) /filters.html $(OUT_DIR ) /filters-main.js
2224
@@ -34,7 +36,7 @@ ts/dist/header-validator/index.js ts/dist/header-validator/filters-main.js: ts/p
3436 @ npm run pack --prefix ./ts
3537
3638clean :
37- @ rm -rf $(OUT_DIR )
39+ @ rm -rf $(OUT_DIR ) venv
3840
3941$(OUT_DIR ) /filters.html : ts/src/header-validator/filters.html $(OUT_DIR )
4042 @ cp $< $@
You can’t perform that action at this time.
0 commit comments