diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 0000000..1ec9755 --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,54 @@ +name: Trigger documentation build + +on: + push: + branches: + - 'master' + paths: + - 'docs/**' + pull_request: + branches: + - 'master' + paths: + - 'docs/**' + +env: + VALE_VERSION: ${{ vars.LIBRARY_VALE_VERSION || '3.3.0' }} + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + + - name: Install vale + run: | + wget "https://github.com/errata-ai/vale/releases/download/v${VALE_VERSION}/vale_${VALE_VERSION}_Linux_64-bit.tar.gz" + sudo tar -xvzf vale_${VALE_VERSION}_Linux_64-bit.tar.gz -C /usr/local/bin vale + + - name: Generate Site + run: | + cd docs/_playbook/ + npm install + export GIT_CREDENTIALS='https://axoniq-devops:${{ secrets.LIBRARY_DEVBOT_TOKEN }}@github.com' + echo 'Using' `vale -v` + npx antora playbook.yaml + + - name: Notify AxonIQ Library (if a push to a tracked branch) + if: ${{ github.event_name == 'push'}} + uses: actions/github-script@v7 + with: + github-token: ${{ secrets.LIBRARY_DEVBOT_TOKEN }} + script: | + await github.rest.actions.createWorkflowDispatch({ + owner: 'AxonIQ', + repo: 'axoniq-library-site', + workflow_id: 'publish.yml', + ref: 'main' + }) \ No newline at end of file diff --git a/docs/_playbook/.gitignore b/docs/_playbook/.gitignore new file mode 100644 index 0000000..8a28735 --- /dev/null +++ b/docs/_playbook/.gitignore @@ -0,0 +1,4 @@ +build +node_modules +.vscode +vale diff --git a/docs/_playbook/.vale.ini b/docs/_playbook/.vale.ini new file mode 100644 index 0000000..0f6f4fc --- /dev/null +++ b/docs/_playbook/.vale.ini @@ -0,0 +1,24 @@ +StylesPath = vale + +MinAlertLevel = suggestion + +Packages = http://github.com/AxonIQ/axoniq-vale-package/releases/latest/download/axoniq-vale-package.zip + +Vocab = general, AxonIQ, Java, Names_Terms, misc + +[*.{adoc,html}] +BasedOnStyles = AxonIQ, proselint, Google + +Google.Headings = NO # Diasable in favor od AxonIQ one +Google.Parens = NO # Disable warning about using parens +Google.Quotes = NO # Diasable "commas and periods go inside quotation marks" +Google.WordList = NO # Disable Google's word list +Google.Passive = NO # Allow the use of Passive voice +Google.Colons = NO # Allow the use of Colons +Google.Will = NO # Allow use will +Google.Contractions = NO +Google.We = NO + + +AxonIQ.AcronymCase = NO +AxonIQ.HeadingTitle = NO diff --git a/docs/_playbook/package.json b/docs/_playbook/package.json new file mode 100644 index 0000000..26e6dde --- /dev/null +++ b/docs/_playbook/package.json @@ -0,0 +1,11 @@ +{ + "devDependencies": { + "@antora/atlas-extension": "^1.0.0-alpha.2", + "@antora/cli": "^3.2.0-alpha.2", + "@antora/lunr-extension": "^1.0.0-alpha.8", + "@antora/site-generator": "^3.2.0-alpha.2", + "@asciidoctor/tabs": "^1.0.0-beta.6", + "@axoniq/antora-vale-extension": "^0.1.1", + "asciidoctor-kroki": "^0.17.0" + } +} diff --git a/docs/_playbook/playbook.yaml b/docs/_playbook/playbook.yaml new file mode 100644 index 0000000..112b71e --- /dev/null +++ b/docs/_playbook/playbook.yaml @@ -0,0 +1,42 @@ +site: + title: Axon JGroups Extension docs PREVIEW + start_page: old-reference-guide::index.adoc + +content: + sources: + - url: ../.. + start_paths: ['docs/*', '!docs/_*'] + +asciidoc: + attributes: + experimental: true + page-pagination: true + kroki-fetch-diagram: true + # primary-site-manifest-url: https://library.axoniq.io/site-manifest.json + extensions: + - asciidoctor-kroki + - '@asciidoctor/tabs' + +antora: + extensions: + - id: prose-linting + require: '@axoniq/antora-vale-extension' + enabled: true + vale_config: .vale.ini + update_styles: true + - id: lunr + require: '@antora/lunr-extension' + enabled: true + index_latest_only: true + - id: atlas + require: '@antora/atlas-extension' + +runtime: + fetch: true # fetch remote repos + log: + level: info + failure_level: error + +ui: + bundle: + url: https://github.com/AxonIQ/axoniq-library-ui/releases/download/v.0.1.10/ui-bundle.zip diff --git a/docs/old-reference-guide/antora.yml b/docs/old-reference-guide/antora.yml new file mode 100644 index 0000000..14e16e5 --- /dev/null +++ b/docs/old-reference-guide/antora.yml @@ -0,0 +1,14 @@ +name: jgroups_extension_old_ref +title: Spring AMQP Extension Guide +version: true +prerelease: true +start_page: ROOT:index.adoc + +asciidoc: + attributes: + component_description: The JGroups AMQP Extension Guide from the former reference guide + type: guide + group: axon-framework + +nav: + - modules/nav.adoc \ No newline at end of file diff --git a/docs/old-reference-guide/modules/nav.adoc b/docs/old-reference-guide/modules/nav.adoc new file mode 100644 index 0000000..e69de29