This repository was archived by the owner on Dec 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
98 lines (96 loc) · 2.83 KB
/
publish-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
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
name: Generate new release
on:
push:
tags:
- "v*"
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- run: npm ci
env:
PUPPETEER_CACHE_DIR: ${{ github.workspace }}/dist/puppeteer
- name: Update GeoIP database
run: npm run updateGeoIPData
env:
LICENSE_KEY: ${{ secrets.GEOIP_LICENSE_KEY }}
- name: Generate ZIP files for Linux
run: ./scripts/create-zips.sh Linux x64
- uses: actions/upload-artifact@v3
with:
name: linux
path: "*.zip"
build-mac:
runs-on: macos-12
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- run: npm ci
env:
PUPPETEER_CACHE_DIR: ${{ github.workspace }}/dist/puppeteer
- name: Update GeoIP database
run: npm run updateGeoIPData
env:
LICENSE_KEY: ${{ secrets.GEOIP_LICENSE_KEY }}
- name: Generate ZIP files for macOS
run: ./scripts/create-zips.sh macOS intel
shell: bash
- uses: actions/upload-artifact@v3
with:
name: mac
path: "*.zip"
build-win:
runs-on: windows-2022
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- run: npm ci
env:
PUPPETEER_CACHE_DIR: ${{ github.workspace }}/dist/puppeteer
- name: Update GeoIP database
run: npm run updateGeoIPData
env:
LICENSE_KEY: ${{ secrets.GEOIP_LICENSE_KEY }}
- name: Generate ZIP files for Windows
run: ./scripts/create-zips.sh Windows x64
shell: bash
- uses: actions/upload-artifact@v3
with:
name: win
path: "*.zip"
publish:
needs:
- build-linux
- build-mac
- build-win
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/download-artifact@v3
- uses: ncipollo/release-action@v1
with:
allowUpdates: true
artifacts: "linux/*.zip,mac/*.zip,win/*.zip"
omitBodyDuringUpdate: true
omitNameDuringUpdate: true
token: ${{ secrets.GITHUB_TOKEN }}
- name: Notify to design-modello-comuni
uses: italia/[email protected]
with:
channel_id: ${{ secrets.SLACK_CHANNEL_COMUNI }}
project_name: App valutazione modelli
slack_token: ${{ secrets.SLACK_TOKEN }}
- name: Notify to design-modello-scuole
uses: italia/[email protected]
with:
channel_id: ${{ secrets.SLACK_CHANNEL_SCUOLE }}
project_name: App valutazione modelli
slack_token: ${{ secrets.SLACK_TOKEN }}