Skip to content

Commit

Permalink
Merge branch 'release/4.2'
Browse files Browse the repository at this point in the history
* release/4.2: (89 commits)
  Add CLI not using colours with pipe or redirect #4393
  Hyphenate pre-processing consistently
  Provide additional details on S9API & XSLT3
  Add LwDITA list parsing performance improvements
  Add ancestor directories to .ditaotrc search path
  Add DEBUG to list of message types
  List Java dependency updates
  Add missing CLI options --deliverable & --theme
  Add details on recently resolved issues in 4.2
  Add target release date
  Add details on 4.2 issues tagged “bug”
  Add common CSS changes to migration & re-use in RN
  Add 4.2 migration topic
  Promote map-first HTML5 to release summary
  Add details on remaining enhancements
  Add details on subject scheme enhancements
  Add details on  map-first preprocessing in HTML5
  Add details on additional enhancements
  Add details on LwDITA plug-in v5.7
  Add details on Normalized DITA plug-in v2.0
  ...
  • Loading branch information
infotexture committed Feb 10, 2024
2 parents 0ce3dc5 + 31a2a40 commit bf7ea79
Show file tree
Hide file tree
Showing 87 changed files with 2,045 additions and 1,220 deletions.
6 changes: 1 addition & 5 deletions .github/actions/render/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ inputs:
default: 'master'
DITA_OT_VERSION:
description: 'DITA-OT version used for rendering'
default: '4.0.1'
default: '4.1.2'
runs:
using: 'composite'
steps:
Expand All @@ -23,7 +23,6 @@ runs:
uses: ruby/setup-ruby@v1
with:
ruby-version: 2.6

- name: Download website plug-in
shell: bash
run: |
Expand All @@ -33,7 +32,6 @@ runs:
with:
path: dita-ot-${{ inputs.DITA_OT_VERSION }}
key: ${{ runner.os }}-dita-ot-${{ inputs.DITA_OT_VERSION }}

- name: Download stable DITA-OT
shell: bash
run: |
Expand All @@ -44,7 +42,6 @@ runs:
echo "Use cached dita-ot-${{ inputs.DITA_OT_VERSION }}"
fi
dita-ot-${{ inputs.DITA_OT_VERSION }}/bin/dita install org.dita-ot.html.zip --force -v
- name: Get develop DITA-OT ETag
shell: bash
run: |
Expand All @@ -66,7 +63,6 @@ runs:
echo "Use cached dita-ot-develop"
fi
echo "DITA_OT_DEV=$(find dita-ot-develop -name 'dita-ot-*@*' -type d | head -1)" >> $GITHUB_ENV
- name: Run DITA-OT
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/gradle-wrapper-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v1
- uses: gradle/wrapper-validation-action@v2
2 changes: 1 addition & 1 deletion .github/workflows/prettier.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
ref: ${{ github.ref }}

- name: Set up Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '18.x'
cache: 'npm'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
uses: ./.github/actions/render

- name: Cache NPM
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
Expand All @@ -47,7 +47,7 @@ jobs:
rm -fr build
- name: Cache gems
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
Expand Down
60 changes: 44 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# This workflow builds changes to release tag and commits to website repo for release PR

name: Generate website release PR

on:
workflow_dispatch:
inputs:
Expand All @@ -13,13 +12,12 @@ on:
required: true
repository_dispatch:
types: [release]

jobs:
deploy:
runs-on: ubuntu-latest
env:
WEBSITE_PLUGIN_BRANCH: 'master'
DITA_OT_VERSION: '4.0.1'
DITA_OT_VERSION: '4.1.2'
steps:
- name: Parse arguments
run: |
Expand All @@ -34,35 +32,29 @@ jobs:
else
echo "TAG=${{ github.event.inputs.docs-tag }}" >> $GITHUB_ENV
fi
- name: Check out docs
uses: actions/checkout@v4
with:
ref: ${{ env.TAG }}

- name: Set variables
run: |
echo "GITHUB_SHA_SHORT=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
- name: Set up JDK 17
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17

- name: Check out website
uses: actions/checkout@v4
with:
repository: dita-ot/website
token: ${{ secrets.COMMITTER_TOKEN }}
path: website

- name: Download website plug-in
run: |
curl -sL https://github.com/dita-ot/org.dita-ot.html/archive/refs/heads/${{ env.WEBSITE_PLUGIN_BRANCH }}.zip -o org.dita-ot.html.zip
- name: Cache render DITA-OT
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: dita-ot-${{ env.DITA_OT_VERSION }}
key: ${{ runner.os }}-dita-ot-${{ env.DITA_OT_VERSION }}
Expand All @@ -75,14 +67,12 @@ jobs:
echo "Use cached dita-ot-${{ env.DITA_OT_VERSION }}"
fi
dita-ot-${{ env.DITA_OT_VERSION }}/bin/dita install org.dita-ot.html.zip --force -v
- name: Download release DITA-OT
run: |
curl -sL https://github.com/dita-ot/dita-ot/releases/download/$VERSION/dita-ot-$VERSION.zip -o dita-ot-$VERSION.zip
unzip dita-ot-$VERSION.zip -d src-dita-ot
env:
VERSION: ${{ github.event.inputs.dita-ot-version }}

- name: Run DITA-OT
run: |
./gradlew site \
Expand All @@ -96,9 +86,8 @@ jobs:
WEBSITE_DIR: ${{ github.workspace }}/website
DITA_HOME: ${{ github.workspace }}/dita-ot-${{ env.DITA_OT_VERSION }}
RELEASE_DITA_OT: ${{ github.workspace }}/src-dita-ot/dita-ot-${{ github.event.inputs.dita-ot-version }}

- name: Create release PR
uses: peter-evans/create-pull-request@v5
uses: peter-evans/create-pull-request@v6
with:
branch: release/${{ github.event.inputs.dita-ot-version }}
title: 'Update site for ${{ github.event.inputs.dita-ot-version }}'
Expand All @@ -112,7 +101,46 @@ jobs:
commit-message: 'Update ‘${{ env.RELEASE }}’ docs for ${{ github.event.inputs.dita-ot-version }}'
committer: 'DITA-OT Bot <[email protected]>'
signoff: true
token: ${{ secrets.COMMITTER_TOKEN }}
token: ${{ secrets.DOCS_RELEASE_TOKEN }}
path: website
labels: |
release-updates
update-ci:
runs-on: ubuntu-latest
steps:
- name: Parse arguments
run: |
if [[ -n "${{ github.event.client_payload.dita_ot_version }}" ]]; then
echo "VERSION=${{ github.event.client_payload.dita_ot_version }}" >> $GITHUB_ENV
else
echo "VERSION=${{ github.event.inputs.dita-ot-version }}" >> $GITHUB_ENV
fi
- name: Check out docs
uses: actions/checkout@v4
with:
ref: develop

- name: Update GitHub Actions release workflow
uses: mikefarah/yq@master
with:
cmd: yq -i '.jobs.deploy.env.DITA_OT_VERSION = "${{ env.VERSION }}"' '.github/workflows/release.yml'
- name: Update GitHub Actions render action
uses: mikefarah/yq@master
with:
cmd: yq -i '.inputs.DITA_OT_VERSION.default = "${{ env.VERSION }}"' '.github/actions/render/action.yml'

- name: Create release PR
uses: peter-evans/create-pull-request@v6
with:
branch: feature/update-github-actions-${{ env.VERSION }}
title: 'Update docs GitHub Actions for ${{ env.VERSION }}'
body: |
Update docs GitHub Actions for ${{ env.VERSION }}.
commit-message: 'Update GitHub Actions for ${{ env.VERSION }}'
committer: 'DITA-OT Bot <[email protected]>'
signoff: true
token: ${{ secrets.DOCS_RELEASE_TOKEN }}
labels: |
release-updates
3 changes: 0 additions & 3 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
39 changes: 0 additions & 39 deletions .prettierrc.json

This file was deleted.

35 changes: 35 additions & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Prettier Configuration File

# https://prettier.io/docs/en/configuration.html

arrowParens: avoid
bracketSameLine: false
bracketSpacing: false
endOfLine: lf
htmlWhitespaceSensitivity: css
printWidth: 120
proseWrap: preserve
requirePragma: false
semi: true
singleQuote: true
tabWidth: 2
trailingComma: all
useTabs: false
vueIndentScriptAndStyle: true
xmlSelfClosingSpace: false
xmlWhitespaceSensitivity: strict

# Override configuration for certain files
overrides:
- files: external-links.ditamap
options:
printWidth: 80
- files: source-files.ditamap
options:
printWidth: 200
- files: '*.json'
options:
printWidth: 200

plugins:
- '@prettier/plugin-xml'
31 changes: 22 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,26 +29,39 @@ You must have a JRE and a local installation of DITA-OT. There is no need to dow
1. Open a command prompt, and change to the directory of your docs repository clone.
2. Type a variant of the following command for your operating system, adjust the path to your DITA-OT installation, and press <kbd>Enter</kbd>:

- On Linux or macOS, use `./gradlew`:
- On **Linux**, **macOS**, or **Git Bash**, use `./gradlew`:

./gradlew -PditaHome=/path/to/dita-ot

- On **Windows**, use `gradlew.bat`:

gradlew.bat -PditaHome=C:\path\to\dita-ot

<details>
<summary>Using a `dita-ot` repository clone</summary>
<details>
<summary><strong>Alternative:</strong> Using a DITA-OT repository clone</summary>

If you’re using a clone of the [DITA-OT development repository][5] as your toolkit installation alongside your clone of the `docs` repository:

1. In the root directory of your `dita-ot` repository, run Gradle to compile the Java code and install plugins.

- On **Linux**, **macOS**, or **Git Bash**, use `./gradlew`.
- On **Windows**, use `gradlew.bat`.

2. Then run the Gradle build in the `docs` repository to generate topics and build the documentation output.

- If you’re using a clone of the [DITA-OT development repository][5] as your toolkit installation alongside your clone of the docs repository, run the build script on **Linux** or **macOS** like this:
- On **Linux**, **macOS**, or **Git Bash**, run the build script like this:

./gradlew -PditaHome=../dita-ot/src/main
./gradlew -PditaHome=../dita-ot/src/main

- You can also specify a single output format. To build HTML output, enter the following on the command line:
- On **Windows**, use `gradlew.bat`:

gradlew.bat -PditaHome=C:\path\to\dita-ot\src\main

</details>

./gradlew -PditaHome=../dita-ot/src/main html
You can also specify a single output format. To build HTML for example, add `html` to the end of the command:

</details>
./gradlew -PditaHome=/path/to/dita-ot html

### Results

Expand Down Expand Up @@ -125,7 +138,7 @@ If you'd like to check whether your changes are formatted correctly, or format t
[4]: https://www.dita-ot.org
[5]: https://github.com/dita-ot/dita-ot
[6]: https://s3-eu-west-1.amazonaws.com/dita-ot/dita-ot-develop.zip
[7]: https://github.com/dita-ot/dita-ot/blob/develop/build.gradle#L181-L192
[7]: https://github.com/dita-ot/dita-ot/blob/develop/build.gradle#L206-L217
[8]: .github/CONTRIBUTING.md
[9]: https://github.com/dita-ot/docs/wiki/Coding-guidelines
[10]: https://github.com/dita-ot/docs/wiki/Git-workflow#best-practices
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
<title>Legacy pre-processing extensions</title>
<p>The following extension points are available in the original <codeph>preprocess</codeph> pipeline that was used
by default for all transformations prior to DITA-OT 3.0. These extensions are not available in the newer
<xref keyref="map-first-preproc">map-first preprocessing</xref> pipeline (<codeph>preprocess2</codeph>), which
<xref keyref="map-first-preproc">map-first pre-processing</xref> pipeline (<codeph>preprocess2</codeph>), which
is used in the PDF and HTML Help transformations as of DITA-OT 3.0.</p>
<note conkeyref="conref-task/caution-extend-within-preprocessing"/>
<dl>
Expand Down
2 changes: 1 addition & 1 deletion extension-points/plugin-extension-points-xslt-import.dita
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<indexterm>extension points</indexterm></indexterm>
<indexterm>extension points
<indexterm>XSLT</indexterm></indexterm>
<indexterm>preprocessing
<indexterm>pre-processing
<indexterm>extension points, XSLT</indexterm></indexterm>
</keywords>
</metadata>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<keywords>
<indexterm>XSLT
<indexterm>parameters</indexterm></indexterm>
<indexterm>preprocessing
<indexterm>pre-processing
<indexterm>extension points, parameters</indexterm></indexterm>
</keywords>
</metadata>
Expand Down
2 changes: 1 addition & 1 deletion extension-points/plugin-extension-points.dita
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<indexterm>overview</indexterm>
<indexterm>plug-in</indexterm></indexterm>
<indexterm>extension points
<index-see-also>preprocessing</index-see-also></indexterm>
<index-see-also>pre-processing</index-see-also></indexterm>
<indexterm><filepath>plugin.xml</filepath></indexterm>
<indexterm>topicmerge
<index-see>org.dita.pdf2.xsl.topicmerge</index-see></indexterm>
Expand Down
2 changes: 1 addition & 1 deletion index.dita
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
conkeyref="pdf-customization/shortdesc-ph"
/>.</li>
<li outputclass="list-group-item list-group-item-action">
<xref keyref="adding-plugins" outputclass="stretched-link"/> explains how to install, remove and discover new
<xref keyref="adding-plugins" outputclass="stretched-link"/> explains how to install, remove, and discover new
plug-ins.</li>
<li outputclass="list-group-item list-group-item-action">
<xref keyref="custom-plugins" outputclass="stretched-link"/> provides information on extending DITA-OT with
Expand Down
Loading

0 comments on commit bf7ea79

Please sign in to comment.