Skip to content

Add script for docs preprocessing for static site #13587

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

Merged
merged 4 commits into from
Sep 30, 2021

Conversation

BarkingBad
Copy link
Contributor

No description provided.

@BarkingBad BarkingBad force-pushed the scaladoc/move-docs branch 3 times, most recently from 4b70570 to c9ad3d2 Compare September 22, 2021 15:10
@BarkingBad
Copy link
Contributor Author

To review the PR it's good to filter out md files like this:
obraz
The only interesting md file is docs/README.md file explaining why we have two types of docs there and how to build documentation. The goal is to port all the files to the docs.scala-lang so the number of whitelisted (or later blacklisted) directories should change and eventually all files will be preprocessed.

@BarkingBad
Copy link
Contributor Author

https://scala3doc.virtuslab.com/pr-move-docs/scala3/docs/index.html

From static site point of view everything is working correctly.

@BarkingBad
Copy link
Contributor Author

If you copy the docs/docs/reference into _scala3-reference and docs/docs/usage/scaladoc into _overviews/scala3-scaladoc you can generate the docs.scala-lang page with no issues (actually these files has been backported from docs.scala-lang). Of course these files will be preprocessed, but for now it is sufficient to prove that they work with docs.scala-lang.

import scala.io.{ Codec, Source }
import scala.collection.JavaConverters._

val inputDir = FileSystems.getDefault.getPath("docs")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need some comment what this script does and where is used here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added in docs/README.md

@BarkingBad BarkingBad merged commit 01c70a2 into scala:master Sep 30, 2021
@BarkingBad BarkingBad deleted the scaladoc/move-docs branch September 30, 2021 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants