CMake/Source/CPack
Brad King e1c7747253 Format include directive blocks and ordering with clang-format
Sort include directives within each block (separated by a blank line) in
lexicographic order (except to prioritize `sys/types.h` first).  First
run `clang-format` with the config file:

    ---
    SortIncludes: false
    ...

Commit the result temporarily.  Then run `clang-format` again with:

    ---
    SortIncludes: true
    IncludeCategories:
      - Regex:    'sys/types.h'
        Priority: -1
    ...

Commit the result temporarily.  Start a new branch and cherry-pick the
second commit.  Manually resolve conflicts to preserve indentation of
re-ordered includes.  This cleans up the include ordering without
changing any other style.

Use the following command to run `clang-format`:

    $ git ls-files -z -- \
        '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' |
      egrep -z -v '(Lexer|Parser|ParserHelper)\.' |
      egrep -z -v '^Source/cm_sha2' |
      egrep -z -v '^Source/(kwsys|CursesDialog/form)/' |
      egrep -z -v '^Utilities/(KW|cm).*/' |
      egrep -z -v '^Tests/Module/GenerateExportHeader' |
      egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' |
      xargs -0 clang-format -i

This selects source files that do not come from a third-party.

Inspired-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
2016-04-29 13:58:54 -04:00
..
IFW Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
WiX Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
OSXLauncherScript.scpt BUG: Fix issue #7833: Add file extension handling to CPack generated installers for OSXX11 applications. Also modify the X11 test to build such an installer on Mac builds that test CPack and have X11 available. Thanks to Wes Turner for the patch. 2009-01-21 11:54:30 -05:00
OSXScriptLauncher.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
bills-comments.txt Remove trailing whitespace from most CMake and C/C++ code 2012-08-13 14:18:39 -04:00
cmCPack7zGenerator.cxx cmake: Teach "-E tar" command a "--format=" option 2015-04-10 08:32:31 -04:00
cmCPack7zGenerator.h CPack: add generators for .7z and .tar.xz (#13072, #14519) 2014-07-29 09:48:41 -04:00
cmCPackArchiveGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackArchiveGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackBundleGenerator.cxx Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackBundleGenerator.h CPack: Add support for code signing of bundles on MacOS 2014-10-28 12:20:05 -06:00
cmCPackComponentGroup.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackComponentGroup.h stringapi: Miscellaneous char* parameters 2014-03-08 13:05:37 -05:00
cmCPackConfigure.h.in Convert CMake to OSI-approved BSD License 2009-09-28 11:43:28 -04:00
cmCPackCygwinBinaryGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackCygwinBinaryGenerator.h CPack: Refactor API in order to handle multi-file packages 2010-08-11 14:09:52 -04:00
cmCPackCygwinSourceGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackCygwinSourceGenerator.h CPack: Refactor API in order to handle multi-file packages 2010-08-11 14:09:52 -04:00
cmCPackDebGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackDebGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackDragNDropGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackDragNDropGenerator.h CPack/DragNDrop: Fix handling of certain license file content (#15899) 2016-01-07 15:24:42 -05:00
cmCPackGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackGeneratorFactory.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackGeneratorFactory.h strings: Remove cmStdString references 2014-03-08 13:05:35 -05:00
cmCPackLog.cxx Replace 'foo.size() > 0' pattern with !foo.empty(). 2015-01-18 14:25:24 +01:00
cmCPackLog.h Port all cmOStringStream to std::ostringstream. 2015-01-11 17:06:03 +01:00
cmCPackNSISGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackNSISGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackOSXX11Generator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackOSXX11Generator.h stringapi: Miscellaneous char* parameters 2014-03-08 13:05:37 -05:00
cmCPackPackageMakerGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackPackageMakerGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackRPMGenerator.cxx Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackRPMGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackSTGZGenerator.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cmCPackSTGZGenerator.h Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackTGZGenerator.cxx cmake: Teach "-E tar" command a "--format=" option 2015-04-10 08:32:31 -04:00
cmCPackTGZGenerator.h Switch to using libarchive from libtar for cpack and cmake -E tar 2009-10-30 13:10:56 -04:00
cmCPackTXZGenerator.cxx cmake: Teach "-E tar" command a "--format=" option 2015-04-10 08:32:31 -04:00
cmCPackTXZGenerator.h CPack: add generators for .7z and .tar.xz (#13072, #14519) 2014-07-29 09:48:41 -04:00
cmCPackTarBZip2Generator.cxx Source: Stabilize include order 2016-04-29 13:58:31 -04:00
cmCPackTarBZip2Generator.h Switch to using libarchive from libtar for cpack and cmake -E tar 2009-10-30 13:10:56 -04:00
cmCPackTarCompressGenerator.cxx cmake: Teach "-E tar" command a "--format=" option 2015-04-10 08:32:31 -04:00
cmCPackTarCompressGenerator.h Switch to using libarchive from libtar for cpack and cmake -E tar 2009-10-30 13:10:56 -04:00
cmCPackZIPGenerator.cxx cmake: Teach "-E tar" command a "--format=" option 2015-04-10 08:32:31 -04:00
cmCPackZIPGenerator.h Switch to using libarchive from libtar for cpack and cmake -E tar 2009-10-30 13:10:56 -04:00
cpack.cxx Format include directive blocks and ordering with clang-format 2016-04-29 13:58:54 -04:00
cygwin.readme Remove trailing whitespace from most CMake and C/C++ code 2012-08-13 14:18:39 -04:00