Skip to content

Commit

Permalink
Consolidate blog/ and docs/ under website/ folder (#4510)
Browse files Browse the repository at this point in the history
  • Loading branch information
lihaoyi authored Feb 8, 2025
1 parent c1fe9ea commit 8d73650
Show file tree
Hide file tree
Showing 177 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
- uses: actions/checkout@v4
with: { fetch-depth: 1 }

- run: ./mill -i docs.fastPages + docs.checkBrokenLinks
- run: ./mill -i website.fastPages + website.checkBrokenLinks

cross-plat:
if: (github.event.action == 'ready_for_review') || (github.event.pull_request.draft == false)
Expand Down
2 changes: 1 addition & 1 deletion build.mill
Original file line number Diff line number Diff line change
Expand Up @@ -766,7 +766,7 @@ def validate(): Command[Unit] = {
Task.Command {
Task.sequence(tasks)()
mill.scalalib.scalafmt.ScalafmtModule.checkFormatAll(Tasks(sources))()
build.docs.localPages()
build.website.localPages()
()
}
}
Expand Down
6 changes: 3 additions & 3 deletions ci/mill-bootstrap.patch
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ index 67d3f94c143..98733778894 100644
()
}

diff --git a/docs/package.mill b/docs/package.mill
diff --git a/website/package.mill b/website/package.mill
index d558389312e..11f8e5c3ce9 100644
--- a/docs/package.mill
+++ b/docs/package.mill
--- a/website/package.mill
+++ b/website/package.mill
@@ -40,8 +40,8 @@ object `package` extends RootModule {
private val antoraExe = if (scala.util.Properties.isWin) "antora.cmd" else "antora"
def npmBase: T[os.Path] = Task(persistent = true) { Task.dest }
Expand Down
4 changes: 2 additions & 2 deletions ci/publish-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
set -eu

# Build the pages
./mill -i docs.githubPages
./mill -i website.githubPages

# Prepare ssh-key for git actions
echo $REPO_DEPLOY_KEY | base64 --decode > deploy_key
Expand All @@ -24,7 +24,7 @@ git worktree add -b gh-pages gh-pages origin/gh-pages

# we want to keep history, so we prepare a new commit
rm -r ${PAGES_REPO}/*
cp -r out/docs/githubPages.dest/site/* ${PAGES_REPO}/
cp -r out/website/githubPages.dest/site/* ${PAGES_REPO}/
touch ${PAGES_REPO}/.nojekyll

cd $PAGES_REPO
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions docs/package.mill → website/package.mill
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package build.docs
package build.website
import org.jsoup._
import mill.util.Jvm
import mill._, scalalib._
Expand Down Expand Up @@ -71,7 +71,7 @@ object `package` extends RootModule {
PathRef(workDir / "build/site")
}

def source0 = Task.Source(millSourcePath)
def source0 = Task.Source(millSourcePath / "docs")
def projectChangelog = Task.Source(Task.workspace / "changelog.adoc")
def source = Task {
os.copy(source0().path, Task.dest, mergeFolders = true)
Expand Down Expand Up @@ -173,7 +173,7 @@ object `package` extends RootModule {

}

def supplementalFiles = Task.Source(millSourcePath / "supplemental-ui")
def supplementalFiles = Task.Source(millSourcePath / "docs" / "supplemental-ui")

/**
* The doc root ready to be built by antora for the current branch.
Expand Down Expand Up @@ -216,7 +216,7 @@ object `package` extends RootModule {
os.write.over(dest / "antora.yml", (lines ++ newLines).mkString("\n"))
}

def blogFolder0 = Task.Source(build.millSourcePath / "blog")
def blogFolder0 = Task.Source(millSourcePath / "blog")
def blogFolder = Task {
os.copy(blogFolder0().path, Task.dest, mergeFolders = true)
expandDiagramsInDirectoryAdocFile(Task.dest, mill.main.VisualizeModule.classpath().map(_.path))
Expand Down Expand Up @@ -244,7 +244,7 @@ object `package` extends RootModule {
"'" + _ + "'"
).mkString("[", ",", "]")}
| edit_url: false
| start_path: docs/antora
| start_path: website/antora
|
|${taggedSources.mkString("\n\n")}
|
Expand Down

0 comments on commit 8d73650

Please sign in to comment.