diff options
author | Ernesto Castellotti <mail@ernestocastellotti.it> | 2023-06-07 14:12:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-07 14:12:35 +0200 |
commit | e89f7dec2cc99871925300cd35b921f015585174 (patch) | |
tree | bce23207a489723fd399b076f2dce1f70c96de72 | |
parent | Remove hardcoded URL in config.yml (#220) (diff) | |
download | hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar.gz hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar.bz2 hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar.lz hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar.xz hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.tar.zst hack-gpon.github.io-e89f7dec2cc99871925300cd35b921f015585174.zip |
-rw-r--r-- | .github/workflows/preview-pr.yaml | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/.github/workflows/preview-pr.yaml b/.github/workflows/preview-pr.yaml new file mode 100644 index 0000000..f3a3d57 --- /dev/null +++ b/.github/workflows/preview-pr.yaml @@ -0,0 +1,35 @@ +name: preview-pr + +on: + pull_request_target: + types: [opened, reopened] + +permissions: + pull-requests: write + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Setup Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: '3.0' + bundler-cache: true + - run: bundle exec jekyll build --baseurl "" + - name: Publish to Cloudflare Pages + id: preview-pages + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: ${{ secrets.CLOUDFLARE_ACCOUNT }} + projectName: hack-gpon-preview + directory: _site + branch: preview + - uses: thollander/actions-comment-pull-request@v2 + with: + message: | + Preview of the website obtained from the PR: ${{ steps.preview-pages.outputs.url }} + |