63
|
1 #!/bin/bash
|
|
2 set -e
|
|
3
|
|
4 cd "$(dirname $0)/../.."
|
|
5
|
|
6 ./build.sh
|
|
7
|
|
8 cd build
|
|
9
|
|
10 mkdir mac
|
|
11 mkdir mac/Luan_Editor.app
|
|
12 mkdir mac/Luan_Editor.app/Contents
|
|
13 mkdir mac/Luan_Editor.app/Contents/MacOS
|
|
14 mkdir mac/Luan_Editor.app/Contents/Resources
|
|
15 mkdir mac/Luan_Editor.app/Contents/Resources/CLI
|
|
16
|
|
17 cp ../scripts/mac/Info.plist mac/Luan_Editor.app/Contents
|
|
18 cp ../scripts/mac/launcher mac/Luan_Editor.app/Contents/MacOS
|
|
19 cp ../scripts/mac/install.sh mac/Luan_Editor.app/Contents/Resources/CLI
|
|
20 cp ../scripts/mac/uninstall.sh mac/Luan_Editor.app/Contents/Resources/CLI
|
|
21 cp -r luan_editor/jars mac/Luan_Editor.app/Contents/Resources
|
|
22 cp -r luan_editor/dictionaries mac/Luan_Editor.app/Contents/Resources
|
|
23
|
|
24 create-dmg \
|
|
25 --volname "Luan Editor" \
|
|
26 --window-pos 200 120 \
|
|
27 --window-size 500 300 \
|
|
28 --icon-size 100 \
|
|
29 --icon "Luan_Editor.app" 100 100 \
|
|
30 --app-drop-link 380 100 \
|
|
31 "Luan_Editor.dmg" \
|
|
32 "mac/"
|
|
33
|
|
34 cp Luan_Editor.dmg ../website/src/download
|
|
35
|
|
36 echo "finished mac build"
|