-
Notifications
You must be signed in to change notification settings - Fork 36
/
pack.sh
53 lines (39 loc) · 1.57 KB
/
pack.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
52
53
#!/bin/sh
VERSION=0.4.100
rm -rf artifacts
mkdir artifacts
echo ""
echo "///////////////////////////////////////////////"
echo "// Build IL2C.Interop"
echo ""
dotnet pack --configuration Release --include-symbols -p:VersionPrefix=${VERSION} IL2C.Interop/IL2C.Interop.csproj
cp IL2C.Interop/bin/Release/IL2C.Interop.${VERSION}.symbols.nupkg artifacts/IL2C.Interop.${VERSION}.nupkg
echo ""
echo "///////////////////////////////////////////////"
echo "// Build IL2C.Core"
echo ""
dotnet pack --configuration Release --include-symbols -p:VersionPrefix=${VERSION} IL2C.Core/IL2C.Core.csproj
cp IL2C.Core/bin/Release/IL2C.Core.${VERSION}.symbols.nupkg artifacts/IL2C.Core.${VERSION}.nupkg
echo ""
echo "///////////////////////////////////////////////"
echo "// Build IL2C.Runtime"
echo ""
.nuget/nuget pack -Prop version=${VERSION} -OutputDirectory artifacts IL2C.Runtime/IL2C.Runtime.nuspec
echo ""
echo "///////////////////////////////////////////////"
echo "// Build IL2C.Build"
echo ""
dotnet pack --configuration Release --include-symbols -p:VersionPrefix=${VERSION} IL2C.Tasks/IL2C.Tasks.csproj
cp IL2C.Tasks/bin/Release/IL2C.Build.${VERSION}.symbols.nupkg artifacts/IL2C.Build.${VERSION}.nupkg
echo ""
echo "///////////////////////////////////////////////"
echo "// Build Arduino library"
echo ""
mkdir artifacts/Arduino
cp /R IL2C.Runtime/include/*.h artifacts/Arduino/src/
cp /R IL2C.Runtime/src/*.h artifacts/Arduino/src/
cp /R IL2C.Runtime/src/*.c artifacts/Arduino/src/
sed 's/{version}/${VERSION}/g' Arduino.properties > artifacts/Arduino/library.properties
echo ""
echo "Done."
echo ""