shlink-web-client/.github/workflows/deploy-preview.yml

29 lines
749 B
YAML
Raw Permalink Normal View History

name: Deploy preview
on:
pull_request_target: null
jobs:
deploy:
2023-08-12 11:26:42 +03:00
runs-on: ubuntu-22.04
continue-on-error: true
steps:
- name: Checkout code
2024-10-26 14:14:16 +03:00
uses: actions/checkout@v4
with:
2021-05-09 21:58:48 +03:00
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
- name: Use node.js
2024-10-26 14:14:16 +03:00
uses: actions/setup-node@v4
with:
2024-10-26 14:14:16 +03:00
node-version: 22.x
- name: Build
run: |
2023-08-12 11:26:42 +03:00
npm ci && \
node ./scripts/set-homepage.cjs /shlink-web-client/${GITHUB_HEAD_REF#refs/heads/} && \
2024-10-26 14:14:16 +03:00
node --run build
- name: Deploy preview
2021-08-29 12:31:33 +03:00
uses: shlinkio/deploy-preview-action@v1.0.1
with:
folder: build