9191 sudo apt-get install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev
9292 sudo apt-get install clang
9393 - name : Build V
94- run : make -j4 && ./v -cg -cstrict -o v cmd/v && ./v test-cleancode
94+ run : make && ./v -cg -cstrict -o v cmd/v
95+ - name : Ensure code is well formatted
96+ run : ./v test-cleancode
9597 - name : Self tests (-fsanitize=undefined)
9698 run : ./v -cflags "-fsanitize=undefined" -o v2 cmd/v && ./v2 -cflags -fsanitize=undefined test-self
9799 - name : Build examples (V compiled with -fsanitize=undefined)
@@ -115,7 +117,9 @@ jobs:
115117 sudo apt-get install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
116118 sudo apt-get install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev
117119 - name : Build V
118- run : make -j4 && ./v -cg -cstrict -o v cmd/v && ./v test-cleancode
120+ run : make && ./v -cg -cstrict -o v cmd/v
121+ - name : Ensure code is well formatted
122+ run : ./v test-cleancode
119123 - name : Self tests (-fsanitize=undefined)
120124 run : ./v -cflags "-fsanitize=undefined" -o v2 cmd/v && ./v2 -cflags -fsanitize=undefined test-self
121125 - name : Build examples (V compiled with -fsanitize=undefined)
@@ -140,7 +144,9 @@ jobs:
140144 sudo apt-get install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev
141145 sudo apt-get install clang
142146 - name : Build V
143- run : make -j4 && ./v -cg -cstrict -o v cmd/v && ./v test-cleancode
147+ run : make && ./v -cg -cstrict -o v cmd/v
148+ - name : Ensure code is well formatted
149+ run : ./v test-cleancode
144150 - name : Self tests (-fsanitize=address)
145151 run : ASAN_OPTIONS=detect_leaks=0 ./v -cflags "-fsanitize=address,pointer-compare,pointer-subtract" test-self
146152 - name : Self tests (V compiled with -fsanitize=address)
@@ -168,7 +174,11 @@ jobs:
168174 echo $VFLAGS
169175 .\make.bat -msvc
170176 .\v.exe self
171- .\v.exe test-cleancode
177+ - name : Ensure code is well formatted
178+ run : |
179+ .\v.exe fmt -verify vlib/builtin/ vlib/v/scanner/ vlib/v/parser/ vlib/v/gen/
180+ # # TODO: check to see why `v test-cleancode` does not work with msvc on windows
181+
172182 # # - name: Install dependencies
173183 # # run: |
174184 # # .\v.exe setup-freetype
@@ -196,7 +206,9 @@ jobs:
196206 sudo apt-get install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev
197207 sudo apt-get install clang
198208 - name : Build V
199- run : make -j4 && ./v -cg -cstrict -o v cmd/v && ./v test-cleancode
209+ run : make && ./v -cg -cstrict -o v cmd/v
210+ - name : Ensure code is well formatted
211+ run : ./v test-cleancode
200212 - name : Self tests (-fsanitize=address)
201213 run : ASAN_OPTIONS=detect_leaks=0 ./v -cflags -fsanitize=address test-self
202214 - name : Self tests (V compiled with -fsanitize=address)
@@ -225,11 +237,14 @@ jobs:
225237 sudo apt-get install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev
226238 sudo apt-get install clang
227239 - name : Build V
228- run : make -j4 && ./v -cc clang -cg -cstrict -o v cmd/v && ./v test-cleancode
240+ run : make && ./v -cc clang -cg -cstrict -o v cmd/v
241+ - name : Ensure code is well formatted
242+ run : ./v test-cleancode
229243 - name : Self tests (-fsanitize=memory)
230244 run : ./v -cflags -fsanitize=memory test-self
231245 - name : Self tests (V compiled with -fsanitize=memory)
232- run :
233- ./v -cflags -fsanitize=memory -o v cmd/v && ./v -cc tcc test-self -msan-compiler
246+ run : |
247+ ./v -cflags -fsanitize=memory -o v cmd/v
248+ ./v -cc tcc test-self -msan-compiler
234249 - name : Build examples (V compiled with -fsanitize=memory)
235250 run : ./v build-examples
0 commit comments