{"id":14624,"url":"https://patchwork.libcamera.org/api/1.1/patches/14624/?format=json","web_url":"https://patchwork.libcamera.org/patch/14624/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20211118124910.31123-1-laurent.pinchart@ideasonboard.com>","date":"2021-11-18T12:49:10","name":"[libcamera-devel] Documentation: coding-style: Document the git commit hooks","commit_ref":"f2a1817275db8fb77acb5f2771b7577be8642194","pull_url":null,"state":"accepted","archived":false,"hash":"f7556e858509f8c573631b53eb0b8f9a8ec386d5","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/1.1/people/2/?format=json","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/14624/mbox/","series":[{"id":2725,"url":"https://patchwork.libcamera.org/api/1.1/series/2725/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=2725","date":"2021-11-18T12:49:10","name":"[libcamera-devel] Documentation: coding-style: Document the git commit hooks","version":1,"mbox":"https://patchwork.libcamera.org/series/2725/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/14624/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/14624/checks/","tags":{},"headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 9B58BBF415\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 18 Nov 2021 12:49:38 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 9ED7860371;\n\tThu, 18 Nov 2021 13:49:37 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 3921160231\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 18 Nov 2021 13:49:36 +0100 (CET)","from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id AE2A7E7\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 18 Nov 2021 13:49:35 +0100 (CET)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"NVcXkvWa\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1637239775;\n\tbh=4+fxqBPPCooe0YyyEsoNBkUeS9P+pPx7gIM0IrKf9D4=;\n\th=From:To:Subject:Date:From;\n\tb=NVcXkvWa0OYUHkS7KJL37OzmbxFtzHQsWHXf852P0o9T7lFqen7P1QFEYIwz2mLoK\n\tmREH7villXuaFsGuzihpsoYv9BBeypUWh7BebI5r9Mvjz9YeO+EZyf4mvn1s1AdFL0\n\t6vwbHnTBode9PzyyNrB77rqNZ4shyhTc/F03bNb4=","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Thu, 18 Nov 2021 14:49:10 +0200","Message-Id":"<20211118124910.31123-1-laurent.pinchart@ideasonboard.com>","X-Mailer":"git-send-email 2.32.0","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH] Documentation: coding-style: Document the\n\tgit commit hooks","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"checkstyle.py is ignored too often. Document how to automate its usage\nthrough git commit hooks.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n Documentation/coding-style.rst | 8 ++++++++\n 1 file changed, 8 insertions(+)\n\n\nbase-commit: d9a2a1f703273a28b001dee40fddd378bba7a1b6","diff":"diff --git a/Documentation/coding-style.rst b/Documentation/coding-style.rst\nindex 4e8d6988fef8..053fdd998351 100644\n--- a/Documentation/coding-style.rst\n+++ b/Documentation/coding-style.rst\n@@ -418,4 +418,12 @@ diff that fixes the issues, on top of the corresponding commit. As the script is\n in early development false positive are expected. The flagged issues should be\n reviewed, but the diff doesn't need to be applied blindly.\n \n+Execution of checkstyle.py can be automated through git commit hooks. Example\n+of pre-commit and post-commit hooks are available in `utils/hooks/pre-commit`\n+and `utils/hooks/post-commit`. You can install either hook by copying it to\n+`.git/hooks/`. The post-commit hook is easier to start with as it will only flag\n+potential issues after committing, while the pre-commit hook will abort the\n+commit if issues are detected and requires usage of `git commit --no-verify` to\n+ignore false positives.\n+\n Happy hacking, libcamera awaits your patches!\n","prefixes":["libcamera-devel"]}