aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2023-01-15 19:30:17 +0100
committerGitHub <noreply@github.com>2023-01-15 19:30:17 +0100
commit69c71c4ab44d0bf9fe5f6b6066ad5c269d1507b8 (patch)
tree070140e60dca62c7a09b35b83eaefd917c08c497
parentc752c853630898f38bcf46a9a5e9d83e41989eeb (diff)
downloadrneovim-69c71c4ab44d0bf9fe5f6b6066ad5c269d1507b8.tar.gz
rneovim-69c71c4ab44d0bf9fe5f6b6066ad5c269d1507b8.tar.bz2
rneovim-69c71c4ab44d0bf9fe5f6b6066ad5c269d1507b8.zip
build: exclude tui/terminfo_defs.h from lintc-clint (#21822)
clint takes around 5-10 seconds to lint tui/terminfo_defs.h. For CI this is negligible, but it's annoying for local development as touching terminfo_defs.h will skyrocket lint times. Furthermore, we have no reason to touch or modify terminfo_defs.h as it's a generated file, so linting it shouldn't be necessary. This should speed up "make lint" by the same amount, so around 5-10 seconds.
-rw-r--r--cmake/Util.cmake7
-rwxr-xr-xsrc/nvim/CMakeLists.txt4
2 files changed, 7 insertions, 4 deletions
diff --git a/cmake/Util.cmake b/cmake/Util.cmake
index a86ced89d6..e15b44d29a 100644
--- a/cmake/Util.cmake
+++ b/cmake/Util.cmake
@@ -79,12 +79,13 @@ function(add_glob_target)
file(TO_CMAKE_PATH "${f}" f)
list(APPEND globfiles ${f})
endforeach()
- foreach(exclude_pattern ${ARG_EXCLUDE})
- list(FILTER globfiles EXCLUDE REGEX ${exclude_pattern})
- endforeach()
list(APPEND ARG_FILES ${globfiles})
endforeach()
+ foreach(exclude_pattern ${ARG_EXCLUDE})
+ list(FILTER ARG_FILES EXCLUDE REGEX ${exclude_pattern})
+ endforeach()
+
if(NOT ARG_TOUCH_STRATEGY)
set(ARG_TOUCH_STRATEGY PER_FILE)
endif()
diff --git a/src/nvim/CMakeLists.txt b/src/nvim/CMakeLists.txt
index bcaf372962..316f12e302 100755
--- a/src/nvim/CMakeLists.txt
+++ b/src/nvim/CMakeLists.txt
@@ -977,7 +977,9 @@ add_glob_target(
TARGET lintc-clint
COMMAND ${PROJECT_SOURCE_DIR}/src/clint.py
FLAGS --output=${LINT_OUTPUT_FORMAT}
- FILES ${LINT_NVIM_SOURCES})
+ FILES ${LINT_NVIM_SOURCES}
+ EXCLUDE
+ tui/terminfo_defs.h)
add_custom_target(uncrustify-version
COMMAND ${CMAKE_COMMAND}