From patchwork Sat Mar 22 17:09:03 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomas Volf <~@wolfsden.cz> X-Patchwork-Id: 40638 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id D446527BBE9; Sat, 22 Mar 2025 17:11:34 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_ADSP_ALL,DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL, RCVD_IN_VALIDITY_SAFE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 21A8C27BBE2 for ; Sat, 22 Mar 2025 17:11:33 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tw2NO-0000Zh-5s; Sat, 22 Mar 2025 13:11:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tw2NE-0000Vu-5F for guix-patches@gnu.org; Sat, 22 Mar 2025 13:11:04 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tw2NC-0007kA-Va; Sat, 22 Mar 2025 13:11:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=YEIEeVHDHgIyyqdRQ721HkiXl/EKHAoa+RMJ8P0Ry9M=; b=pKI/t7E2eg6zSYdqEVQIr+wt9aH8PxWzTROyHTLabdTe1Dc4HreNvVVtnbbbCshxLhToUypSViG5bH06AT/TGpmjVe9AwvFBAFGsKu34w4WCqlCabigxbFNrHscmNFFsA5E1UXrgLCeVkKeuXeeNylqUG9JXA7dMgdfopC8PBSKYV7I/KYEOjPwGyF4kPYcOo0ot1d3DyshDnyWaE42xr0+4lETGy39gzWYR44d3o/I/yAy+fRPO4d4MRDeQoH26MfCfLZpYgRf7mZC68LBR8ZBXNe1IfcpNttIB0t+fCPKlhcSlSepXssrxYScU2zjRpG44o3KkIwdknf1223gfjg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tw2NC-0007Hy-R6; Sat, 22 Mar 2025 13:11:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#77186] [PATCH v2 02/13] services: gitolite-rc-file: Add log-extra field. Resent-From: Tomas Volf <~@wolfsden.cz> Original-Sender: "Debbugs-submit" Resent-CC: ludo@gnu.org, maxim.cournoyer@gmail.com, guix-patches@gnu.org Resent-Date: Sat, 22 Mar 2025 17:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77186 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 77186@debbugs.gnu.org Cc: Tomas Volf <~@wolfsden.cz>, Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer X-Debbugs-Original-Xcc: Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer Received: via spool by 77186-submit@debbugs.gnu.org id=B77186.174266341027438 (code B ref 77186); Sat, 22 Mar 2025 17:11:02 +0000 Received: (at 77186) by debbugs.gnu.org; 22 Mar 2025 17:10:10 +0000 Received: from localhost ([127.0.0.1]:45226 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tw2MJ-00076r-0q for submit@debbugs.gnu.org; Sat, 22 Mar 2025 13:10:09 -0400 Received: from wolfsden.cz ([37.205.8.62]:57522) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <~@wolfsden.cz>) id 1tw2MB-00074Z-PL for 77186@debbugs.gnu.org; Sat, 22 Mar 2025 13:10:01 -0400 Received: by wolfsden.cz (Postfix, from userid 104) id 73F5737FB4C; Sat, 22 Mar 2025 17:09:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1742663398; bh=uvHBnszqcHNWSmGWaoUPTxI6k0AAWdw+AsQhP6tWlao=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=UfSQqFzRHHGxBfSLDioFQmuYX0FJqS0gEzg98vHedn5CajjE6roCzVWNh4V7LviWg WFPd/KjdkX4U7E49qJy6WqEOjRXlqrFALgjtrRenKF5LD6wknpW0sdsWf0ZVyFUoHA MfGf3p+apTlT7V8j+LmOJ0fCc++9h6dprhopwceDrxAiTnxbzTn8IQo1QAHlJ5HAaW bsRgA5+ytE0nd0Guq2+x5tA34ZkTw1yGPcoWyGMBms2sYwXbxJSmxZd0s4EKdmIP6G KOx8K3uLe7x5GXvFC5b9oc/kr+l4o8iOF//J6W4z1WLDhm9GsTkvFLecVKjleUZXOo 74t/GbrFAjxAsGol/XM/g1tyrUdvnVhKdOoYaUhmT6sniAdzSKe0b75hTiNlpWPYVY vooweWBHhzqet0DNGJKJ9iyLLE5ObFjdfG0dFqhyqLE4cl9Ezx3EOfmng92odIbMmz RcfVJrESGRQwGRKwtzydhi+ow98ddmzdtIPv+2Tb3b5bkEc4Ol9qmPTLrl/teKQhMo AjJ5VIzbpOiGsGfGIs9n2bzMexnXOs5y5r6GzEMl1kFl1iDghwtclLmzHdqYX34vlk QDgsCS5ov32aCtBITLV07NTxb00UhSche1wDjLX4tI1oFTzl3syUwxYYgx2Mrbr09s 4weV/T2QndOF7Eccfh5z1RFU= Received: from localhost (unknown [128.0.188.242]) by wolfsden.cz (Postfix) with ESMTPSA id 1049937EDE3; Sat, 22 Mar 2025 17:09:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1742663398; bh=uvHBnszqcHNWSmGWaoUPTxI6k0AAWdw+AsQhP6tWlao=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=UfSQqFzRHHGxBfSLDioFQmuYX0FJqS0gEzg98vHedn5CajjE6roCzVWNh4V7LviWg WFPd/KjdkX4U7E49qJy6WqEOjRXlqrFALgjtrRenKF5LD6wknpW0sdsWf0ZVyFUoHA MfGf3p+apTlT7V8j+LmOJ0fCc++9h6dprhopwceDrxAiTnxbzTn8IQo1QAHlJ5HAaW bsRgA5+ytE0nd0Guq2+x5tA34ZkTw1yGPcoWyGMBms2sYwXbxJSmxZd0s4EKdmIP6G KOx8K3uLe7x5GXvFC5b9oc/kr+l4o8iOF//J6W4z1WLDhm9GsTkvFLecVKjleUZXOo 74t/GbrFAjxAsGol/XM/g1tyrUdvnVhKdOoYaUhmT6sniAdzSKe0b75hTiNlpWPYVY vooweWBHhzqet0DNGJKJ9iyLLE5ObFjdfG0dFqhyqLE4cl9Ezx3EOfmng92odIbMmz RcfVJrESGRQwGRKwtzydhi+ow98ddmzdtIPv+2Tb3b5bkEc4Ol9qmPTLrl/teKQhMo AjJ5VIzbpOiGsGfGIs9n2bzMexnXOs5y5r6GzEMl1kFl1iDghwtclLmzHdqYX34vlk QDgsCS5ov32aCtBITLV07NTxb00UhSche1wDjLX4tI1oFTzl3syUwxYYgx2Mrbr09s 4weV/T2QndOF7Eccfh5z1RFU= From: Tomas Volf <~@wolfsden.cz> Date: Sat, 22 Mar 2025 18:09:03 +0100 Message-ID: X-Mailer: git-send-email 2.48.1 In-Reply-To: <39fb02cc97f30aa37523d9f5f9390264d53fcf8b.1742663354.git.~@wolfsden.cz> References: <39fb02cc97f30aa37523d9f5f9390264d53fcf8b.1742663354.git.~@wolfsden.cz> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/services/version-control.scm (): Add log-extra field. (gitolite-rc-file-compiler): Handle it during configuration file generation. * doc/guix.texi (Version Control Services): Document it. Change-Id: Ice65dbdf4f42549e3c83914da7229db9d2cf856b --- doc/guix.texi | 7 +++++++ gnu/services/version-control.scm | 9 ++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/doc/guix.texi b/doc/guix.texi index bcb1f9d9cf..3179d33cb3 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -41147,6 +41147,13 @@ Version Control Services Gitolite allows you to set git config values using the @samp{config} keyword. This setting allows control over the config keys to accept. +@item @code{log-extra} (default: @code{#f}) +Whether gitolite should log extra details. + +For historical reasons, this field defaults to @code{#f}. The default +value from gitolite however is @code{1} (written as @code{#t} in this +configuration). + @item @code{roles} (default: @code{'(("READERS" . 1) ("WRITERS" . ))}) Set the role names allowed to be used by users running the perms command. diff --git a/gnu/services/version-control.scm b/gnu/services/version-control.scm index f5558e9197..344538a73e 100644 --- a/gnu/services/version-control.scm +++ b/gnu/services/version-control.scm @@ -60,6 +60,7 @@ (define-module (gnu services version-control) gitolite-rc-file-umask gitolite-rc-file-unsafe-pattern gitolite-rc-file-git-config-keys + gitolite-rc-file-log-extra gitolite-rc-file-roles gitolite-rc-file-enable @@ -252,6 +253,8 @@ (define-record-type* (default #f)) (git-config-keys gitolite-rc-file-git-config-keys (default "")) + (log-extra gitolite-rc-file-log-extra + (default #f)) (roles gitolite-rc-file-roles (default '(("READERS" . 1) ("WRITERS" . 1)))) @@ -269,7 +272,8 @@ (define-record-type* (define-gexp-compiler (gitolite-rc-file-compiler (file ) system target) (match-record file - (umask local-code unsafe-pattern git-config-keys roles enable) + ( umask local-code unsafe-pattern git-config-keys log-extra + roles enable) (apply text-file* "gitolite.rc" `("%RC = (\n" " UMASK => " ,(format #f "~4,'0o" umask) ",\n" @@ -277,6 +281,9 @@ (define-gexp-compiler (gitolite-rc-file-compiler ,(if local-code (simple-format #f " LOCAL_CODE => \"~A\",\n" local-code) "") + ,(if log-extra + " LOG_EXTRA => 1,\n" + "") " ROLES => {\n" ,@(map (match-lambda ((role . value)