cmd_restore # restore first
local OPTS=""
[ -n "$CONFIGURATION" ] && OPTS="$OPTS -c $CONFIGURATION"
- [ -n "$VERSION" ] && OPTS="$OPTS /p:Version=$VERSION"
run_dotnet build $PROJECT $OPTS $@
else
if [[ $PROJECT_TYPE == "dir" ]]; then
}
cmd_pack() {
+ local OPTS=""
if $USE_DOTNET_CLI; then
- local OPTS=""
[ -n "$CONFIGURATION" ] && OPTS="$OPTS -c $CONFIGURATION"
[ -n "$VERSION" ] && OPTS="$OPTS /p:Version=$VERSION"
run_dotnet pack $PROJECT $OPTS $@
if [ -d $PROJECT ]; then
NUSPEC=($(find $PROJECT -name "*.nuspec"))
fi
+ [ -n "$CONFIGURATION" ] && OPTS="$OPTS -Properties Configuration=$CONFIGURATION"
+ [ -n "$VERSION" ] && OPTS="$OPTS -Version $VERSION"
for x in ${NUSPEC[@]}; do
- run_nuget pack $x -Version $VERSION -Properties Configuration=$CONFIGURATION $@
+ run_nuget pack $x $OPTS $@
done
fi
}
%_with_corefx 1
%_dotnet_assembly_path /usr/share/dotnet.tizen/framework
-%_dotnet_nuget_source /nuget
+%_dotnet_nuget_source /nuget
###############################################################
%_nuget_package \
%{nil}
-%dotnet_restore() \
-dotnet-build -s %{_dotnet_nuget_source} restore %{1} %{?2} %{?3} %{?4} %{?5} %{?6} \
+%dotnet_restore(s:) \
+dotnet-build -s %{-s:%{-s*}}%{!-s:%{_dotnet_nuget_source}} restore %{1} %{?2} %{?3} %{?4} %{?5} %{?6} \
%{nil}
-%dotnet_build() \
-dotnet-build -c %{_dotnet_build_conf} -s %{_dotnet_nuget_source} build %{1} %{?2} %{?3} %{?4} %{?5} %{?6} \
+%dotnet_build(s:) \
+dotnet-build -c %{_dotnet_build_conf} -s %{-s:%{-s*}}%{!-s:%{_dotnet_nuget_source}} build %{1} %{?2} %{?3} %{?4} %{?5} %{?6} \
%{nil}
%dotnet_pack() \