From patchwork Sat Mar 22 17:09:05 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: 40640 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 B8AE627BBEA; Sat, 22 Mar 2025 17:11:53 +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=ham 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 40B7127BBE2 for ; Sat, 22 Mar 2025 17:11:53 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tw2NP-0000cJ-Uy; Sat, 22 Mar 2025 13:11:15 -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 1tw2NK-0000Zf-Cr for guix-patches@gnu.org; Sat, 22 Mar 2025 13:11:13 -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 1tw2NJ-0007lc-Dj; Sat, 22 Mar 2025 13:11:10 -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=4E72H7LQGf5wdlF7d/o1tqHOJNCtrARd0PSpXzwo5AI=; b=RqzphsfIRdij29WuVbDfgDEwEHT3k9OE5I8rZulrHzMgwzzIa2r1IoB9Q2rmaf7CR84d8gtaAb9Ml/bm0FwhZ357g/4aNAK/Yz8P+f8y/g40eTuw9rkY9K7pqKpTmhbfI6QDFh6leDM+58rqgRuTV/dCn/df1VB/RgTiGdY9L6ZbbuDPwXreTuRdk7dJkY9mXV4KsPv6BUebaR9UU371zjvmXCYt04qnFId9zY+NbuMHgeuKq5eQRPMJ3fcGKQAkkoKE4pieckzyiIqRVti3WJPGRtaJTTOCv1k0xyYDZaLHTB5wkuqaQMZpqXh5nyFXV9sgKM4pid8wJePSg3L9Pw==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tw2NJ-0007Ji-7z; Sat, 22 Mar 2025 13:11:09 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#77186] [PATCH v2 04/13] services: gitolite-rc-file: Add extra-content 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:09 +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.174266344227901 (code B ref 77186); Sat, 22 Mar 2025 17:11:09 +0000 Received: (at 77186) by debbugs.gnu.org; 22 Mar 2025 17:10:42 +0000 Received: from localhost ([127.0.0.1]:45261 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tw2Mn-0007Ez-W0 for submit@debbugs.gnu.org; Sat, 22 Mar 2025 13:10:40 -0400 Received: from wolfsden.cz ([37.205.8.62]:57544) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <~@wolfsden.cz>) id 1tw2MC-00074d-Gg for 77186@debbugs.gnu.org; Sat, 22 Mar 2025 13:10:02 -0400 Received: by wolfsden.cz (Postfix, from userid 104) id 7D53837F93E; Sat, 22 Mar 2025 17:09:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1742663399; bh=oIRywjcbaVxrHIDAWDnpoerUNSaoYkMpJPOKISN8Hs8=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=FSymUdnqWjRoQZEV912+zgx1wADOeuzVfj0VR2WtJa6a2xhLtlno4LWxrqvR1+f++ 0SnSBuAe5NLNT+OQMYOLEeLg1d/KRiU8n9TqL0AT6uRYPSx5G0KBN6HFti3PHGXIsZ wdEGJdAV8c8rcYiwsyZGUBmC6pBeTBb3KXFClIO11B3Y2SK+1E4FcwDtmg72ml5ssN aHOGuaV5WMPsEmjN2nB6+rBQlIIq6JUKcMMODjsYUxCJy1SuwxrFtjNuiNWAJBtWZw zrpBi+799MiXi0bo0SSJBfUPFLXxIeH+mX6eUvgYiqAyJIwMnrmI28AiakLwgv7UDi VN2o/CVh+uCLLCqqfN9Ds7wxMktgMHqERV8bLnrWLUfAGe+530YWsbkul+pxe9o7nL Q1/ooIvXDt9ZsoDp+UPuxa4bX5/4pDU4G+NMEbWZg5aXgH0rkRh0m2BdMiW0e7+h41 g3Pxs8yTi1d3zXvQs9zDj3lJfEdtlCk4G4lnHTOedvabjoqh6GN6D3kmBXmlXvwKz1 k1LY6K7ioebpSfl5z2NlaiFxkRb3vRzxIQ47o5heRcIJoE3mARbyZd/X5JoBA/jd45 7dK0O2aYAoVnWDC5YdKM5fh195H+rVohYfGz30RCvOND/QmnfYPvyeRRYTI6u/vIIH ZMUOn+daMrRpbqomnKIv8TfM= Received: from localhost (unknown [128.0.188.242]) by wolfsden.cz (Postfix) with ESMTPSA id 1B69A38080D; Sat, 22 Mar 2025 17:09:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1742663399; bh=oIRywjcbaVxrHIDAWDnpoerUNSaoYkMpJPOKISN8Hs8=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=FSymUdnqWjRoQZEV912+zgx1wADOeuzVfj0VR2WtJa6a2xhLtlno4LWxrqvR1+f++ 0SnSBuAe5NLNT+OQMYOLEeLg1d/KRiU8n9TqL0AT6uRYPSx5G0KBN6HFti3PHGXIsZ wdEGJdAV8c8rcYiwsyZGUBmC6pBeTBb3KXFClIO11B3Y2SK+1E4FcwDtmg72ml5ssN aHOGuaV5WMPsEmjN2nB6+rBQlIIq6JUKcMMODjsYUxCJy1SuwxrFtjNuiNWAJBtWZw zrpBi+799MiXi0bo0SSJBfUPFLXxIeH+mX6eUvgYiqAyJIwMnrmI28AiakLwgv7UDi VN2o/CVh+uCLLCqqfN9Ds7wxMktgMHqERV8bLnrWLUfAGe+530YWsbkul+pxe9o7nL Q1/ooIvXDt9ZsoDp+UPuxa4bX5/4pDU4G+NMEbWZg5aXgH0rkRh0m2BdMiW0e7+h41 g3Pxs8yTi1d3zXvQs9zDj3lJfEdtlCk4G4lnHTOedvabjoqh6GN6D3kmBXmlXvwKz1 k1LY6K7ioebpSfl5z2NlaiFxkRb3vRzxIQ47o5heRcIJoE3mARbyZd/X5JoBA/jd45 7dK0O2aYAoVnWDC5YdKM5fh195H+rVohYfGz30RCvOND/QmnfYPvyeRRYTI6u/vIIH ZMUOn+daMrRpbqomnKIv8TfM= From: Tomas Volf <~@wolfsden.cz> Date: Sat, 22 Mar 2025 18:09:05 +0100 Message-ID: <3ae90a9c51dc9508f324eee1d32002a081d93c33.1742663354.git.~@wolfsden.cz> 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 extra-content field. (gitolite-rc-file-compiler): Handle it during configuration file generation. * doc/guix.texi (Version Control Services): Document it. Change-Id: I5082e1d7a27cc746641ba9ec8ae07c703da5f279 --- doc/guix.texi | 3 +++ gnu/services/version-control.scm | 8 ++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 2c7ddb2f55..e60fef9673 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -41164,6 +41164,9 @@ Version Control Services @item @code{enable} (default: @code{'("help" "desc" "info" "perms" "writable" "ssh-authkeys" "git-config" "daemon" "gitweb")}) This setting controls the commands and features to enable within Gitolite. +@item @code{extra-content} (default: @code{""}) +Extra content to add verbatim into the @code{%RC} hash. + @end table @end deftp diff --git a/gnu/services/version-control.scm b/gnu/services/version-control.scm index 2b99e8db86..9bd17334fe 100644 --- a/gnu/services/version-control.scm +++ b/gnu/services/version-control.scm @@ -64,6 +64,7 @@ (define-module (gnu services version-control) gitolite-rc-file-host-name gitolite-rc-file-roles gitolite-rc-file-enable + gitolite-rc-file-extra-content gitolite-service-type @@ -270,13 +271,15 @@ (define-record-type* "ssh-authkeys" "git-config" "daemon" - "gitweb")))) + "gitweb"))) + (extra-content gitolite-rc-extra-content + (default ""))) (define-gexp-compiler (gitolite-rc-file-compiler (file ) system target) (match-record file ( umask local-code unsafe-pattern git-config-keys log-extra - host-name roles enable) + host-name roles enable extra-content) (apply text-file* "gitolite.rc" `("%RC = (\n" " UMASK => " ,(format #f "~4,'0o" umask) ",\n" @@ -302,6 +305,7 @@ (define-gexp-compiler (gitolite-rc-file-compiler (simple-format #f " '~A',\n" value)) enable) " ],\n" + ,extra-content "\n" ");\n" "\n" ,(if unsafe-pattern