-
Notifications
You must be signed in to change notification settings - Fork 18
44 lines (34 loc) · 1.03 KB
/
build-release.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
name: Build module artifact & deploy
on: [push, pull_request]
env:
NODE_VERSION: 20
jobs:
build:
name: Build dependencies & create artifact
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
cache: npm
cache-dependency-path: '_dev/package-lock.json'
- name: Install & build
working-directory: _dev
run: |
npm install
npm run build
- name: Install dev composer dependencies
run: composer install
- name: Generate index.php
run: vendor/bin/autoindex
- name: Install prod composer dependencies
run: composer install --no-dev
- name: Clean-up project
uses: PrestaShopCorp/[email protected]
- name: Create & upload artifact
uses: actions/upload-artifact@v1
with:
name: ${{ github.event.repository.name }}
path: ../