forked from htmlacademy-ecmascript/368613-big-trip-21
-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (28 loc) · 799 Bytes
/
build.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
name: Build
on:
- pull_request
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '20.x'
- name: Build
run: |
NODE_ENV=development npm install && npm run build --if-present
if [[ $(find . -maxdepth 1 -type d -name 'build') == '' ]]
then
cp -r public build
fi
mkdir actions_artifacts
echo "prev.event.number=${{ github.event.number }}" > actions_artifacts/env
mv build actions_artifacts
- name: Save build
uses: actions/upload-artifact@v2
with:
name: actions_artifacts
path: actions_artifacts