Merge pull request #45 from Kryfulli/fix/footer #132
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: Test, build and deploy to administrans.fr | |
on: | |
push: | |
branches: | |
- main | |
# - $default-branch # Set a branch name to trigger deployment | |
pull_request: | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
deploy: | |
runs-on: ubuntu-20.04 | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
cache: 'yarn' | |
- name: Install dependencies | |
run: yarn install | |
- name: Build | |
run: yarn build | |
env: | |
VITE_PLAUSIBLE_TRACKING_DOMAIN: administrans.fr | |
VITE_PLAUSIBLE_URL: https://stats.administrans.fr | |
VITE_REDIRECT_DOMAIN: administrans.fr | |
- name: Disable jekyll | |
run: touch dist/.nojekyll | |
- name: Deploy 🚀 | |
uses: JamesIves/github-pages-deploy-action@v4 | |
if: github.ref == 'refs/heads/main' | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
branch: gh-pages # The branch the action should deploy to. | |
folder: dist # The folder the action should deploy. | |
- name: Deploy review branch | |
uses: JamesIves/github-pages-deploy-action@v4 | |
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
branch: pr-review-${{ github.event.number }} # The branch the action should deploy to. | |
folder: dist # The folder the action should deploy. |