This commit is contained in:
Archi
2021-11-29 09:56:43 +01:00
parent a049bf39d6
commit d64669d563

7
cc.sh
View File

@@ -112,7 +112,8 @@ if [ "$ASF_UI" -eq 1 ]; then
fi
fi
DOTNET_FLAGS="-c $CONFIGURATION -f $TARGET_FRAMEWORK -p:ContinuousIntegrationBuild=true -p:UseAppHost=false -r ${os_type}-${cpu_architecture} --nologo --no-self-contained"
DOTNET_FLAGS="-c $CONFIGURATION -f $TARGET_FRAMEWORK -p:ContinuousIntegrationBuild=true -p:UseAppHost=false --nologo"
PUBLISH_FLAGS="-r ${os_type}-${cpu_architecture} --no-self-contained"
if [ "$ANALYSIS" -eq 0 ]; then
DOTNET_FLAGS="$DOTNET_FLAGS -p:AnalysisMode=AllDisabledByDefault"
@@ -131,14 +132,14 @@ if [ "$TEST" -eq 1 ]; then
dotnet test "$TESTS_PROJECT" $DOTNET_FLAGS
fi
dotnet publish "$MAIN_PROJECT" -o "$OUT_ASF" $DOTNET_FLAGS
dotnet publish "$MAIN_PROJECT" -o "$OUT_ASF" $DOTNET_FLAGS $PUBLISH_FLAGS
if [ -n "${STEAM_TOKEN_DUMPER_TOKEN-}" ] && [ -f "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs" ] && command -v git >/dev/null; then
git checkout -- "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs"
sed "s/STEAM_TOKEN_DUMPER_TOKEN/${STEAM_TOKEN_DUMPER_TOKEN}/g" "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs" > "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs.new";
mv "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs.new" "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs"
dotnet publish "$STEAM_TOKEN_DUMPER_NAME" -o "$OUT_STD" $DOTNET_FLAGS
dotnet publish "$STEAM_TOKEN_DUMPER_NAME" -o "$OUT_STD" $DOTNET_FLAGS $PUBLISH_FLAGS
git checkout -- "${STEAM_TOKEN_DUMPER_NAME}/SharedInfo.cs"
rm -rf "${OUT_ASF}/plugins/${STEAM_TOKEN_DUMPER_NAME}"