Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Generate Keyword Documentation

on:
pull_request:
branches: [ main ]
paths:
- 'libraries/**'
- '.github/workflows/docs.yaml'
workflow_dispatch:
inputs:
doc_type:
description: 'Type of documentation to generate'
required: true
default: 'markdown'
type: choice
options:
- markdown
- confluence
- both
libraries_path:
description: 'Path to the libraries directory'
required: false
default: 'libraries'
type: string

jobs:
generate-docs:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
ref: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}

- name: Generate Keyword Documentation
uses: runwhen-contrib/github-actions/runwhen-keyword-docs-generator@keyword-doc-generator
with:
# Use workflow dispatch inputs if available, otherwise defaults
doc_type: ${{ github.event.inputs.doc_type || 'markdown' }}
libraries_path: ${{ github.event.inputs.libraries_path || 'libraries' }}

# Confluence settings (if needed)
confluence_url: ${{ secrets.CONFLUENCE_URL }}
confluence_username: ${{ secrets.CONFLUENCE_USERNAME }}
confluence_api_token: ${{ secrets.CONFLUENCE_API_TOKEN }}
confluence_space_key: ${{ secrets.CONFLUENCE_SPACE_KEY }}
confluence_parent_page_id: ${{ secrets.CONFLUENCE_PARENT_PAGE_ID }}

# Git commit settings
commit_changes: 'true'
commit_message: >-
${{ github.event_name == 'pull_request' &&
'docs: update keyword documentation [skip ci]' ||
'docs: manual update of keyword documentation [skip ci]' }}
Loading