Also fix the links in GHA

This commit is contained in:
Henrik Tjäder 2020-06-11 18:34:16 +00:00
parent ff4370944f
commit 9b7f1ac30c
2 changed files with 5 additions and 5 deletions

View file

@ -46,8 +46,8 @@ jobs:
run: | run: |
td=$(mktemp -d) td=$(mktemp -d)
cp -r target/doc $td/api cp -r target/doc $td/api
linkchecker $td/api/rtfm/ linkchecker $td/api/rtic/
linkchecker $td/api/cortex_m_rtfm_macros/ linkchecker $td/api/cortex_m_rtic_macros/
mdbook: mdbook:
runs-on: ubuntu-latest runs-on: ubuntu-latest

View file

@ -47,7 +47,7 @@ jobs:
cp -r target/doc $td/$latest/api cp -r target/doc $td/$latest/api
# sed fixes # sed fixes
sed 's|URL|rtfm/index.html|g' redirect.html > $td/$latest/api/index.html sed 's|URL|rtic/index.html|g' redirect.html > $td/$latest/api/index.html
sed 's|URL|0.5|g' redirect.html > $td/index.html sed 's|URL|0.5|g' redirect.html > $td/index.html
sed 's|URL|book/en|g' redirect.html > $td/$latest/index.html sed 's|URL|book/en|g' redirect.html > $td/$latest/index.html
@ -65,13 +65,13 @@ jobs:
mkdir -p $td/$prefix/book mkdir -p $td/$prefix/book
src=$(mktemp -d) src=$(mktemp -d)
curl -L https://github.com/rtfm-rs/cortex-m-rtfm/archive/v${ver}.tar.gz | tar xz --strip-components 1 -C $src curl -L https://github.com/rtic-rs/cortex-m-rtic/archive/v${ver}.tar.gz | tar xz --strip-components 1 -C $src
pushd $src pushd $src
rm -f .cargo/config rm -f .cargo/config
cargo doc || cargo doc --features timer-queue cargo doc || cargo doc --features timer-queue
cp -r target/doc $td/$prefix/api cp -r target/doc $td/$prefix/api
sed 's|URL|rtfm/index.html|g' $root/redirect.html > $td/$prefix/api/index.html sed 's|URL|rtic/index.html|g' $root/redirect.html > $td/$prefix/api/index.html
for lang in ${langs[@]}; do for lang in ${langs[@]}; do
( cd book/$lang && mdbook build ) ( cd book/$lang && mdbook build )
cp -r book/$lang/book $td/$prefix/book/$lang cp -r book/$lang/book $td/$prefix/book/$lang