forked from threema-ch/threema-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gather-licenses.sh
51 lines (48 loc) · 2.25 KB
/
gather-licenses.sh
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
#!/usr/bin/env bash
set -euo pipefail
LICENSE_FILES=(
'angular' 'node_modules/angular/LICENSE.md'
'angular-animate' 'node_modules/angular-animate/LICENSE.md'
'angular-aria' 'node_modules/angular-aria/LICENSE.md'
'angular-inview' 'public/libs/angular-inview/LICENSE'
'angular-material' 'node_modules/angular-material/LICENSE'
'angular-messages' 'node_modules/angular-messages/LICENSE.md'
'angular-qrcode' 'public/libs/angular-qrcode/LICENCE.txt'
'angular-route' 'node_modules/angular-route/LICENSE.md'
'angular-sanitize' 'node_modules/angular-sanitize/LICENSE.md'
'angular-translate' 'node_modules/angular-translate/LICENSE'
'angular-ui-router' 'node_modules/@uirouter/angularjs/LICENSE'
'angularjs-scroll-glue' 'node_modules/angularjs-scroll-glue/src/LICENSE'
'autolinker' 'node_modules/autolinker/LICENSE'
'babel-runtime' 'node_modules/@babel/runtime/LICENSE'
'croppie' 'node_modules/croppie/LICENSE'
'emojibase-regex' 'node_modules/emojibase-regex/LICENSE'
'file-saver' 'node_modules/file-saver/LICENSE.md'
'messageformat' 'node_modules/messageformat/LICENSE'
'msgpack-lite' 'node_modules/msgpack-lite/LICENSE'
'node-sass' 'node_modules/node-sass/LICENSE'
'qrcode-generator' '.licenses/qrcode-generator'
'saltyrtc-client' 'node_modules/@saltyrtc/client/LICENSE.md'
'saltyrtc-task-relayed-data' 'node_modules/@saltyrtc/task-relayed-data/LICENSE.md'
'saltyrtc-task-webrtc' 'node_modules/@saltyrtc/task-webrtc/LICENSE.md'
'sdp' 'node_modules/sdp/LICENSE'
'ts-events' 'node_modules/ts-events/LICENSE'
'ts-loader' 'node_modules/ts-loader/LICENSE'
'ts-log' 'node_modules/ts-log/LICENSE'
'tweetnacl' 'node_modules/tweetnacl/LICENSE'
'twemoji' '.licenses/twemoji'
'typescript' 'node_modules/typescript/LICENSE.txt'
'webrtc-adapter' 'node_modules/webrtc-adapter/LICENSE.md'
)
FILE=LICENSE-3RD-PARTY.txt
echo -e "Licenses for third party libraries in Threema Web:\n\n\n\n" > $FILE
for i in ${!LICENSE_FILES[@]}; do
if (( $i % 2 == 0 )); then
echo -e "----------" >> $FILE
echo -e "License for ${LICENSE_FILES[$i]}" >> $FILE
echo -e "----------\n" >> $FILE
else
cat "${LICENSE_FILES[$i]}" >> $FILE
echo -e "\n\n\n" >> $FILE
fi
done