Skip to content

Freeze the static site #13550

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

Closed
wants to merge 1 commit into from
Closed
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
3 changes: 2 additions & 1 deletion project/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1419,7 +1419,8 @@ object Build {
"https://scala-lang.org/api/versions.json",
"-Ydocument-synthetic-types",
s"-snippet-compiler:${dottyLibRoot}/scala/quoted=compile"
) ++ (if (justAPI) Nil else Seq("-siteroot", "docs", "-Yapi-subdirectory")))
)
)

if (dottyJars.isEmpty) Def.task { streams.value.log.error("Dotty lib wasn't found") }
else if (justAPI) generateDocTask
Expand Down
4 changes: 2 additions & 2 deletions project/scripts/genDocs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ 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
(cp -vr [03].*/ "$PREVIOUS_SNAPSHOTS_DIR"; true) # Don't fail if no `3.*` found to copy
(cp -vr 0.*/ 3.*/ docs/ blog/ index.html "$PREVIOUS_SNAPSHOTS_DIR"; true) # Don't fail if no `3.*` found to copy
git checkout "$GIT_HEAD"

### Generate the current snapshot of the website ###
Expand All @@ -34,5 +34,5 @@ if [ ! -d "$SITE_OUT_DIR" ]; then
fi

### Move previous versions' snapshots to _site ###
mv -v "$PREVIOUS_SNAPSHOTS_DIR"/* "$SITE_OUT_DIR"
mv -vf "$PREVIOUS_SNAPSHOTS_DIR"/* "$SITE_OUT_DIR"
rm -rf "$PREVIOUS_SNAPSHOTS_DIR"