Skip to content

Commit

Permalink
[fix] Correct bug in gitdiff finder
Browse files Browse the repository at this point in the history
If CmakeLists.txt contains more than one error including one on WS_PATH,
the other errors are not taken into account.
+ Correct NabLabTests/CMakeLists.txt

Signed-off-by: Marie-Pierre Oudot <[email protected]>
  • Loading branch information
mpoudot committed Oct 12, 2022
1 parent a538603 commit 033d13a
Show file tree
Hide file tree
Showing 10 changed files with 12 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(HydroRemap LANGUAGES CXX)
project(HydroRemap LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Iteration LANGUAGES CXX)
project(Iteration LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Variables LANGUAGES CXX)
project(Variables LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(HydroRemap LANGUAGES CXX)
project(HydroRemap LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Iteration LANGUAGES CXX)
project(Iteration LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Variables LANGUAGES CXX)
project(Variables LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(HydroRemap LANGUAGES CXX)
project(HydroRemap LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Iteration LANGUAGES CXX)
project(Iteration LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if (NOT DEFINED Arcane_ROOT)
message(FATAL_ERROR "Arcane_ROOT variable must be set")
endif()

project(Variables LANGUAGES CXX)
project(Variables LANGUAGES C CXX)

find_package(Arcane REQUIRED)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class GitUtils
val formatter = new DiffFormatter(outputStream)
formatter.setRepository(git.repository)
formatter.setPathFilter(PathFilter.create(subPath))
//context = number of lines of context to see before the first modification and after the last modification within a hunk of the modified file.
//in case of multiple errors, whe get several @@
formatter.setContext(0)

var diffs = formatter.scan(workingTreeIterator, headTreeParser)
diffs = diffs.filter[d | d.newPath.contains(moduleName)].toList
Expand Down

0 comments on commit 033d13a

Please sign in to comment.