Skip to content
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

Major docs overhaul (remove asciidoc and switch to MDX) #1397

Closed
wants to merge 19 commits into from
Closed
5 changes: 4 additions & 1 deletion .github/linters/.markdown-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,7 @@ MD013: false # Line length is usually not important and the 80 char limit is way
MD026: false # Trailing punctuation in header
MD033: false # Inline HTML is important for multilines and checkboxes within markdown tables
MD034: false # no-bare-urls Bare URL used
MD029: false # Markdown automatically calculates the ordered list order
MD029: false # Markdown automatically calculates the ordered list order
MD036: false # Emphasis used instead of a heading
MD028: false # No blank lines inside blockquote
MD053: false # Link and image reference definitions should be needed
5 changes: 4 additions & 1 deletion .github/linters/.stylelintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
"number-leading-zero": null,
"color-function-notation": null,
"no-descending-specificity": null,
"selector-class-pattern": null
"selector-class-pattern": null,
"scss/at-import-partial-extension": null,
"property-no-vendor-prefix": null,
"selector-pseudo-class-no-unknown": null
}
}
12 changes: 6 additions & 6 deletions .github/workflows/check-contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Contributor Updater

on:
push:
paths: [ content/asciidoc-pages/** ]
paths: [ content/mdx-docs/** ]
branches: [ main ]

concurrency:
Expand All @@ -26,8 +26,8 @@ jobs:
- run: |
# shellcheck disable=2043
for changed_file in ${{ steps.files.outputs.all }}; do
if [[ ${changed_file} =~ ^content/asciidoc.*.adoc ]]; then
current_authors=$(grep ':page-authors:' "${changed_file}" | sed -n -e 's/^.*page-authors: //p')
if [[ ${changed_file} =~ ^content/mdx-docs.*.md ]]; then
current_authors=$(grep '^authors:' "${changed_file}" | sed -n -e 's/^.*authors: //p')
contibutors=$(python3 .github/workflows/github-file-contributors.py --file "${changed_file}")
for contibutor in ${contibutors}; do
if ! echo "${current_authors}" | grep "${contibutor}"; then
Expand All @@ -44,10 +44,10 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.ADOPTIUM_TEMURIN_BOT_TOKEN }}
with:
title: "Update Asciidoc Contributors"
title: "Update MDX Contributors"
body: "This is an automatically generated pull request, it will be automatically merged if all the CI tests pass."
path: "content/asciidoc-pages/"
path: "content/mdx-docs/"
branch: "contributor_bot"
commit-message: "contributors: update asciidoc contributors"
commit-message: "contributors: update mdx contributors"
labels: automerge
author: "eclipse-temurin-bot <[email protected]>"
2 changes: 1 addition & 1 deletion .github/workflows/github-file-contributors.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
parser.add_argument(
"--file",
nargs="?",
default="content/asciidoc-pages/docs/marketplace-policy.adoc",
default="content/mdx-docs/docs/marketplace-policy/index.md",
help="specify the relative path to a particular file",
)
args = parser.parse_args()
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ jobs:

- name: Lint Code Base
uses: github/super-linter/slim@454ba4482ce2cd0c505bc592e83c06e1e37ade61 # v4.10.1

env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: main
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Markdown lint complains about the issue templates
FILTER_REGEX_EXCLUDE: .github/ISSUE_TEMPLATE/*
VALIDATE_NATURAL_LANGUAGE: false
VALIDATE_YAML: false
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The main branch contains the source code necessary for development. The producti

## Tech Stack

This is is a Node.js / npm driven stack with AsciiDoc used for static content and Gatsby as the rendering engine etc.
This is is a Node.js / npm driven stack with MDX used for static content and Gatsby as the rendering engine etc.

## How to develop locally

Expand All @@ -20,7 +20,7 @@ This assumes you already have Node.js and npm installed. Node.js version 18 or a
npm install --legacy-peer-deps
```

1. Start the site up. Gatsby will build all of the various parts of the site (Asciidoc etc). Note that this command takes some time to execute.
1. Start the site up. Gatsby will build all of the various parts of the site (MDX etc). Note that this command takes some time to execute.

```shell
npm start
Expand All @@ -36,7 +36,7 @@ This assumes you already have Node.js and npm installed. Node.js version 18 or a

## Configuring the build

`gatsby-config.js` is effectively your build script and `gatsby-node.js` is where the Asciidoc rendering takes place.
`gatsby-config.js` is effectively your build script and `gatsby-node.js` is where the MDX rendering takes place.

## How to contribute

Expand Down
10 changes: 10 additions & 0 deletions babel.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,15 @@
"presets": [
[ "@babel/preset-env", { "targets": { "node": true } } ],
[ "@babel/preset-react" ]
],
"plugins": [
[
"prismjs",
{
"languages": ["dockerfile", "java", "js", "css", "yaml", "bash", "batch", "markup", "json", "powershell"],
"plugins": [],
"css": false
}
]
]
}
2 changes: 1 addition & 1 deletion content/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Adding Content

There are two different types of content; Blogs and Documentation. For adding/modifying documentation please see the seperate [README](./asciidoc-pages/README.md). For Blogs please review the steps below:
There are two different types of content; Blogs and Documentation. For adding/modifying documentation please see the seperate [README](./mdx-docs/README.md). For Blogs please review the steps below:

1. Create a folder in `blog` that is named after your post's title. [Slugify](https://blog.tersmitten.nl/slugify/) the title if it's more than a single word. Example: `hello-world`.
2. Create a file called `index.md` in the directory you just created (`blog/hello-world`).
Expand Down
58 changes: 0 additions & 58 deletions content/asciidoc-pages/README.md

This file was deleted.

59 changes: 0 additions & 59 deletions content/asciidoc-pages/docs/eca-sign-off/index.adoc

This file was deleted.

71 changes: 0 additions & 71 deletions content/asciidoc-pages/docs/faq/index.zh-cn.adoc

This file was deleted.

59 changes: 0 additions & 59 deletions content/asciidoc-pages/docs/logo-styleguide/index.adoc

This file was deleted.

Loading