red-hat-developers-documentation-rhdh
red-hat-developers-documentation-rhdh copied to clipboard
Red Hat Developer Hub documentation - upstream sources for https://gitlab.cee.redhat.com/red-hat-developers-documentation/rhdh
Red Hat Developer Hub documentation
This is a repository for Red Hat Developer (RHDH) documentation.
Contributing
Contribute to this repository to add new and edit existing RHDH documentation published on the link:https://docs.redhat.com/en/documentation/red_hat_developer_hub/[Red Hat Documentation page].
Before submitting a pull request (PR), create a Jira issue associated with your contribution to this repository.
There are currently three Jira projects related to RHDH:
- link:https://redhat.atlassian.net/jira/software/c/projects/RHDHBUGS/issues[RHDHBUGS] - Red Hat Developer Hub Bugs.
- link:https://redhat.atlassian.net/jira/software/c/projects/RHIDP/issues[RHIDP] - Red Hat Internal Developer Platform.
- link:https://redhat.atlassian.net/jira/software/c/projects/RHDHPLAN/issues[RHDHPLAN] - RH Developer Hub Planning.
Choose a Jira project that matches your contribution and create a new issue:
. In the Jira project, click Create. . In the Description field, describe your contribution. . In the Component/s field, select Documentation from the drop-down list. . Save the created Jira issue.
[IMPORTANT]
RHDH release notes are single-sourced from Jira. See the link:https://docs.google.com/document/d/1X2CrrU9K3ZqbxN7DXmU6P1mY7inLD32qs3rpOUHz6Vw/edit?tab=t.0#heading=h.yqxd252ryhua[RHDH Release Notes process document] and the link:https://gitlab.cee.redhat.com/red-hat-developers-documentation/red-hat-developer-hub-release-notes[release notes repository] (VPN required) for details.
Style and formatting
All contributions are in AsciiDoc.
Make sure your writing follows the rules listed in link:https://www.ibm.com/docs/en/ibm-style[IBM Style] and link:https://redhat-documentation.github.io/supplementary-style-guide/[Red Hat supplementary style guide].
[NOTE]
If the IBM Style and the Red Hat supplementary style guide offer conflicting solutions, the Red Hat supplementary style guide solution overrides IBM Style.
Follow the link:https://redhat-documentation.github.io/modular-docs/[Modular documentation reference guide] to modularize your content.
Building locally
.Prerequisites
- link:https://nodejs.org[Node.js]
- link:https://podman.io[Podman]
- link:https://github.com/errata-ai/vale[Vale]
- link:https://github.com/lycheeverse/lychee[Lychee] (downloaded automatically by the build script if not installed)
- Optional for local builds: A
GITHUB_TOKENenvironment variable to avoid GitHub API rate limiting during lychee link validation. Use link:https://cli.github.com[GitHub CLI] (gh) to get and refresh the token:export GITHUB_TOKEN=$(gh auth token). This token is required in CI for deployment togh-pages.
.Procedure
. Sync the Vale style rules: + [source,terminal]
$ vale sync
. Build HTML with images in titles-generated/ using ccutil in a container, then run lychee link validation and CQA content quality checks:
+
[source,terminal]
$ ./build/scripts/build-ccutil.sh
The ccutil CLI tool reproduces the behavior of the production publication chain (Pantheon), including its limitations, and is therefore preferred over asciidoctor.
Results are written to build-report.json.
Checking for broken links
The build command above includes lychee link validation automatically. To run lychee separately on already-built HTML:
.Prerequisites
- link:https://github.com/lycheeverse/lychee[Lychee]
- Optional: A
GITHUB_TOKENenvironment variable to avoid GitHub API rate limiting. Use link:https://cli.github.com[GitHub CLI] (gh) to get and refresh the token:export GITHUB_TOKEN=$(gh auth token)
.Procedure
. Run lychee on the built HTML: + [source,terminal]
$ lychee titles-generated/
To check for broken links in the published RHDH docs, use linkchecker:
.Prerequisites
- link:https://github.com/linkchecker/linkchecker[linkchecker]
.Procedure
. Run the following command to create a .txt file with a list of detected broken links: + [source,terminal]
$ linkchecker --check-extern --output failures --file-output failures/broken-links.txt https://docs.redhat.com/en/documentation/red_hat_developer_hub/
Previews
You can view commits to this repo as GitHub Page content here:
https://redhat-developer.github.io/red-hat-developers-documentation-rhdh/
PRs have a link to the generated HTML attached as a comment.
The publication workflow has two stages:
. The link:.github/workflows/pr.yml[PR workflow] and link:.github/workflows/build-asciidoc.yml[GitHub Pages workflow] build HTML from AsciiDoc sources and push the output to the gh-pages branch using build/scripts/deploy-gh-pages.js, which handles concurrent pushes with automatic retry, cleanup of stale PR/branch directories, and index regeneration.
. The link:https://github.com/redhat-developer/red-hat-developers-documentation-rhdh/actions/workflows/pages/pages-build-deployment[GitHub Pages build and deployment] workflow, managed by GitHub, detects pushes to the gh-pages branch and publishes the content to GitHub Pages.
See link:docs/github-publication-workflow.md[GitHub Publication Workflow Architecture] for the full technical reference.
Reviews
All PRs are reviewed for technical accuracy by an SME and writing quality by another tech writer.
When possible, request a tech review first and implement suggestions from the SME. After your PR is approved by the tech reviewer, follow it up with a request a peer review.
Check link:https://docs.google.com/spreadsheets/d/1X1KHZx2Kvbotie-sU1g2xNt5vHWtc8Wq9Zb43JycOlA/edit?gid=1375268335#gid=1375268335[this doc] for the current peer review roster.
Merging PRs
After the peer and tech reviewer approve your PR, the PR is ready for merging and cherry-picking by a gatekeeper.
Check link:https://docs.google.com/spreadsheets/d/1X1KHZx2Kvbotie-sU1g2xNt5vHWtc8Wq9Zb43JycOlA/edit?gid=0#gid=0[this doc] for the current gatekeeper roster.
Labels
As you work on your contribution to this repo, use labels to show the status of your PR and to request reviews:
- draft:
do-not-merge/work-in-progress - ready for peer and technical reviews:
do-not-merge/review-in-progress - request for a tech review:
technical-review-needed - completed tech review:
technical-review-done - request for a peer review:
peer-review-needed - completed peer review:
peer-review-done - ready for merging:
ready-to-merge
[NOTE]
Remember to remove labels as they become outdated.
For example, remove the do-not-merge/work-in-progress label when you finalize your draft and your PR is ready for review.
Publishing pipeline
This repo is the upstream mirror of the GitLab RHDH repo https://gitlab.cee.redhat.com/red-hat-developers-documentation/rhdh
Merged PRs are synced to GitLab for build with Pantheon.
Plugins Reference Guide
For Plugin configuration guide, see upstream content in https://github.com/janus-idp/backstage-plugins/tree/main/plugins
Additional sources
- link:https://spaces.redhat.com/spaces/RHDEVDOCS/pages/467060194/RHDH+documentation+contributor+guide[RHDH documentation contributor guide]
- link:https://spaces.redhat.com/spaces/RHDEVDOCS/pages/494635174/Content+creation+guidelines [RHDH content creation guidelines]
- link:https://spaces.redhat.com/spaces/RHDEVDOCS/pages/580260123/GitHub+Labels+-+What+When+Who[RHDH GitHub labels]