Skip to content

Documents

Documents #11053

Workflow file for this run

name: Documents
on:
workflow_call:
workflow_run:
workflows: ["Build"]
types:
- completed
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idconcurrency
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
skip-check:
name: Skip check
continue-on-error: true
runs-on: ubuntu-latest
outputs:
should_skip: ${{ steps.skip-check.outputs.should_skip }}
permissions:
actions: write
contents: read
steps:
- id: skip-check
uses: fkirc/skip-duplicate-actions@f75f66ce1886f00957d99748a42c724f4330bdcf # v5.3.1
with:
do_not_skip: '["schedule", "workflow_dispatch"]'
paths: |-
[
".github/workflows/docs.yml",
".go-version",
"Makefile",
"cmd/parca-agent/main.go",
"docs"
]
skip_after_successful_duplicate: false
docs:
name: Generate documentation
needs: skip-check
if: ${{ needs.skip-check.outputs.should_skip != 'true' }}
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Set up Go
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version-file: .go-version
- name: Set up Clang
uses: KyleMayes/install-llvm-action@be40c5af3a4adc3e4a03199995ab73aa37536712 # v1.9.0
with:
version: "14"
- name: Install libbpf dependencies
run: |
sudo apt-get update -y
sudo apt-get install -yq libelf-dev zlib1g-dev
- name: Initialize and update libbpf submodule
run: git submodule init && git submodule update
- name: Build BPF
run: make bpf
- name: Set up Jsonnet
run: ./env-jsonnet.sh
- name: Set up environment
run: ./env.sh
- name: Build
run: make build
- name: Docs check
run: |
make README.md
git diff --exit-code ':!deploy'
# Even though pre-commit is not involved here,
# we re-use the pre-commit.ci lite app as a
# generic solution to commit changes
- name: "pre-commit-ci-lite: Apply automatic fixes"
uses: pre-commit-ci/lite-action@9d882e7a565f7008d4faf128f27d1cb6503d4ebf # v1.0.2
if: always()