Commit Graph

24 Commits

Author SHA1 Message Date
Adriaan de Groot
f496570df4 CI: accept more clang-format versions 2023-10-24 14:55:24 +02:00
Adriaan de Groot
945180e1d3 CI: accept clang-format-16 as well 2023-10-21 16:22:37 +02:00
Adriaan de Groot
183f88a846 CI: Document changed coding style 2023-10-17 21:44:33 +02:00
Adriaan de Groot
fc8e5fb5c7 CI: forbid clang-format-14 2022-05-18 12:55:15 +02:00
Adriaan de Groot
56071c4016 CI: acceptable clang-format versions 2022-05-18 12:22:51 +02:00
Adriaan de Groot
9dd2f275f1 CI: allow clang-format naming according to Debian 2022-02-21 12:27:59 +01:00
Adriaan de Groot
c4eee7bb11 CI: demand clang-format 12 or 13
- use clang-format12 or 13 or unversioned executable, only
- check it's actually 12 or 13
- set language standard explicitly to C++17, "Cpp11" is now
  an alias for "latest" which is weird

This change does lead to some thrashing when applying styles,
so I'm not going to do that across the board right now. Changes include:
- extra spaces in lambda-captures
- nicer alignment of lambda-bodies
2022-02-01 16:23:39 +01:00
Adriaan de Groot
154396f80a CI: drop support for clang-format10 and later
The only acceptable versions of clang-format are 8 and 9 for now
(until another round of big-churn-from-formatting, at which point
we'll update the required version).

clang-format-9 says:

    SpacesInSquareBrackets (bool)
      If true, spaces will be inserted after [ and before ]. Lambdas
      or unspecified size array declarations will not be affected.

clang-format-10 changes part of that to:

      Lambdas without arguments or unspecified size array
      declarations will not be affected.

This means that 9 will only allow `[name]` for captures, and 10
will only allow `[ name ]` for captures, so they ping-pong all
the lambda's in the codebase back and forth. Just don't.
2021-06-04 14:55:11 +02:00
Adriaan de Groot
f3c57723df CI: make clang-format wrangling more flexible
Various clang-format versions have different defaults and
don't understand the same options, so adjust to having
files per-formatting-version to patch things up.
2021-06-04 14:47:26 +02:00
Adriaan de Groot
ea8f5afc3c CI: clang-format 7 is no longer supported 2021-05-15 06:24:32 +02:00
Adriaan de Groot
3b9c0bdf91 CI: don't allow clang-format 7 any more 2021-03-16 16:06:46 +01:00
Adriaan de Groot
697ee6f65f CI: accept clang-format90 (FreeBSD naming style) 2020-10-23 17:16:37 +02:00
Adriaan de Groot
17914b9cf9 CI: adjust to clang-format-10 automatically
- leave clang-format file alone, but dynamically
  modify it when clang-format 10 or later is present
- ignore the resulting .bak file
2020-09-21 16:15:51 +02:00
Adriaan de Groot
0ee0f40816 REUSE: license tags for the scripts and tools in ci/
- remove empty useless HACKING
- remove unused cppcheck.sh
- migrate the AppImage docs to the wiki (which doesn't moan about licensing)
- try a HTML-style comment in the RELEASE docs
2020-08-26 02:05:46 +02:00
Adriaan de Groot
4a45eb847d CI: fix edge cases for calamaresstyle
- no format-10
- skip empty directories (otherwise astyle gets no file-paramaters
  and then hangs on stdin)
2020-08-26 00:31:16 +02:00
Adriaan de Groot
45aac7db66 CI: update clang-format
In clang-format 10, SpaceInEmptyBlock is introduced, and defaults to
true .. which is different from the earlier formatting versions did.
For now, refuse clang-format 10, and search specifically also for
clang-format-9.0.1 because that's what I have on my laptop.

At some point, switch in the config option and then require
clang-format 10 or later (because earlier versions refuse to
run with an unknown config option)
2020-06-17 07:53:40 -04:00
Adriaan de Groot
24d0ca6f8e CI: don't be so chatty while looking for clang-format 2020-04-15 11:54:27 +02:00
Adriaan de Groot
0f8751497e CI: give tooling a standard LANG environment 2020-03-03 14:23:48 +01:00
Adriaan de Groot
a403f1e851 CI: allow plain clang-format (Tumbleweed) 2020-01-21 19:07:03 +01:00
Adriaan de Groot
fae1fdae1c CI: allow meaningful error messages
- Move set -e down in the script so that the error-handling
   at the top (which prints meaningful error messages) isn't
   short-circuited by the -e.
2019-11-26 22:29:06 +01:00
Adriaan de Groot
fa676c573e CI: Fix style script
- when passing in more than one directory, expanded the wrong variable
2019-08-04 22:21:53 +02:00
Adriaan de Groot
d220fcea24 CI: allow different versions of clang-format 2019-07-05 10:47:31 +02:00
Adriaan de Groot
8053bf6f3a CI: use both tools for code-formatting
- astyle can do some things that clang-format doesn't (e.g.
   adding brackets; you need clang-tidy for that),
 - clang-format does a much nicer job with lambdas and certain
   other constructions,
 - allow passing in directories at a time for formatting.
2019-06-11 13:44:29 +02:00
Adriaan de Groot
1859808227 Move development-related scripts, tools, into ci/ 2017-09-05 06:09:51 -04:00