Skip to content

bfranske/antora-site-action

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Antora Site GitHub Action

GitHub action that can be used to generate the Antora site using Antora 3.0.1.

It supports as opt-in the Lunr index generator extension for documentation search.

Important Note: This is Deprecated!

This is no longer maintained and no longer the suggested way to generate an Antora site on GitHub Pages. Instead see the updated instructions in the Antora documentation which explain how to automatically use the latest stable version of Antora directly in a GitHub workflow. See the Antora Issue #940 for more details on the change, essentially you only save about 2 seconds by having a custom GitHub Action with Antora installed over installing Antora and NPM as part of the workflow and things are much less prone to future breakage.

Parameters

The action accepts the following parameters:

  • antora_playbook — that specifies the Antora playbook path within the repository

  • site_sources_path — the path within $GITHUB_WORKSPACE from where to run the site generation

  • antora_lunr_docsearch_enabled — Flag for downloading antora docsearch extension from npm

How to add to your action

name: "Generate site using antora site action"
uses: bfranske/antora-site-action@master
with:
    antora_playbook: antora-playbook.yml
    # optional path within the repo, defaults to ${{github.workspace}}
    site_sources_path: 'site-sources-folder'

How to add to your action for Lunr documentation search index

name: "Generate site and Lunr doc search index using antora site action"
uses: bfranske/antora-site-action@master
with:
    antora_playbook: antora-playbook.yml
    # optional path within the repo, defaults to ${{github.workspace}}
    site_sources_path: 'site-sources-folder'
    antora_lunr_docsearch_enabled: 'true'

Note, this will only add the lunr extension to the build environment. You must also enable the extension and provide supplemental UI files in your antora playbook.

ui:
  bundle:
    url: https://gitlab.com/antora/antora-ui-default/-/jobs/artifacts/HEAD/raw/build/ui-bundle.zip?job=bundle-stable
    snapshot: true
  supplemental_files: ./node_modules/@antora/lunr-extension/supplemental_ui
antora:
  extensions:
  - require: '@antora/lunr-extension'
    index_latest_only: true

See the Antor Lunr Extension project for more details.

About

Antora Site generator GitHub action

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 85.0%
  • Dockerfile 15.0%