-
Notifications
You must be signed in to change notification settings - Fork 158
64 lines (56 loc) · 1.31 KB
/
build-ipk.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
name: Build ipk for HomeProxy
on:
push:
branches:
- 'master'
- 'dev'
paths:
- 'htdocs/**'
- 'po/**'
- 'root/**'
- 'Makefile'
- '.github/**'
pull_request:
branches:
- 'master'
- 'dev'
types:
- opened
- synchronize
- reopened
paths:
- 'htdocs/**'
- 'root/**'
- 'Makefile'
- '.github/**'
release:
types:
- published
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout source tree
uses: actions/checkout@v3
- name: Build ipk file
env:
RELEASE_TYPE: ${{ github.event_name }}
run: |
pushd .github
fakeroot bash build-ipk.sh
echo "ASSET_NAME=$(ls *.ipk)" >> $GITHUB_ENV
popd
- name: Publishing to GitHub Artifacts
uses: actions/upload-artifact@v3
if: github.event_name != 'release'
with:
name: ${{ env.ASSET_NAME }}
path: .github/*.ipk
- name: Publishing to GitHub Releases
uses: floralatin/upload-release-action@3688e13ae053ba3052eb4f0cfe03e78deb8f88d7
if: github.event_name == 'release'
with:
repo_token: ${{ github.token }}
file: .github/*.ipk
tag: ${{ github.ref }}
file_glob: true