forked from fsprojects/Paket
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
executable file
·45 lines (41 loc) · 1.29 KB
/
build.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
#!/usr/bin/env bash
if test "$OS" = "Windows_NT"
then
# use .Net
.paket/paket.bootstrapper.exe prerelease
exit_code=$?
if [ $exit_code -ne 0 ]; then
exit $exit_code
fi
.paket/paket.exe restore
exit_code=$?
if [ $exit_code -ne 0 ]; then
exit $exit_code
fi
packages/build/FAKE/tools/FAKE.exe $@ --fsiargs -d:MONO build.fsx
else
# use mono
mono .paket/paket.bootstrapper.exe prerelease
exit_code=$?
if [ $exit_code -ne 0 ]; then
certificate_count=$(certmgr -list -c Trust | grep X.509 | wc -l)
if [ $certificate_count -le 1 ]; then
echo "Couldn't download Paket. This might be because your Mono installation"
echo "doesn't have the right SSL root certificates installed. One way"
echo "to fix this would be to download the list of SSL root certificates"
echo "from the Mozilla project by running the following command:"
echo ""
echo " mozroots --import --sync"
echo ""
echo "This will import over 100 SSL root certificates into your Mono"
echo "certificate repository. Then try running the build script again."
fi
exit $exit_code
fi
mono .paket/paket.exe restore
exit_code=$?
if [ $exit_code -ne 0 ]; then
exit $exit_code
fi
mono packages/build/FAKE/tools/FAKE.exe $@ --fsiargs -d:MONO build.fsx
fi