Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adapt scripts to scala/dotty.epfl.ch not lampepfl/dotty-website #21604

Merged
merged 1 commit into from
Sep 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -710,7 +710,7 @@ jobs:
git config --global --add safe.directory /__w/scala3/scala3
./project/scripts/genDocs -doc-snapshot

- name: Deploy Website to dotty-website
- name: Deploy Website to https://dotty.epfl.ch
uses: peaceiris/actions-gh-pages@v4
with:
personal_token: ${{ secrets.DOTTYBOT_TOKEN }}
Expand Down
8 changes: 4 additions & 4 deletions project/scripts/genDocs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ shopt -s extglob # needed for rm everything but x
echo "Working directory: $PWD"

GENDOC_EXTRA_ARGS=$@
GIT_HEAD=$(git rev-parse HEAD) # save current head for commit message in gh-pages
GIT_HEAD=$(git rev-parse HEAD) # save current head for commit message in scala/dotty.epfl.ch
PREVIOUS_SNAPSHOTS_DIR="$PWD/../prev_snapshots"
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >& /dev/null && pwd)"
SITE_OUT_DIR="$PWD/docs/_site"
Expand All @@ -16,9 +16,9 @@ if [ -d "$PREVIOUS_SNAPSHOTS_DIR" ]; then
fi

mkdir -pv "$PREVIOUS_SNAPSHOTS_DIR"
git remote add doc-remote "https://github.com/lampepfl/dotty-website.git"
git fetch doc-remote gh-pages
git checkout gh-pages
git remote add doc-remote "https://github.com/scala/dotty.epfl.ch.git"
git fetch doc-remote main
git checkout doc-remote/main
(cp -vr [03].*/ "$PREVIOUS_SNAPSHOTS_DIR"; true) # Don't fail if no `3.*` found to copy
git checkout "$GIT_HEAD"

Expand Down
Loading