GNU bug report logs - #31277
[PATCH] cgit changes

Previous Next

Package: guix-patches;

Reported by: Christopher Baines <mail <at> cbaines.net>

Date: Thu, 26 Apr 2018 21:15:01 UTC

Severity: normal

Tags: patch

Done: Christopher Baines <mail <at> cbaines.net>

Bug is archived. No further changes may be made.

Full log


Message #32 received at 31277 <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: 31277 <at> debbugs.gnu.org
Subject: [PATCH 2/3] services: cgit: Improve handling of extra-options.
Date: Fri, 18 May 2018 11:23:38 +0100
* gnu/services/cgit.scm (serialize-cgit-configuration): Add the extra options,
one per line, before the scan-path, as this makes it possible to use the
extra-options to affect the global behaviour for repositories.
(serialize-extra-options): New procedure.
---
 gnu/services/cgit.scm | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/gnu/services/cgit.scm b/gnu/services/cgit.scm
index 8ef12cd5a..3183535d4 100644
--- a/gnu/services/cgit.scm
+++ b/gnu/services/cgit.scm
@@ -1,6 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2018 Oleg Pykhalov <go.wigust <at> gmail.com>
 ;;; Copyright © 2018 Clément Lassieur <clement <at> lassieur.org>
+;;; Copyright © 2018 Christopher Baines <mail <at> cbaines.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -169,6 +170,9 @@
        'project-list
        (plain-file "project-list" (string-join val "\n")))))
 
+(define (serialize-extra-options extra-options)
+  (string-join extra-options "\n" 'suffix))
+
 (define repository-directory? string?)
 
 (define (serialize-repository-directory _ val)
@@ -641,6 +645,7 @@ for cgit to allow access to that repository.")
   (define (rest? field)
     (not (memq (configuration-field-name field)
                '(project-list
+                 extra-options
                  repository-directory
                  repositories))))
   #~(string-append
@@ -649,6 +654,8 @@ for cgit to allow access to that repository.")
      #$(serialize-project-list
         'project-list
         (cgit-configuration-project-list config))
+     #$(serialize-extra-options
+        (cgit-configuration-extra-options config))
      #$(serialize-repository-directory
         'repository-directory
         (cgit-configuration-repository-directory config))
-- 
2.17.0





This bug report was last modified 7 years and 1 day ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.