-
-
Notifications
You must be signed in to change notification settings - Fork 6
40 lines (36 loc) · 896 Bytes
/
tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: GitHub Actions CI
on:
push:
branches:
- main
pull_request:
jobs:
tests:
runs-on: ubuntu-latest
steps:
- name: Set up Git repository
uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- name: Run HTML Proofer tests
run: bundle exec rake
- name: Upload GitHub Pages artifact
if: always()
uses: actions/upload-pages-artifact@v3
deploy:
needs: tests
if: ${{ always() && github.ref_name == 'main' }}
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
steps:
- uses: actions/deploy-pages@v4
id: deploy-pages
outputs:
deploy_url: ${{ steps.deploy-pages.outputs.page_url }}
environment:
name: github-pages
url: ${{ steps.deploy-pages.outputs.page_url }}