Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

lablabs/setup-terraform-docs

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

⛔️ DEPRECATED

This is no longer supported, please consider using install-gh-release instead.

Setup Terraform docs Action

A GitHub action that installs a Terraform docs executable in the PATH.

Inputs

terraform_docs_version

Required The version of Terraform docs which will be installed. See Terraform docs releases page for valid versions.

If version is "latest", the action will get the latest version number using Octokit.

Default "latest".

token

If set, token will be used for Octokit authentication. Authenticating will increase the API rate limit.

Outputs

The action does not have any output.

Usage

name: Test
on:
  push:
    branches: [ master ]

jobs:
  example-job:
  runs-on: ${{ matrix.os }}

  strategy:
    matrix:
      os: [ubuntu-latest, macos-latest, windows-latest]

  steps:
    - uses: actions/checkout@v1
      name: Checkout source code

    - uses: lablabs/setup-terraform-docs@v1
      name: Setup Terraform docs
      with:
        terraform_docs_version: v0.9.1

    - shell: bash
      run: |
        terraform-docs --version

For latest release you can omit version variable and use

- uses: lablabs/setup-terraform-docs@v1

or specify it explicitly as

- uses: lablabs/setup-terraform-docs@v1
  with:
    terraform_docs_version: latest

For authenticating with the GITHUB_TOKEN you can use

- uses: lablabs/setup-terraform-docs@v1
  with:
    token: ${{ secrets.GITHUB_TOKEN }}