Add a tool to follow KDE cmake coding style with regard to end commands
Removes the predicate from all of them, especially on else it was very annoying. http://techbase.kde.org/Policies/CMake_Coding_Style#End_commands
This commit is contained in:
parent
d56f690fcf
commit
19d6fab067
6
tools/port-cmake-style.sh
Normal file
6
tools/port-cmake-style.sh
Normal file
@ -0,0 +1,6 @@
|
||||
for FS in `find $PWD -type f -name 'CMakeLists.txt'`; do
|
||||
#removes the predicate of endif and else in cmake
|
||||
# http://techbase.kde.org/Policies/CMake_Coding_Style#End_commands
|
||||
perl -p -i -e 's/endif( *)\(.*\)/endif\1()/g' $FS
|
||||
perl -p -i -e 's/else( *)\(.*\)/else\1()/g' $FS
|
||||
done
|
Loading…
Reference in New Issue
Block a user