We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f1c2a76 commit 863008dCopy full SHA for 863008d
src/Makefile
@@ -13,7 +13,10 @@ all: $(FILES_HTML)
13
%.html: %.v %.glob jscoqdoc
14
./jscoqdoc $<
15
mv $(<F:.v=.html) $@
16
- sed -i 's/\.\//\.\.\//' $@
+ DIRNAME=$$(dirname $@ | sed 's|^\./||;s|/*$$||') ; \
17
+ DEPTH=$$(echo "$$DIRNAME" | awk -F/ '{if ($$1=="") print 0; else print NF}') ; \
18
+ PREFIX=$$(printf '../%.0s' $$(seq 1 $$DEPTH)) ; \
19
+ sed -i -E "s#(src|href)=\"\./#\1=\"$${PREFIX}#g" $@
20
21
%.glob: %.v
22
coqc $<
0 commit comments