Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
181 lines
4.2 KiB
YAML
181 lines
4.2 KiB
YAML
name: Docs
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- "**"
|
|
- "!dependabot/**"
|
|
- "!xgopilot/**"
|
|
pull_request:
|
|
branches: ["**"]
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
doc_verify:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 30
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Node.js
|
|
uses: actions/setup-node@v6
|
|
with:
|
|
node-version: "20"
|
|
|
|
- name: Install embedme
|
|
run: npm install -g embedme
|
|
|
|
- name: Verify README.md embedded code
|
|
run: embedme --verify README.md
|
|
|
|
- name: Link Checker
|
|
id: lychee
|
|
uses: lycheeverse/lychee-action@v2
|
|
with:
|
|
args: --max-concurrency 3 --retry-wait-time 15 README.md
|
|
|
|
remote_install:
|
|
continue-on-error: true
|
|
timeout-minutes: 30
|
|
strategy:
|
|
matrix:
|
|
os:
|
|
- macos-latest
|
|
- ubuntu-latest
|
|
runs-on: ${{matrix.os}}
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Go
|
|
uses: ./.github/actions/setup-go
|
|
with:
|
|
go-version: "1.24.2"
|
|
|
|
- name: Install dependencies on macOS
|
|
if: startsWith(matrix.os, 'macos')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_macos.sh
|
|
|
|
- name: Install dependencies on Ubuntu
|
|
if: startsWith(matrix.os, 'ubuntu')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_ubuntu.sh
|
|
|
|
- name: Test doc code blocks
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/run.sh
|
|
|
|
local_install:
|
|
continue-on-error: true
|
|
timeout-minutes: 30
|
|
strategy:
|
|
matrix:
|
|
os:
|
|
- macos-latest
|
|
- ubuntu-latest
|
|
runs-on: ${{matrix.os}}
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v6
|
|
with:
|
|
go-version: "1.23"
|
|
|
|
- name: Install dependencies on macOS
|
|
if: startsWith(matrix.os, 'macos')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_macos.sh
|
|
|
|
- name: Install dependencies on Ubuntu
|
|
if: startsWith(matrix.os, 'ubuntu')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_ubuntu.sh
|
|
|
|
- name: Install llgo with tools
|
|
run: |
|
|
set -e
|
|
set -x
|
|
git() {
|
|
if [ "$1" = "clone" ]; then
|
|
# do nothing because we already have the branch
|
|
cd ..
|
|
else
|
|
command git "$@"
|
|
fi
|
|
}
|
|
source doc/_readme/scripts/install_llgo.sh
|
|
echo "LLGO_ROOT=$GITHUB_WORKSPACE" >> $GITHUB_ENV
|
|
|
|
- name: Test doc code blocks
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/run.sh
|
|
|
|
local_install_full:
|
|
continue-on-error: true
|
|
timeout-minutes: 30
|
|
strategy:
|
|
matrix:
|
|
os:
|
|
- macos-latest
|
|
- ubuntu-latest
|
|
runs-on: ${{matrix.os}}
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v6
|
|
with:
|
|
go-version: "1.23"
|
|
|
|
- name: Install dependencies on macOS
|
|
if: startsWith(matrix.os, 'macos')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_macos.sh
|
|
|
|
- name: Install dependencies on Ubuntu
|
|
if: startsWith(matrix.os, 'ubuntu')
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/install_ubuntu.sh
|
|
echo "PATH=/usr/lib/llvm-19/bin:$PATH" >> $GITHUB_ENV
|
|
|
|
- name: Install llgo with tools
|
|
run: |
|
|
set -e
|
|
set -x
|
|
git() {
|
|
if [ "$1" = "clone" ]; then
|
|
# do nothing because we already have the branch
|
|
cd ..
|
|
else
|
|
command git "$@"
|
|
fi
|
|
}
|
|
source doc/_readme/scripts/install_full.sh
|
|
echo "LLGO_ROOT=$GITHUB_WORKSPACE" >> $GITHUB_ENV
|
|
|
|
- name: Test doc code blocks
|
|
run: |
|
|
set -e
|
|
set -x
|
|
source doc/_readme/scripts/run.sh
|