-
Notifications
You must be signed in to change notification settings - Fork 6
/
publish.sh
executable file
·50 lines (33 loc) · 885 Bytes
/
publish.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
#!/bin/sh
cd $(dirname $0)
mkdir target 2> /dev/null
cd target
rm -r publication 2> /dev/null
mkdir publication
cd publication
# x86_64-unknown-linux-gnu
echo 'do x86_64-unknown-linux-gnu'
mkdir ruga
cd ruga
(cd ../../../; cargo build --release)
cp ../../release/ruga .
cp -r ../../../README.md ../../../config.toml ../../../assets ../../../levels .
echo '''#!/bin/sh
cd $(dirname $0)
./ruga''' > launch.sh
chmod a+x launch.sh
cd ..
tar -czvf ruga_linux64.tar.gz ruga
rm -r ruga
echo 'done x86_64-unknown-linux-gnu'
# x86_64-pc-windows-gnu
echo 'do x86_64-pc-windows-gnu'
mkdir ruga
cd ruga
(cd ../../../; cargo build --release --target x86_64-pc-windows-gnu)
cp ../../x86_64-pc-windows-gnu/release/ruga.exe .
cp -r ../../../README.md ../../../config.toml ../../../assets ../../../levels .
cd ..
zip -r ruga_win64.zip ruga
rm -r ruga
echo 'done x86_64-pc-windows-gnu'