criu/.github/workflows
Pavel Tikhomirov be61624f45 clang-format: rework make indent to check specific commits
Previousely "make indent" checked all files in criu source directory for
codding style flaws. We have several problems with it:

- clang-format default format sometimes changes in new versions of the
package and we need to reformat all our code base each time it happens
- on different systems we may have different versions of clang-format
and on latest criu-dev "make indent" may be still unhappy on your system
- when we want to update clang-format rules ourselves we need to update
all our code base each time
- sometimes clang-format rules are not fitting all our cases, (e.g.: an
option IndentGotoLabels works nice for simple C code, but is a no go for
assembler and C macros) and putting "clang-format off" everywhere is a
mess
- sometimes we intentionally want to break clang-format rules (e.g.:
we want to put function arguments on a new line separating them
"logically" not "mechanically" following 120-char rule like clang-format
does).

This adds a BASE option for "make indent" where all commits in range
BASE..HEAD would be checked with git-clang-format for codding style
flaws. For instance when developing on top of criu-dev, one can use
"make BASE=origin/criu-dev indent" to check all their commits for
compliance with the clang-format rules. Default base is HEAD~1 to make
last commit checked when "make indent" is called. The closest thing to
the old behaviour would then be "make indent BASE=init", note that only
commited files would be checked.

Extra options to git-clang-format may be passed through OPTS variable.

Also reuse "make indent" in github lint workflow.

Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com>
2023-04-15 21:17:21 -07:00
..
alpine-test.yml ci: move alpine based tests to github actions 2021-09-03 10:31:00 -07:00
archlinux-test.yml scripts/build: add a docker file for archlinux 2021-09-03 10:31:00 -07:00
compat-test.yml ci: move compat tests to Github Actions 2021-09-03 10:31:00 -07:00
cross-compile-daily.yml ci: Run cross compile on debian stable 2022-04-28 17:53:52 -07:00
cross-compile.yml ci: set continue-on-error for cross-compile 2022-04-28 17:53:52 -07:00
docker-test.yml ci: update docker test matrix 2021-09-03 10:31:00 -07:00
fedora-asan-test.yml ci: move asan and image streamer test to github 2021-09-03 10:31:00 -07:00
fedora-rawhide-test.yml ci: unset XDG_RUNTIME_DIR when invoking podman 2023-04-15 21:17:21 -07:00
gcov-test.yml ci: replace deprecated codecov bash uploader 2022-04-28 17:53:52 -07:00
java-test.yml ci: Clean up and improve Java testing 2023-04-15 21:17:21 -07:00
lint.yml clang-format: rework make indent to check specific commits 2023-04-15 21:17:21 -07:00
podman-test.yml CI: distribute CI jobs between CI systems 2020-11-08 14:04:12 -08:00
stale.yml github: update the stale version 2022-04-06 10:57:20 -07:00
stream-test.yml ci: move asan and image streamer test to github 2021-09-03 10:31:00 -07:00
x86-64-clang-test.yml CI: distribute CI jobs between CI systems 2020-11-08 14:04:12 -08:00
x86-64-gcc-test.yml CI: distribute CI jobs between CI systems 2020-11-08 14:04:12 -08:00