Skip to content

Link and text update (updates #1158, #1159) #1287

Link and text update (updates #1158, #1159)

Link and text update (updates #1158, #1159) #1287

Workflow file for this run

name: Build docs, check CloudFormation, check for dead links
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
pull_request:
branches:
- main
permissions:
contents: read
id-token: write
deployments: write
jobs:
check:
name: build docs
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v7
- name: Build documentation
run: docker run --rm -v "$PWD":/docs -w /docs swift:6.3 swift run VaporDocs
- name: Setup cloudformation linter
uses: ScottBrenner/cfn-lint-action@ed184e91f5085a2932501da8314e899e5e0ef5be # v2.7.1
- name: Run cloudformation lint
run: cfn-lint -t stack.yml
# Only the current docs are checked. 1.5, 2.0 and 3.0 are archived and full
# of long-dead links, so including them would keep this job permanently red.
- name: Run dead links check
uses: tcort/github-action-markdown-link-check@e047c5b37f24ab722bbef1a27b6fab7f96bc4068 # v1.1.3
with:
folder-path: 'docs/4.0, docs/5.0'
config-file: markdown-link-check-config.yml
use-verbose-mode: yes
use-quiet-mode: yes
- name: Run dead links check on top-level markdown
uses: tcort/github-action-markdown-link-check@e047c5b37f24ab722bbef1a27b6fab7f96bc4068 # v1.1.3
with:
folder-path: '.'
max-depth: 1
config-file: markdown-link-check-config.yml
use-verbose-mode: yes
use-quiet-mode: yes
- name: Configure AWS credentials
if: ${{ github.event.pull_request.head.repo.full_name == 'vapor/docs' && github.event.pull_request.user.login != 'dependabot[bot]' }}
uses: aws-actions/configure-aws-credentials@e6de054238d6b7531b4efff3b6587d9aade6a06c # v6.2.3
with:
role-to-assume: ${{ vars.OIDC_ROLE_ARN }}
aws-region: ${{ vars.OIDC_ROLE_REGION }}
- name: Deploy preview to S3
if: ${{ github.event.pull_request.head.repo.full_name == 'vapor/docs' && github.event.pull_request.user.login != 'dependabot[bot]' }}
uses: brokenhandsio/s3-website-pr-action@6ebd9b622b4bb33358228571a50e05d375cbd4de # v3.1.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
bucket-prefix: "vapor-docs-pulls"
folder-to-copy: "./site"
bucket-region: "us-east-1"