Skip to content

Commit 3f97a87

Browse files
authored
Merge pull request #13140 from BarkingBad/scaladoc/markdowns-preprocessor
Scaladoc markdown preprocessor
2 parents 688c2ca + b8e4571 commit 3f97a87

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+558
-563
lines changed

.github/workflows/ci.yaml

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -470,9 +470,12 @@ jobs:
470470
if: "(github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.repository == 'lampepfl/dotty'"
471471
env:
472472
NIGHTLYBUILD: yes
473-
BOT_TOKEN: ${{ secrets.BOT_TOKEN }} # If you need to change this:
474-
# Generate one at https://github.com/settings/tokens
475-
# Make sure you have the write permissions to the repo: https://github.com/lampepfl/dotty-website
473+
DOTTY_WEBSITE_BOT_TOKEN: ${{ secrets.BOT_TOKEN }} # If you need to change this:
474+
# Generate one at https://github.com/settings/tokens
475+
# Make sure you have the write permissions to the repo: https://github.com/lampepfl/dotty-website
476+
DOCS_SCALALANG_BOT_TOKEN: ${{ secrets.DOCS_SCALALANG_BOT_TOKEN }} # If you need to change this:
477+
# Generate one at https://github.com/settings/tokens
478+
# Make sure you have the write permissions to the repo: https://github.com/scala/docs.scala-lang
476479

477480
steps:
478481
- name: Reset existing repo
@@ -494,14 +497,26 @@ jobs:
494497
run: |
495498
./project/scripts/genDocs -doc-snapshot
496499
497-
- name: Deploy Website
500+
- name: Deploy Website to dotty-website
498501
uses: peaceiris/actions-gh-pages@v3
499502
with:
500-
personal_token: ${{ secrets.BOT_TOKEN }}
503+
personal_token: ${{ env.DOTTY_WEBSITE_BOT_TOKEN }}
501504
publish_dir: docs/_site
502505
external_repository: lampepfl/dotty-website
503506
publish_branch: gh-pages
504507

508+
- name: Generate docs.scala-lang preprocessed files
509+
run: |
510+
./project/scripts/genDocsScalaLang
511+
512+
- name: Deploy Website to docs.scala-lang
513+
uses: peaceiris/actions-gh-pages@v3
514+
with:
515+
personal_token: ${{ env.DOCS_SCALALANG_BOT_TOKEN }}
516+
publish_dir: docsScalaLang
517+
external_repository: BarkingBad/docs.scala-lang
518+
publish_branch: dev
519+
505520
publish_release:
506521
runs-on: [self-hosted, Linux]
507522
container:

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,3 +105,7 @@ compiler/test-coursier/run/*.jar
105105

106106
# Docs
107107
docs-for-dotty-page/*
108+
109+
# docs.scala-lang deplyment temp dir
110+
docsScalaLang/
111+
docs/_site/

docs/docs/reference/changed-features.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
title: "Other Changed Features"
33
type: chapter
4-
num: 51
5-
previous-page: /scala3/reference/other-new-features/type-test
4+
num: 52
5+
previous-page: /scala3/reference/other-new-features/experimental-defs
66
next-page: /scala3/reference/changed-features/numeric-literals
77
---
88

docs/docs/reference/changed-features/compiler-plugins.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Changes in Compiler Plugins"
33
type: section
4-
num: 67
4+
num: 68
55
previous-page: /scala3/reference/changed-features/eta-expansion
66
next-page: /scala3/reference/changed-features/lazy-vals-init
77
---

docs/docs/reference/changed-features/eta-expansion.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Automatic Eta Expansion"
33
type: section
4-
num: 66
4+
num: 67
55
previous-page: /scala3/reference/changed-features/pattern-matching
66
next-page: /scala3/reference/changed-features/compiler-plugins
77
---

docs/docs/reference/changed-features/implicit-conversions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Implicit Conversions"
33
type: section
4-
num: 60
4+
num: 61
55
previous-page: /scala3/reference/changed-features/implicit-resolution
66
next-page: /scala3/reference/changed-features/overload-resolution
77
---

docs/docs/reference/changed-features/implicit-resolution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Changes in Implicit Resolution"
33
type: section
4-
num: 59
4+
num: 60
55
previous-page: /scala3/reference/changed-features/type-inference
66
next-page: /scala3/reference/changed-features/implicit-conversions
77
---

docs/docs/reference/changed-features/imports.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Imports"
33
type: section
4-
num: 56
4+
num: 57
55
previous-page: /scala3/reference/changed-features/wildcards
66
next-page: /scala3/reference/changed-features/type-checking
77
---

docs/docs/reference/changed-features/lazy-vals-init.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Lazy Vals Initialization
33
type: section
4-
num: 68
4+
num: 69
55
previous-page: /scala3/reference/changed-features/compiler-plugins
66
next-page: /scala3/reference/changed-features/main-functions
77
---

docs/docs/reference/changed-features/main-functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Main Methods"
33
type: section
4-
num: 69
4+
num: 70
55
previous-page: /scala3/reference/changed-features/lazy-vals-init
66
next-page: /scala3/reference/dropped-features
77
---

docs/docs/reference/changed-features/match-syntax.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Match Expressions"
33
type: section
4-
num: 62
4+
num: 63
55
previous-page: /scala3/reference/changed-features/overload-resolution
66
next-page: /scala3/reference/changed-features/vararg-splices
77
---
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
22
title: "Numeric Literals"
33
type: section
4-
num: 52
4+
num: 53
55
previous-page: /scala3/reference/changed-features
66
next-page: /scala3/reference/changed-features/structural-types
77
---
88

9-
[Document was moved](../experimental/numeric-literals.md)
9+
[Document was moved](../experimental/numeric-literals.md)

docs/docs/reference/changed-features/operators.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Rules for Operators"
33
type: section
4-
num: 54
4+
num: 55
55
previous-page: /scala3/reference/changed-features/structural-types
66
next-page: /scala3/reference/changed-features/wildcards
77
---

docs/docs/reference/changed-features/overload-resolution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Changes in Overload Resolution"
33
type: section
4-
num: 61
4+
num: 62
55
previous-page: /scala3/reference/changed-features/implicit-conversions
66
next-page: /scala3/reference/changed-features/match-syntax
77
---

docs/docs/reference/changed-features/pattern-bindings.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Pattern Bindings"
33
type: section
4-
num: 64
4+
num: 65
55
previous-page: /scala3/reference/changed-features/vararg-splices
66
next-page: /scala3/reference/changed-features/pattern-matching
77
---

docs/docs/reference/changed-features/pattern-matching.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Option-less pattern matching"
33
type: section
4-
num: 65
4+
num: 66
55
previous-page: /scala3/reference/changed-features/pattern-bindings
66
next-page: /scala3/reference/changed-features/eta-expansion
77
---

docs/docs/reference/changed-features/structural-types.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Programmatic Structural Types"
33
type: section
4-
num: 53
4+
num: 54
55
previous-page: /scala3/reference/changed-features/numeric-literals
66
next-page: /scala3/reference/changed-features/operators
77
---

docs/docs/reference/changed-features/type-checking.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Changes in Type Checking"
33
type: section
4-
num: 57
4+
num: 58
55
previous-page: /scala3/reference/changed-features/imports
66
next-page: /scala3/reference/changed-features/type-inference
77
---

docs/docs/reference/changed-features/type-inference.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Changes in Type Inference"
33
type: section
4-
num: 58
4+
num: 59
55
previous-page: /scala3/reference/changed-features/type-checking
66
next-page: /scala3/reference/changed-features/implicit-resolution
77
---

docs/docs/reference/changed-features/vararg-splices.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Vararg Splices"
33
type: section
4-
num: 63
4+
num: 64
55
previous-page: /scala3/reference/changed-features/match-syntax
66
next-page: /scala3/reference/changed-features/pattern-bindings
77
---

docs/docs/reference/changed-features/wildcards.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Wildcard Arguments in Types
33
type: section
4-
num: 55
4+
num: 56
55
previous-page: /scala3/reference/changed-features/operators
66
next-page: /scala3/reference/changed-features/imports
77
---
@@ -49,4 +49,4 @@ These rules make it possible to cross build between Scala 2 using the kind proje
4949
There is also a migration path for users that want a one-time transition to syntax with `_` as a type parameter placeholder.
5050
With option `-Ykind-projector:underscores` Scala 3 will regard `_` as a type parameter placeholder, leaving `?` as the only syntax for wildcards.
5151

52-
To cross-compile with old Scala 2 sources, while using `_` a placeholder, you must use options `-Xsource:3 -P:kind-projector:underscore-placeholders` together with a recent version of kind-projector (`0.13` and higher) and most recent versions of Scala 2 (`2.13.5` and higher and `2.12.14` and higher)
52+
To cross-compile with old Scala 2 sources, while using `_` a placeholder, you must use options `-Xsource:3 -P:kind-projector:underscore-placeholders` together with a recent version of kind-projector (`0.13` and higher) and most recent versions of Scala 2 (`2.13.5` and higher and `2.12.14` and higher)

docs/docs/reference/dropped-features.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped Features"
33
type: chapter
4-
num: 70
4+
num: 71
55
previous-page: /scala3/reference/changed-features/main-functions
66
next-page: /scala3/reference/dropped-features/delayed-init
77
---

docs/docs/reference/dropped-features/auto-apply.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Auto-Application"
33
type: section
4-
num: 83
4+
num: 84
55
previous-page: /scala3/reference/dropped-features/symlits
66
next-page: /scala3/reference/dropped-features/weak-conformance
77
---

docs/docs/reference/dropped-features/class-shadowing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Class Shadowing"
33
type: section
4-
num: 79
4+
num: 80
55
previous-page: /scala3/reference/dropped-features/early-initializers
66
next-page: /scala3/reference/dropped-features/limit22
77
---

docs/docs/reference/dropped-features/delayed-init.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: DelayedInit"
33
type: section
4-
num: 71
4+
num: 72
55
previous-page: /scala3/reference/dropped-features
66
next-page: /scala3/reference/dropped-features/macros
77
---

docs/docs/reference/dropped-features/do-while.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Do-While"
33
type: section
4-
num: 75
4+
num: 76
55
previous-page: /scala3/reference/dropped-features/type-projection
66
next-page: /scala3/reference/dropped-features/procedure-syntax
77
---

docs/docs/reference/dropped-features/early-initializers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Early Initializers"
33
type: section
4-
num: 78
4+
num: 79
55
previous-page: /scala3/reference/dropped-features/package-objects
66
next-page: /scala3/reference/dropped-features/class-shadowing
77
---

docs/docs/reference/dropped-features/existential-types.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Existential Types"
33
type: section
4-
num: 73
4+
num: 74
55
previous-page: /scala3/reference/dropped-features/macros
66
next-page: /scala3/reference/dropped-features/type-projection
77
---

docs/docs/reference/dropped-features/limit22.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Limit 22"
33
type: section
4-
num: 80
4+
num: 81
55
previous-page: /scala3/reference/dropped-features/class-shadowing
66
next-page: /scala3/reference/dropped-features/xml
77
---

docs/docs/reference/dropped-features/macros.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Scala 2 Macros"
33
type: section
4-
num: 72
4+
num: 73
55
previous-page: /scala3/reference/dropped-features/delayed-init
66
next-page: /scala3/reference/dropped-features/existential-types
77
---

docs/docs/reference/dropped-features/package-objects.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Package Objects"
33
type: section
4-
num: 77
4+
num: 78
55
previous-page: /scala3/reference/dropped-features/procedure-syntax
66
next-page: /scala3/reference/dropped-features/early-initializers
77
---

docs/docs/reference/dropped-features/procedure-syntax.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Procedure Syntax"
33
type: section
4-
num: 76
4+
num: 77
55
previous-page: /scala3/reference/dropped-features/do-while
66
next-page: /scala3/reference/dropped-features/package-objects
77
---

docs/docs/reference/dropped-features/symlits.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Symbol Literals"
33
type: section
4-
num: 82
4+
num: 83
55
previous-page: /scala3/reference/dropped-features/xml
66
next-page: /scala3/reference/dropped-features/auto-apply
77
---

docs/docs/reference/dropped-features/this-qualifier.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: private[this] and protected[this]"
33
type: section
4-
num: 85
4+
num: 86
55
previous-page: /scala3/reference/dropped-features/weak-conformance
66
next-page: /scala3/reference/dropped-features/wildcard-init
77
---

docs/docs/reference/dropped-features/type-projection.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: General Type Projection"
33
type: section
4-
num: 74
4+
num: 75
55
previous-page: /scala3/reference/dropped-features/existential-types
66
next-page: /scala3/reference/dropped-features/do-while
77
---

docs/docs/reference/dropped-features/weak-conformance.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Weak Conformance"
33
type: section
4-
num: 84
4+
num: 85
55
previous-page: /scala3/reference/dropped-features/auto-apply
66
next-page: /scala3/reference/dropped-features/this-qualifier
77
---

docs/docs/reference/dropped-features/wildcard-init.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: Wildcard Initializer"
33
type: section
4-
num: 86
4+
num: 87
55
previous-page: /scala3/reference/dropped-features/this-qualifier
66
next-page: /scala3/reference/syntax
77
---

docs/docs/reference/dropped-features/xml.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "Dropped: XML Literals"
33
type: section
4-
num: 81
4+
num: 82
55
previous-page: /scala3/reference/dropped-features/limit22
66
next-page: /scala3/reference/dropped-features/symlits
77
---

docs/docs/reference/language-versions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Language Versions"
33
type: chapter
44
description: This page lists the different flavours of language supported by the Scala 3 compiler.
5-
num: 100
5+
num: 101
66
previous-page: overview
77
---
88

0 commit comments

Comments
 (0)