Skip to content

vhs: basic tests

vhs: basic tests #391

Workflow file for this run

name: Doc
on:
pull_request:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: shallow clone
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.22.0'
- name: build
run: |
cd example
go build
- uses: actions/upload-artifact@v4
with:
name: example
path: example/example
retention-days: 1
word: {needs: build, uses: ./.github/workflows/vhs-template.yml, with: {topic: word}}
nospace: {needs: build, uses: ./.github/workflows/vhs-template.yml, with: {topic: nospace}}
doubleQuote: {needs: build, uses: ./.github/workflows/vhs-template.yml, with: {topic: doubleQuote}}
doc:
needs:
- word
- nospace
- doubleQuote
runs-on: ubuntu-latest
container: ghcr.io/carapace-sh/carapace
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
key: linkcheck
path: docs/book/linkcheck
- uses: actions/download-artifact@v4
with:
path: docs/src/development/vhs/
- name: Display structure of downloaded files
run: ls -R docs/src/development/vhs/
- name: "build docs"
run: |
mdbook build docs
- name: "push gh-pages"
if: github.ref == 'refs/heads/master'
run: |
cd docs/book/html/
git init
git config user.name rsteube
git config user.email [email protected]
git add .
git commit -m "initial commit [ci skip]"
git push --force https://rsteube:${GITHUB_TOKEN}@github.com/carapace-sh/carapace.git master:gh-pages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}