-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathaction.yml
42 lines (42 loc) · 1.11 KB
/
action.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
name: "UmBox box upload"
description: "Automatically builds an UmBox Box and uploads it to the repo"
inputs:
dir:
description: "Directory containing the box.json"
required: false
default: "."
secret:
decription: "UmBox secret"
required: true
debug:
description: "Enable debug mode"
required: false
default: "false"
runs:
using: "composite"
steps:
- name: Setup UmBox
shell: bash
run: |
cd ${{ inputs.dir }}
sudo apt install -y curl unzip zip nsis rsync
curl https://mrms.cz/dl/umbox/umbox_linux.zip -O
unzip umbox_linux.zip
- name: Build
shell: bash
run: |
cd ${{ inputs.dir }}
if [ "${{ inputs.debug }}" == "true" ]; then
./umbox_linux/umbox build -d
else
./umbox_linux/umbox build
fi
- name: Upload
shell: bash
run: |
cd ${{ inputs.dir }}
if [ "${{ inputs.debug }}" == "true" ]; then
./umbox_linux/umbox upload -d ${{ inputs.secret }} box.tar
else
./umbox_linux/umbox upload ${{ inputs.secret }} box.tar
fi