forked from mapbox/mapbox-unity-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
update-mapbox-unity-sdk-core.sh
executable file
·48 lines (37 loc) · 1.52 KB
/
update-mapbox-unity-sdk-core.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
#!/usr/bin/env bash
set -eu
echo "fetching submodules..."
git submodule update --init --recursive
SDK_PATH=sdkproject/Assets/Mapbox/Core
echo "deleting existing plugins..."
if [ -d "$SDK_PATH/Plugins/Mapbox" ]; then rm -rf $SDK_PATH/Plugins/Mapbox; fi
if [ -d "$SDK_PATH/Plugins/ThirdParty" ]; then rm -rf $SDK_PATH/Plugins/ThirdParty; fi
# exclude copying these files
echo "*project.json" >> x.txt
echo "*project.lock.json" >> x.txt
echo "*.csproj" >> x.txt
echo "*.snk" >> x.txt
echo "*packages.config" >> x.txt
echo "*AssemblyInfoVersion.cs" >> x.txt
echo "*SharedAssemblyInfo.cs" >> x.txt
echo "Properties" >> x.txt
echo "Documentation" >> x.txt
echo "Mono" >> x.txt
echo "Bench" >> x.txt
echo "DemoConsoleApp" >> x.txt
echo "VectorTiles.Tests" >> x.txt
echo "VerifyNetFrameworkVersion" >> x.txt
echo "copying vector-tile-cs..."
mkdir -p $SDK_PATH/Plugins/Mapbox/vector-tile-cs/
rsync -av --exclude-from=x.txt ./dependencies/vector-tile-cs/src/ $SDK_PATH/Plugins/Mapbox/vector-tile-cs/
echo "copying Mapbox.IO.Compression..."
mkdir -p $SDK_PATH/Plugins/ThirdParty/Mapbox.IO.Compression/
rsync -av --exclude-from=x.txt ./dependencies/Mapbox.IO.Compression-unity/src/Mapbox.IO.Compression.Shared/ $SDK_PATH/Plugins/ThirdParty/Mapbox.IO.Compression/
echo "copying Mapbox.Json..."
mkdir -p $SDK_PATH/Plugins/ThirdParty/Mapbox.Json/
rsync -av --exclude-from=x.txt ./dependencies/Mapbox.Json/ $SDK_PATH/Plugins/ThirdParty/Mapbox.Json/
echo "copying aux files..."
cp -v ./utils/link.xml $SDK_PATH/Plugins/
echo "cleaning up..."
rm x.txt
echo "DONE"