forked from KSP-CKAN/CKAN
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·43 lines (35 loc) · 769 Bytes
/
build.sh
File metadata and controls
executable file
·43 lines (35 loc) · 769 Bytes
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
#!/bin/sh
set -e
arg0=""
remainingArgs=""
if [ $# -gt 0 ]; then
arg0="$1"
fi
if [ $# -gt 1 ]; then
skippedFirst=false
for i in "$@"; do
if $skippedFirst; then
remainingArgs="$remainingArgs $i"
else
skippedFirst=true
fi
done
fi
rootDir=$(dirname "$0")
scriptFile="$rootDir/build/Build.csproj"
cakeArgs=""
if [ -n "$arg0" ]; then
case $arg0 in
-*)
cakeArgs="$cakeArgs $arg0"
;;
*)
cakeArgs="$cakeArgs --target=$arg0"
;;
esac
fi
export PATH="$PATH:$HOME/.dotnet/tools"
export DOTNET_CLI_TELEMETRY_OPTOUT=true
# shellcheck disable=SC2086
dotnet run --project "$scriptFile" -- --verbosity Minimal $cakeArgs $remainingArgs
exit $?