This repository has been archived by the owner on Dec 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 56
/
create_app.command
executable file
·71 lines (51 loc) · 2.19 KB
/
create_app.command
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
# Legacy Video patch
# (c) Copyright 2020 chris1111
# This will create a Apple Bundle App Legacy Video patch
# Dependencies: osacompile
PARENTDIR=$(dirname "$0")
cd "$PARENTDIR"
# Declare some VARS
APP_NAME="Legacy Video patch.app"
SOURCE_SCRIPT="Legacy Video patch.applescript"
echo "= = = = = = = = = = = = = = = = = = = = = = = = = "
echo " Create Legacy Video patch"
echo "= = = = = = = = = = = = = = = = = = = = = = = = = "
# See if the app is already exist
if [ -d "${3}./Legacy Video patch.app" ]; then
rm -rf "${3}./Legacy Video patch.app"
fi
if [ -d "${3}./BUILD/Legacy Video patch.app" ]; then
rm -rf "${3}./BUILD/Legacy Video patch.app"
fi
Sleep 2
# Create the dir structure
/usr/bin/osacompile -o ./BUILD/"$APP_NAME" "$SOURCE_SCRIPT"
# Copy icon to the right place
cp -rp ./Icon/droplet.icns ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Icon/Badge.tiff ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Icon/DocumentIcon.png ./BUILD/"$APP_NAME"/Contents/Resources
# Copy Legacy Video Patch
./Sources/rsync -av ./Kexts-Bundle/* ./BUILD/"$APP_NAME"/Contents/Resources/Scripts/
# Change icons, delete droplet
./Icon/icon.py ./droplet.icns ./BUILD/"$APP_NAME"
rm -rf ./BUILD/"$APP_NAME"/Contents/MacOS/droplet
# Copy source
cp -rp ./Sources/Info.plist ./BUILD/"$APP_NAME"/Contents
cp -r ./Sources/Frameworks ./BUILD/"$APP_NAME"/Contents
cp -r ./Sources/MacOS/FancyDroplet ./BUILD/"$APP_NAME"/Contents/MacOS
cp -r ./Sources/recovery.rtf ./BUILD/"$APP_NAME"/Contents/Resources/Scripts
cp -r ./Sources/POST ./BUILD/"$APP_NAME"/Contents/Resources/Scripts
cp -r ./Sources/en.lproj ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Sources/Base.lproj ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Sources/Assets.car ./BUILD/"$APP_NAME"/Contents/Resources
cp -rp ./Sources/description.rtfd ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Sources/License.rtf ./BUILD/"$APP_NAME"/Contents/Resources
cp -r ./Sources/Credits.rtf ./BUILD/"$APP_NAME"/Contents/Resources
Sleep 2
# Avoid issue opening the app
mv ./BUILD/"$APP_NAME" ./"$APP_NAME"
Sleep 2
xattr -cr ./"$APP_NAME"
echo " = = = = = = = = = = = = = = = = = = = = = = = = =
Legacy Video patch completed Done!
= = = = = = = = = = = = = = = = = = = = = = = = = "