-
Notifications
You must be signed in to change notification settings - Fork 25
100 lines (84 loc) · 3.93 KB
/
preview.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
name: Preview
on:
push:
branches-ignore:
- main
concurrency: preview-${{ github.workflow }}-${{ github.ref }}
jobs:
preview:
name: Preview
if: github.repository_owner == 'isaac-mason'
runs-on: ubuntu-latest
env:
NODE_OPTIONS: '--max-old-space-size=4096'
steps:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Setup Node.js 22.x
uses: actions/setup-node@v2
with:
node-version: 22.x
- name: Install Dependencies
run: yarn
- name: Build Packages
run: ./ci/build-packages.sh
shell: bash
- name: Test
run: yarn test
# navmesh website
- name: NavMesh Website - Pull Vercel Environment Information
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_NAVMESH_WEBSITE_PROJECT_ID }}
- name: NavMesh Website - Build Project Artifacts
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel build --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_NAVMESH_WEBSITE_PROJECT_ID }}
- name: NavMesh Website - Deploy Project Artifacts to Vercel
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_NAVMESH_WEBSITE_PROJECT_ID }}
# storybook
- name: Storybook - Pull Vercel Environment Information
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_STORYBOOK_PROJECT_ID }}
- name: Storybook - Build Project Artifacts
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel build --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_STORYBOOK_PROJECT_ID }}
- name: Storybook - Deploy Project Artifacts to Vercel
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_STORYBOOK_PROJECT_ID }}
# docs
- name: Docs - Pull Vercel Environment Information
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_DOCS_PROJECT_ID }}
- name: Docs - Build Project Artifacts
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel build --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_DOCS_PROJECT_ID }}
- name: Docs - Deploy Project Artifacts to Vercel
if: github.event_name != 'pull_request' && github.actor != 'dependabot[bot]'
run: yarn run vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_DOCS_PROJECT_ID }}