~zainab/blog

583daf53b6f75389519d0f5481620fb5e73b73fd — zainab-ali 7 months ago d23c822
Remove coursier timeout hack
1 files changed, 8 insertions(+), 10 deletions(-)

M nix/mdoc.bash
M nix/mdoc.bash => nix/mdoc.bash +8 -10
@@ 7,13 7,11 @@ set -ex
fs2=$(cs fetch -p co.fs2:fs2-core_3:3.1.3)
catseffect=$(cs fetch -p org.typelevel:cats-effect_3:3.3.2)

# FIXME: coursier doesn't finish when there is an `error` snippet in mdoc
# Hack around this by timing out once we think it's finished
timeout 1m cs launch org.scalameta:mdoc_3:2.2.23 -- \
	 --classpath $fs2 \
	 --in src/chapters/fs2/snippets.md \
	 --out src/chapters/fs2/snippets.out.md || true
timeout 3m cs launch org.scalameta:mdoc_3:2.2.23 -- \
	 --classpath $catseffect \
	 --in src/chapters/2022-02-12-cats-effect-ioruntime/snippets.md \
	 --out src/chapters/2022-02-12-cats-effect-ioruntime/snippets.out.md || true
cs launch org.scalameta:mdoc_3:2.2.23 -- \
   --classpath $fs2 \
   --in src/chapters/fs2/snippets.md \
   --out src/chapters/fs2/snippets.out.md
cs launch org.scalameta:mdoc_3:2.2.23 -- \
   --classpath $catseffect \
   --in src/chapters/2022-02-12-cats-effect-ioruntime/snippets.md \
   --out src/chapters/2022-02-12-cats-effect-ioruntime/snippets.out.md