Deploy Examples #213
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy Examples | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * 0" | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
repository: petitparser/dart-petitparser-examples | |
- name: Install | |
uses: dart-lang/setup-dart@v1.3 | |
- name: Build | |
run: | | |
dart pub get | |
dart pub global activate webdev | |
webdev build --release | |
rm -rf build/packages | |
touch .nojekyll | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./build | |
publish_branch: main | |
destination_dir: examples | |
enable_jekyll: true |