Skip to content

Commit 776c490

Browse files
[Docs] - Fix website build script, also build the website in every PR
1 parent 634c21b commit 776c490

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

.github/workflows/build_docs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828

2929
# Zip and upload the static site.
3030
- name: Upload artifact
31-
uses: actions/upload-pages-artifact@v1
31+
uses: actions/upload-pages-artifact@v3
3232
with:
3333
path: ./doc/website/build
3434

@@ -49,4 +49,4 @@ jobs:
4949
steps:
5050
- name: Deploy to GitHub Pages
5151
id: deployment
52-
uses: actions/deploy-pages@v2
52+
uses: actions/deploy-pages@v4

.github/workflows/pr_validation.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,23 @@ jobs:
2424

2525
# Run all tests
2626
- run: flutter test
27+
28+
build-website:
29+
runs-on: ubuntu-latest
30+
defaults:
31+
run:
32+
working-directory: ./doc/website
33+
steps:
34+
# Checkout the repository
35+
- uses: actions/checkout@v3
36+
37+
# Setup a Dart environment
38+
- uses: dart-lang/setup-dart@v1
39+
40+
# Download all the packages that the app uses
41+
- run: dart pub get
42+
43+
# Build the static site
44+
- run: dart run bin/flutter_test_robots_docs.dart
45+
env:
46+
GHUB_DOC_WEBSITE_TOKEN: ${{ vars.GHUB_DOC_WEBSITE_TOKEN }}

0 commit comments

Comments
 (0)