Skip to content
Success

Changes

Summary

  1. jobs/gerrit-lint: run in docker (details)
  2. lint/lint_diff: make use of shell functions (details)
  3. lint/lint_diff: run clang-format if config was found (details)
  4. lint/lint_diff: allow skipping with OSMO_LINT=0 (details)
Commit b16268a99b2195d672f9ac29578ab847f867b04c by Oliver Smith
jobs/gerrit-lint: run in docker

Run the linting scripts in docker, so we can make use of additional
programs like clang-format without installing them on the jenkins node
directly.

Change-Id: I17d2e538f1f9fb69f298ac223bc293570db90a83
The file was modifiedjobs/gerrit-lint.yml
The file was modifiedcontrib/known_hosts
The file was modifiedlint/lint_diff.sh
Commit a42c6a56e031ff92512494cb7906655e98a9ab52 by Oliver Smith
lint/lint_diff: make use of shell functions

Prepare to add more logic to this file by first moving existing code
blocks into functions.

Change-Id: If884f51f20e794397ee0fecff0cf1f958957da05
The file was modifiedlint/lint_diff.sh
Commit 31db96c312b953afc26ae4b16b266e367a0fdcef by Oliver Smith
lint/lint_diff: run clang-format if config was found

The osmo-asf4-dfu and osmo-ccid-firmware now have clang-format configs.
Adjust the lint script to run clang-format if such a config is found in
the repository for which the lint script is running.

Change-Id: Ie210966ebfbada43dd8507b9b48218df4925820d
The file was modifiedlint/lint_diff.sh
Commit 3dffb34587dc0bba9ce46c7ef0d7e07c8167a8d4 by Oliver Smith
lint/lint_diff: allow skipping with OSMO_LINT=0

When this script is set as pre-commit hook, it can be useful to skip the
linter with this env var to make a commit that intentionally does not
pass the linter (e.g. to test if it will be caught in gerrit + jenkins).

There is also "git commit --no-verify", but with that the hook that
applies the Change-Id does not run.

Change-Id: Ia4563c13d9916a879a1e8afeacad8c541662adaa
The file was modifiedlint/lint_diff.sh