forked from xMasterX/all-the-plugins
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.drone.yml
124 lines (116 loc) · 3.89 KB
/
.drone.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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
kind: pipeline
type: docker
name: "Build apps"
platform:
os: linux
arch: amd64
steps:
- name: "Update submodules"
image: alpine/git
commands:
- git submodule sync
- git -c protocol.version=2 submodule update --init --force --recursive --jobs 4
- git submodule foreach git config --local gc.auto 0
- git log -1 --format='%H'
- name: "Build base pack"
image: hfdj/fztools
pull: never
commands:
- git clone --branch dev https://github.com/DarkFlippers/unleashed-firmware.git
- rm -rf unleashed-firmware/assets/resources/apps/
- rm -rf unleashed-firmware/build/
- rm -rf unleashed-firmware/dist/
- rm -rf unleashed-firmware/.sconsign.dblite
- mv base_pack/* unleashed-firmware/applications_user/
- ./parse_api_ver.sh
- cd unleashed-firmware
- ./fbt COMPACT=1 DEBUG=0 updater_package
- mkdir artifacts-base
- mv assets/resources/apps/* artifacts-base/
- ls -laS artifacts-base
- rm -f artifacts-base/GPIO/gpio.fap
- rm -f artifacts-base/iButton/ibutton.fap
- rm -f artifacts-base/Infrared/infrared.fap
- rm -f artifacts-base/NFC/nfc.fap
- rm -f artifacts-base/RFID/lfrfid.fap
- rm -f artifacts-base/Sub-Ghz/subghz_remote.fap
- rm -f artifacts-base/Tools/clock.fap
- rm -f artifacts-base/USB/bad_usb.fap
- rm -f artifacts-base/USB/u2f.fap
- cd ..
- mkdir base_pack_build
- mv unleashed-firmware/artifacts-base/ base_pack_build
environment:
FBT_TOOLS_CUSTOM_LINK:
from_secret: fbt_link
- name: "Build extra apps"
image: hfdj/fztools
pull: never
commands:
- rm -rf unleashed-firmware/assets/resources/apps/
- rm -rf unleashed-firmware/build/
- rm -rf unleashed-firmware/dist/
- rm -rf unleashed-firmware/.sconsign.dblite
- rm -rf unleashed-firmware/applications_user/*
- mv apps_source_code/* unleashed-firmware/applications_user/
- mv non_catalog_apps/* unleashed-firmware/applications_user/
- cd unleashed-firmware
- ./fbt COMPACT=1 DEBUG=0 updater_package
- mkdir artifacts-extra
- mv assets/resources/apps/* artifacts-extra/
- ls -laS artifacts-extra
- rm -f artifacts-extra/GPIO/gpio.fap
- rm -f artifacts-extra/iButton/ibutton.fap
- rm -f artifacts-extra/Infrared/infrared.fap
- rm -f artifacts-extra/NFC/nfc.fap
- rm -f artifacts-extra/RFID/lfrfid.fap
- rm -f artifacts-extra/Sub-Ghz/subghz_remote.fap
- rm -f artifacts-extra/Tools/clock.fap
- rm -f artifacts-extra/USB/bad_usb.fap
- rm -f artifacts-extra/USB/u2f.fap
- cd ..
- mkdir extra_pack_build
- mv unleashed-firmware/artifacts-extra/ extra_pack_build
environment:
FBT_TOOLS_CUSTOM_LINK:
from_secret: fbt_link
- name: "Bundle packages"
image: kramos/alpine-zip
commands:
- zip -r all-the-apps-extra.zip extra_pack_build
- zip -r all-the-apps-base.zip base_pack_build
- tar czpf all-the-apps-extra.tgz extra_pack_build
- tar czpf all-the-apps-base.tgz base_pack_build
- mkdir ${DRONE_TAG}
- mv all-the-apps-extra.zip ${DRONE_TAG}/
- mv all-the-apps-base.zip ${DRONE_TAG}/
- mv all-the-apps-extra.tgz ${DRONE_TAG}/
- mv all-the-apps-base.tgz ${DRONE_TAG}/
- rm -rf extra_pack_build
- rm -rf base_pack_build
- rm -rf unleashed-firmware
- ls -laS
- ls -laS ${DRONE_TAG}
- name: "Do Github release"
image: ddplugins/github-release
pull: never
settings:
github_url: https://github.com
repo_owner:
from_secret: github_repoowner
api_key:
from_secret: github_apikey
files:
- ${DRONE_TAG}/*.tgz
- ${DRONE_TAG}/*.zip
title: ${DRONE_TAG}
note: CHANGELOG.md
checksum:
- md5
- sha1
- crc32
trigger:
event:
- tag
node:
typ: haupt