Skip to content
file-text

GitHub Action

action-docs

v1.0.1 Latest version

action-docs

file-text

action-docs

Github action that generates docs for a github action and injects them into the README.md

Installation

Copy and paste the following snippet into your .yml file.

              

- name: action-docs

uses: Dirrk/action-docs@v1.0.1

Learn more about this action in Dirrk/action-docs

Choose a version

action-docs

Github action that generates docs for a github action and injects them into the README.md

Usage

To use action-docs github action, configure a YAML workflow file, e.g. .github/workflows/documentation.yml, with the following:

name: Generate action docs
on:
  - pull_request
jobs:
  docs:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
      with:
        ref: ${{ github.event.pull_request.head.ref }}

    - name: Update README.md from action.yml
      uses: Dirrk/action-docs@v1
WARNING: This requires your README.md to contain comment delimiters, view this file in raw mode to see how it works

Inputs

Name Description Default Required
action_docs_git_commit_message Commit message action-docs: automated action false
action_docs_git_push If true it will commit and push the changes true false
action_docs_template_file Template file to use for rendering the markdown docs /src/default_template.tpl false
action_docs_working_dir Directory that contains the action.yml and README.md . false

Outputs

Name Description
num_changed Number of files changed