Skip to content

Commit 829fbe9

Browse files
committed
#2455: CI: fix documentation build
1 parent 6508404 commit 829fbe9

File tree

2 files changed

+26
-25
lines changed

2 files changed

+26
-25
lines changed

ci/build_cpp.sh

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,14 @@ set -ex
44

55
source_dir=${1}
66
build_dir=${2}
7+
target=${3:-install}
78

89
# Dump environment variables for easier debugging
910
env | sort
1011

1112
# Dependency versions, when fetched via git.
1213
checkpoint_rev=develop
1314

14-
if test "${VT_DOXYGEN_ENABLED:-0}" -eq 1
15-
then
16-
token=${3}
17-
else
18-
target=${3:-install}
19-
fi
20-
2115
if [ -z ${4} ]; then
2216
dashj=""
2317
else
@@ -186,20 +180,24 @@ if test "${VT_DOXYGEN_ENABLED:-0}" -eq 1
186180
then
187181
MCSS=$PWD/m.css
188182
GHPAGE=$PWD/DARMA-tasking.github.io
189-
git clone "https://${token}@github.com/DARMA-tasking/DARMA-tasking.github.io"
183+
git clone --depth=1 "https://x-access-token:${GITHUB_TOKEN}@github.com/DARMA-tasking/DARMA-tasking.github.io"
190184
git clone https://github.com/mosra/m.css
191185
cd m.css
192186
git checkout 699abdd5
193187
cd ../
194188

195189
"$MCSS/documentation/doxygen.py" Doxyfile-mcss
196-
cp -R docs "$GHPAGE"
197-
cd "$GHPAGE"
198-
git config --global user.email "[email protected]"
199-
git config --global user.name "Jonathan Lifflander"
200-
git add docs
201-
git commit --allow-empty -m "Update docs (auto-build)"
202-
git push origin master
190+
191+
if test "${GIT_BRANCH:-}" = "develop"
192+
then
193+
cp -R docs "$GHPAGE"
194+
cd "$GHPAGE"
195+
git config --global user.email "[email protected]"
196+
git config --global user.name "Jonathan Lifflander"
197+
git add docs
198+
git commit --allow-empty -m "Update docs (auto-build)"
199+
git push origin master
200+
fi
203201
elif test "${VT_CI_BUILD:-0}" -eq 1
204202
then
205203
# Generate output file with compilation warnings and errors

ci/docker/vt.dockerfile

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,17 @@ ARG CACHE_ID=${IMAGE}
4747

4848
ENV GIT_BRANCH=${GIT_BRANCH}
4949

50-
RUN --mount=type=cache,id=${CACHE_ID},target=/build/ccache \
51-
--mount=type=cache,id=BUILD-${CACHE_ID},target=/build/vt \
52-
--mount=target=/vt,rw \
53-
if [ "${VT_TEST_SPACK}" = "1" ]; then \
54-
apt update -y -q && apt install -y -q libssl-dev unzip && \
55-
/vt/ci/test_spack_package.sh; \
56-
else \
57-
/vt/ci/build_cpp.sh /vt /build && \
58-
/vt/ci/test_cpp.sh /vt /build && \
59-
/vt/ci/build_vt_sample.sh /vt /build; \
50+
RUN --mount=type=cache,id=${CACHE_ID},target=/build/ccache \
51+
--mount=type=cache,id=BUILD-${CACHE_ID},target=/build/vt \
52+
--mount=type=secret,id=GITHUB_TOKEN,env=GITHUB_TOKEN \
53+
--mount=target=/vt,rw \
54+
if [ "${VT_TEST_SPACK}" = "1" ]; then \
55+
apt update -y -q && apt install -y -q libssl-dev unzip && \
56+
/vt/ci/test_spack_package.sh; \
57+
elif [ "$VT_DOXYGEN_ENABLED" = "1" ]; then \
58+
/vt/ci/build_cpp.sh /vt /build; \
59+
else \
60+
/vt/ci/build_cpp.sh /vt /build && \
61+
/vt/ci/test_cpp.sh /vt /build && \
62+
/vt/ci/build_vt_sample.sh /vt /build; \
6063
fi

0 commit comments

Comments
 (0)