Browse Source

Enable auto-formatting in commit-hook.

pull/2990/head
Daniel Grunwald 2 years ago
parent
commit
c2490d79ec
  1. 10
      BuildTools/pre-commit

10
BuildTools/pre-commit

@ -12,9 +12,9 @@ if [ ! -d "$DOTNET_PATH" ]; then
fi fi
"$DOTNET_PATH/dotnet-format.exe" --version "$DOTNET_PATH/dotnet-format.exe" --version
#if git diff --quiet --ignore-submodules; then if git diff --quiet --ignore-submodules; then
# "$DOTNET_PATH/dotnet-format.exe" whitespace --no-restore --verbosity detailed ILSpy.sln "$DOTNET_PATH/dotnet-format.exe" whitespace --no-restore --verbosity detailed ILSpy.sln
# git add -u -- \*\*.cs git add -u -- \*\*.cs
#else else
exec "$DOTNET_PATH/dotnet-format.exe" whitespace --verify-no-changes --no-restore --verbosity detailed ILSpy.sln exec "$DOTNET_PATH/dotnet-format.exe" whitespace --verify-no-changes --no-restore --verbosity detailed ILSpy.sln
#fi fi

Loading…
Cancel
Save