-
Notifications
You must be signed in to change notification settings - Fork 11
58 lines (56 loc) · 1.99 KB
/
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: release
on:
release:
types: [created]
jobs:
package:
name: "Create release package"
runs-on: ubuntu-22.04
container:
image: skaut/lebeda:8.3
steps:
- uses: actions/checkout@v4
# Copy & paste from https://github.com/actions/cache/blob/master/examples.md#php---composer
- name: Get composer cache
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- uses: actions/cache@v4
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-composer-
- name: Install yarn
run: |
apt-get update
apt-get install -y npm
npm install --global yarn
#Copy & paste from https://github.com/actions/cache/blob/master/examples.md#node---yarn
- name: Get yarn cache
id: yarn-cache
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
- uses: actions/cache@v4
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
run: |
composer self-update
composer install --no-dev --prefer-dist --optimize-autoloader
yarn install
yarn build
mv app/config/sample.local.neon app/config/local.neon
rm -f app/config/ci.local.neon app/config/production.local.neon
find . -name .gitignore -type f -delete
- name: Zip package
uses: montudor/[email protected]
with:
args: zip -qq -r srs.zip app backup log migrations temp vendor www .htaccess LICENSE README.md
- name: Upload artifact
uses: skx/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
args: 'srs.zip'