Skip to content

Commit

Permalink
Integrate Docusaurus building
Browse files Browse the repository at this point in the history
  • Loading branch information
eed3si9n committed Jan 21, 2024
1 parent 06e5acb commit 4b85f01
Show file tree
Hide file tree
Showing 7 changed files with 8,419 additions and 14,668 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ jobs:
distribution: 'adopt'
java-version: '11'
cache: 'sbt'
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 20

- name: Build and test
run: |
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,15 @@ This website is built using [Docusaurus](https://docusaurus.io/), a modern stati
### Local Development

```
$ npm start
$ yarn start
```

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.

### Build

```
$ npm run build
$ yarn run build
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.
Expand Down
21 changes: 1 addition & 20 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,12 @@ ThisBuild / scalafmtOnCompile := true

lazy val root = (project in file("."))
.enablePlugins(
(if (!isBetaBranch) Seq(ParadoxSitePlugin) else Seq()) ++
(if (!isBetaBranch) Seq(DocusaurusSitePlugin) else Seq()) ++
Seq(LowTechSnippetPamfletPlugin, ScriptedPlugin): _*
)
.settings(
name := "website",
siteEmail := "eed3si9n" + "@gmail.com",
// Landing
Compile / paradox / sourceDirectory := baseDirectory.value / "src" / "landing",
Compile / paradoxTheme / sourceDirectory := (Compile / paradox / sourceDirectory).value / "_template",
paradoxProperties ++= Map(
"sbtVersion" -> Docs.targetSbtFullVersion,
"windowsBuild" -> Docs.sbtWindowsBuild,
"sbtVersionForScalaDoc" -> Docs.sbtVersionForScalaDoc,
"scala3ExampleVersion" -> Docs.scala3ExampleVersion,
),
Compile / paradoxRoots := List(
"404.html",
"community.html",
"cookie.html",
"documentation.html",
"download.html",
"index.html",
"learn.html",
"thank-you.html",
),
// Reference
Pamflet / sourceDirectory := baseDirectory.value / "src" / "reference",
Pamflet / siteSubdirName := s"""$targetSbtBinaryVersion/docs""",
Expand Down
2 changes: 1 addition & 1 deletion docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const config = {
organizationName: 'sbt', // Usually your GitHub org/user name.
projectName: 'website', // Usually your repo name.

onBrokenLinks: 'throw',
onBrokenLinks: 'warn',
onBrokenMarkdownLinks: 'warn',

// Even if you don't use internationalization, you can use this field to set
Expand Down
Loading

0 comments on commit 4b85f01

Please sign in to comment.