Skip to content

Commit 45ee40a

Browse files
committed
change checks
1 parent fb7892a commit 45ee40a

File tree

2 files changed

+13
-14
lines changed

2 files changed

+13
-14
lines changed

.github/workflows/win-build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ jobs:
3131
- name: Build and test
3232
run: just
3333

34+
- name: Check diff
35+
run: just check-diff
36+
3437
- name: Locate nupkg
3538
id: pkg
3639
run: just locate-nupkg $env:GITHUB_OUTPUT

justfile

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -53,26 +53,22 @@ test-all: build-tests
5353
locate-nupkg GITHUB_OUTPUT:
5454
echo "package=$(find . -name "Rubjerg.Graphviz.*.nupkg" | head -1)" >> "{{GITHUB_OUTPUT}}"
5555

56-
# Check for CRLF line endings
57-
check-line-endings:
56+
# Normalize line endings to crlf
57+
crlf:
5858
bash -c "git ls-files -- ':!GraphvizWrapper/graphvizfiles/*' ':!*.sh' | xargs unix2dos"
59-
git diff --exit-code
60-
61-
# Check if README.md is up to date
62-
check-readme:
63-
git diff --exit-code -- README.md
6459

65-
# Check formatting in main solution
66-
check-format-main:
67-
dotnet format whitespace --verify-no-changes -v diag Rubjerg.Graphviz.sln
60+
# Format the code
61+
format:
62+
dotnet format whitespace -v diag Rubjerg.Graphviz.sln
63+
dotnet format whitespace -v diag Rubjerg.Graphviz.Tests.sln
6864

69-
# Check formatting in test solution
70-
check-format-tests:
71-
dotnet format whitespace --verify-no-changes -v diag Rubjerg.Graphviz.Tests.sln
65+
# Check that none of the actions generated a diff
66+
check-diff:
67+
git diff --exit-code
7268

7369
# Check for unfinished work
7470
check-fixme:
7571
bash -c "! git grep 'FIX''NOW'"
7672

77-
check-all: check-line-endings check-readme check-format-main check-format-tests check-fixme
73+
check-all: crlf format check-diff check-fixme
7874

0 commit comments

Comments
 (0)