summaryrefslogtreecommitdiff
path: root/misc/scripts/dotnet_format.sh
diff options
context:
space:
mode:
authorRaul Santos <raulsntos@gmail.com>2022-10-12 15:55:10 +0200
committerRaul Santos <raulsntos@gmail.com>2022-10-12 15:55:10 +0200
commit7def4c84be2c0a7051cd76ffef247017ae76c586 (patch)
treea3867968dbfe31fc1dbed37bba8aa5f5c651780c /misc/scripts/dotnet_format.sh
parent143dbb354411e5f669e0f751f1254d03f531d576 (diff)
Fix dotnet format
It was failing due to generated files being referenced in .NET projects but the files are missing because they are generated by `godot --generate-mono-glue` or `build_assemblies.py`.
Diffstat (limited to 'misc/scripts/dotnet_format.sh')
-rwxr-xr-xmisc/scripts/dotnet_format.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/misc/scripts/dotnet_format.sh b/misc/scripts/dotnet_format.sh
index 645737f419..cc34137a37 100755
--- a/misc/scripts/dotnet_format.sh
+++ b/misc/scripts/dotnet_format.sh
@@ -5,6 +5,13 @@
set -uo pipefail
+# Create dummy generated files.
+echo "<Project />" > modules/mono/SdkPackageVersions.props
+mkdir -p modules/mono/glue/GodotSharp/GodotSharp/Generated
+echo "<Project />" > modules/mono/glue/GodotSharp/GodotSharp/Generated/GeneratedIncludes.props
+mkdir -p modules/mono/glue/GodotSharp/GodotSharpEditor/Generated
+echo "<Project />" > modules/mono/glue/GodotSharp/GodotSharpEditor/Generated/GeneratedIncludes.props
+
# Loops through all C# projects tracked by Git.
git ls-files -- '*.csproj' \
':!:.git/*' ':!:thirdparty/*' ':!:platform/android/java/lib/src/com/google/*' ':!:*-so_wrap.*' |