aboutsummaryrefslogtreecommitdiff
# GNU Guix --- Functional package management for GNU
# Copyright © 2018, 2019, 2020, 2022 Ludovic Courtès <ludo@gnu.org>
#
# This file is part of GNU Guix.
#
# GNU Guix is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or (at
# your option) any later version.
#
# GNU Guix is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.

#
# Test 'guix build --with-branch'.
#

guix build --version

# 'guix build --with-branch' requires access to the network to clone the
# Git repository below.

if ! guile -c '(getaddrinfo "www.gnu.org" "80" AI_NUMERICSERV)' 2> /dev/null
then
    # Skipping.
    exit 77
fi

orig_drv="`guix build guile-gcrypt -d`"
latest_drv="`guix build guile-gcrypt --with-branch=guile-gcrypt=master -d`"
test -n "$latest_drv"
test "$orig_drv" != "$latest_drv"

# FIXME: '-S' currently doesn't work with non-derivation source.
# checkout="`guix build guile-gcrypt --with-branch=guile-gcrypt=master -S`"
checkout="`guix gc --references "$latest_drv" | grep guile-gcrypt | grep -v -E '(-builder|\.drv)'`"
test -d "$checkout"
test -f "$checkout/COPYING"

orig_drv="`guix build guix -d`"
latest_drv="`guix build guix --with-branch=guile-gcrypt=master -d`"
guix gc -R "$latest_drv" | grep guile-gcrypt-git.master
test "$orig_drv" != "$latest_drv"

v0_1_0_drv="`guix build guix --with-commit=guile-gcrypt=9e3eacdec1d -d`"
guix gc -R "$v0_1_0_drv" | grep guile-gcrypt-git.9e3eacd
test "$v0_1_0_drv" != "$latest_drv"
test "$v0_1_0_drv" != "$orig_drv"

v0_1_0_drv="`guix build guix --with-commit=guile-gcrypt=v0.1.0 -d`"
guix gc -R "$v0_1_0_drv" | grep guile-gcrypt-0.1.0
guix gc -R "$v0_1_0_drv" | grep guile-gcrypt-9e3eacd
test "$v0_1_0_drv" != "$latest_drv"
test "$v0_1_0_drv" != "$orig_drv"

guix build guix --with-commit=guile-gcrypt=000 -d && false

exit 0
Merge branch 'master' into core-updates-frozenLudovic Courtès 2021-11-16services: cups: Update default timeouts.Tobias Geerinckx-Rice Upstream raised these back in 2019 with CUPS 2.3.0. * gnu/services/cups.scm (<cups-configuration>): Raise default ‘multiple-operation-timeout’ and ‘timeout’ from 300 to 900 seconds. * doc/guix.texi (Printing Services): Adjust accordingly. 2021-06-23Merge branch 'master' into core-updatesTobias Geerinckx-Rice Conflicts: gnu/packages/cups.scm gnu/packages/python-web.scm gnu/packages/web.scm guix/build/maven/pom.scm 2021-06-23services: cups: Remove obsolete KeepAliveTimeout directive.Tobias Geerinckx-Rice https://github.com/apple/cups/commit/461bd4e50142b2928a0d164bd1aae274e4d34da5 * gnu/services/cups.scm (<cups-configuration>): Remove keep-alive-timeout field. * doc/guix.texi (Printing Services): Likewise. 2021-06-23services: cups: Fix ‘files-config’ typo/left-over.Tobias Geerinckx-Rice * gnu/services/cups.scm (<policy-configuration>): Substitute <files-configuration> for <files-config> in documentation. * doc/guix.texi (Printing Services): Likewise. 2021-06-23services: cups: Support CUPS 2.3.3op2's LogFileGroup directive.Tobias Geerinckx-Rice * gnu/services/cups.scm (<files-configuration>): Add a log-file-group field. * doc/guix.texi (Printing Services): Document it. 2021-03-10services: Prevent following symlinks during activation.Maxime Devos This addresses a potential security issue, where a compromised service could trick the activation code in changing the permissions, owner and group of arbitrary files. However, this patch is currently only a partial fix, due to a TOCTTOU (time-of-check to time-of-use) race, which can be fixed once guile has bindings to openat and friends. Fixes: <https://lists.gnu.org/archive/html/guix-devel/2021-01/msg00388.html> * gnu/build/activation.scm: new procedure 'mkdir-p/perms'. * gnu/services/authentication.scm (%nslcd-activation, nslcd-service-type): use new procedure. * gnu/services/cups.scm (%cups-activation): likewise. * gnu/services/dbus.scm (dbus-activation): likewise. * gnu/services/dns.scm (knot-activation): likewise. Signed-off-by: Ludovic Courtès <ludo@gnu.org> 2021-01-17services: cups: reuse lp from %base-groups.Leo Prikler * gnu/services/cups.scm (%cups-accounts): Try to reuse lp from %base-groups. 2021-01-10services: cups: Add brlaser extension by default.Tobias Geerinckx-Rice * gnu/services/cups.scm (cups-configuration): Add brlaser to the default extensions. * doc/guix.texi (Printing Services): Document it. 2020-11-21services: cups: Add Splix by default.Tobias Geerinckx-Rice * gnu/services/cups.scm (cups-configuration): Add splix to the default extensions. * doc/guix.texi (Printing Services): Document it. 2020-11-21gnu: Rename escpr to epson-inkjet-printer-escpr.Tobias Geerinckx-Rice ‘escpr’ is nice and short, but everyone else calls this package ‘epson-inkjet-printer-escpr’. More importantly, so does upstream. * gnu/packages/cups.scm (escpr, epson-inkjet-printer-escpr,): Rename escpr to epson-inkjet-printer-escpr, redefining escpr as deprecated-package. Adjust all users. 2020-11-18services: cups: Add some extensions by default.Danny Milosavljevic * gnu/services/cups.scm (cups-configuration): Add some extensions by default. doc/guix.texi (Printing Services): Document the default value. 2020-05-26services: Fix permissions of directory /var/spool/cups/tmp.Danny Milosavljevic Fixes <https://bugs.gnu.org/41367>. * gnu/services/cups.scm (%cups-activation): Fix permissions of directory /var/spool/cups/tmp.