From patchwork Fri Aug 11 18:44:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52748 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 E7A8427BBE9; Fri, 11 Aug 2023 19:50:31 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 2A54727BBEA for ; Fri, 11 Aug 2023 19:50:30 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD6-0003bR-FA; Fri, 11 Aug 2023 14:50:08 -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 1qUXD4-0003ah-9n for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:06 -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 1qUXD3-00008P-DG; Fri, 11 Aug 2023 14:50:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD0-0007qX-Kz; Fri, 11 Aug 2023 14:50:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 01/13] gnu-maintenance: Make base-url argument of import-html-release required. References: In-Reply-To: Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177977529975 (code B ref 65230); Fri, 11 Aug 2023 18:50:02 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:35 +0000 Received: from localhost ([127.0.0.1]:47970 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCY-0007nO-Ug for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:35 -0400 Received: from mail-qt1-x832.google.com ([2607:f8b0:4864:20::832]:57504) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCX-0007n8-AK for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:34 -0400 Received: by mail-qt1-x832.google.com with SMTP id d75a77b69052e-40fd276621aso14860261cf.2 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779767; x=1692384567; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=QXWO6N8H7GhNEgL+zQcNmoAAyzbZv7yNXYx7A5tdUqE=; b=BjwK8U/z7rh0NdwdVz60RiBaHbQ7Ilte5FYcHGtKYO90ZZEctBif1krq2FWC6aK/aQ Vg9UqeIuXvdPN2jxI9yFhNyRvL6s9/g65vli65vIoR0nmfr7J8tln+pFTJ+7Tg7mjLjv BfTiyJYgSWnJ7LW5gEz7sjyIg171D/qo8LuRWJ70NQnOqHisOL3CeZuj8o3wx2EBywtJ Cpzam9icyM48r0mc/W5vn/rdYjYS9wXtcgHBfn7KIgRY/dkEtiKc2xnURQ0LLc4+fLEv gDD8p4vyEIU2TkJFSupGL92qvvvD67lqKNknllkAQL9vLZ1qwgm6Rc5W4X+ke9zmyKiY XDKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779767; x=1692384567; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=QXWO6N8H7GhNEgL+zQcNmoAAyzbZv7yNXYx7A5tdUqE=; b=bRrtkuFhfT0LeNUM3mH7+XUFhCdnTFOlVvwbDFxOhwP8vYYULouO5DgA4y8rUSAVZT rR/2Gd8WI7NJRwZkm4GDIfK6zAc/JDly2kGucYomshxnw1bFhd2Fkmv1tp+KFvEnEcyC Jf6O1HgvK3F/Weeun8Uz970wkFp4Ly6KFM9zivQiMsqzWePEkUUrlMBDi5PO1uAkmbsJ GItMaURXje8wHY68dQrdvXLfJyl+dL3QkWGfoQAtBbM1U7t2xC4n9df4RocA5k0VIvWg Ie3BOp9rlGEUT5iWTaWzEvakJAdTz38DloDsKZ1Y3IYWi/o4uwuqmWiXlYi3hX3XVXLp gkGg== X-Gm-Message-State: AOJu0YzY55OVv8xHV9wP4c5QEarGJ5ma0jal4wr1pKuBKyTNULu/JZx/ gcJ135pWZ4WYdbIQcqbRQmcabTFHT6iLbA== X-Google-Smtp-Source: AGHT+IHmwQ7EJrxX6pFI3vXxSzVf3YB4oPrQs45i98e40LGM+IqKVnsKRoi/tODKoLmTHcrj+kD4Bg== X-Received: by 2002:ac8:5a83:0:b0:400:9b69:7c13 with SMTP id c3-20020ac85a83000000b004009b697c13mr2773361qtc.59.1691779767367; Fri, 11 Aug 2023 11:49:27 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:27 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:48 -0400 Message-ID: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 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 It doesn't make sense to have it default to something like "https://kernel.org/pub"; it should always be provided explicitly. * guix/gnu-maintenance.scm (import-html-release) <#:base-url>: Turn keyword argument into a positional argument. Update doc. * guix/gnu-maintenance.scm (import-savannah-release): Adjust call accordingly. (import-kernel.org-release): Likewise. (import-html-updatable-release): Likewise. --- guix/gnu-maintenance.scm | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) base-commit: 77251c5f5af193dcd031dffef744001cfc48f7e5 diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 32712f7218..b95a45824e 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -483,15 +483,14 @@ (define (html-links sxml) (_ links)))) -(define* (import-html-release package +(define* (import-html-release base-url package #:key (version #f) - (base-url "https://kernel.org/pub") (directory (string-append "/" package)) file->signature) - "Return an for the latest release of PACKAGE (a string) on -SERVER under DIRECTORY, or #f. Optionally include a VERSION string to fetch a -specific version. + "Return an for the latest release of PACKAGE (a string) +under DIRECTORY at BASE-URL, or #f. Optionally include a VERSION string to +fetch a specific version. BASE-URL should be the URL of an HTML page, typically a directory listing as found on 'https://kernel.org/pub'. @@ -730,9 +729,8 @@ (define* (import-savannah-release package #:key (version #f)) (directory (dirname (uri-path uri)))) ;; Note: We use the default 'file->signature', which adds ".sig", ".asc", ;; or whichever detached signature naming scheme PACKAGE uses. - (import-html-release package + (import-html-release %savannah-base package #:version version - #:base-url %savannah-base #:directory directory))) (define* (latest-sourceforge-release package #:key (version #f)) @@ -824,9 +822,8 @@ (define* (import-kernel.org-release package #:key (version #f)) ((uri mirrors ...) uri)))) (package (package-upstream-name package)) (directory (dirname (uri-path uri)))) - (import-html-release package + (import-html-release %kernel.org-base package #:version version - #:base-url %kernel.org-base #:directory directory #:file->signature file->signature))) @@ -870,9 +867,8 @@ (define* (import-html-updatable-release package #:key (version #f)) (dirname (uri-path uri)))) (package (package-upstream-name package))) (false-if-networking-error - (import-html-release package + (import-html-release base package #:version version - #:base-url base #:directory directory)))) (define %gnu-updater From patchwork Fri Aug 11 18:44:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52756 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 4483227BBEC; Fri, 11 Aug 2023 19:51:12 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, 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 6301B27BBEA for ; Fri, 11 Aug 2023 19:51:11 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD5-0003b1-QF; Fri, 11 Aug 2023 14:50:07 -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 1qUXD3-0003ae-Kt for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:06 -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 1qUXD3-00008O-CJ; Fri, 11 Aug 2023 14:50:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD1-0007qi-Fp; Fri, 11 Aug 2023 14:50:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 02/13] download: Add mirrors for Qt. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177977929992 (code B ref 65230); Fri, 11 Aug 2023 18:50:03 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:39 +0000 Received: from localhost ([127.0.0.1]:47974 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCc-0007nf-Ci for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:38 -0400 Received: from mail-qk1-x72f.google.com ([2607:f8b0:4864:20::72f]:54537) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCZ-0007nC-Ah for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:37 -0400 Received: by mail-qk1-x72f.google.com with SMTP id af79cd13be357-765942d497fso175390585a.1 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779769; x=1692384569; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LK2FthP2wADdRwz9YrxDkE5X0n42Lqw4E+SxXdSpGJs=; b=W1Cy4p+dok39jOsLuczbRXJNiCd1dRNK2uF0xJfdaDsLCPPmiTbWESb+yHmpuf4GIP eKp+e4VHTIjPgdiaJ9mTiF37RE3gQbh/8RIP7IkeyZkTFKKlOgBBI3/PNr9iUv34k3+L coajftwEQUM02A+dEWleoU3b+B2RMMaVlDZh7ZyyaQt+LVFGleDtl67kAUy9gqB+n3iB 0fOKyguNF8Ljmmgog3POUg+zLLVvUVaaRVjuzzwbuDpEGkVSKktvv3yJcI7LGLXgJJEK HV0NDUDZyuCdTBeOGZs4kc/mIPjredviMxuolLdfA4BnNgivqBec66R2ZqWSebuh+/eV VD/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779769; x=1692384569; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LK2FthP2wADdRwz9YrxDkE5X0n42Lqw4E+SxXdSpGJs=; b=hPKLcIbVIQQ2BCF+jFUw0zkvMc18FC8SMNRHWqg0fJlxUGvd2EkL3kKzF/+zwLDyn2 HGR/Qc77FN0F+noka4bEoMfEtK+CloSGywPTDJUOITWYQfilpCyO2UH/8wpkcvJahzMp iTF6/oPZNQoC/60uJkQCcyVnf61wGFSJu5NfdVu7NklPY/LSU0aeQBcV1GZgio7Sj3N5 tRnpnT6Zt1s6ZrDMkGTe8Qz1qBIb6aRloBJZZ4wicl3nd49JmZZ1qU6CZNuIFChRg3pO WAd41heSCMhGzJusF/EGovxI55E2CVpBVMYQnvUaJtviINhMIZGvoE0DlwzWq62PsX03 dxqA== X-Gm-Message-State: AOJu0Yxn+waNhheq6LfS2jkmodZQ9IMHvlJtX5omLt1pAd0TtkwN4dXN boLXwbQThaY5MrW+LDrIwstUvfMVSww14Q== X-Google-Smtp-Source: AGHT+IE+z/91zJ0SqyuYUR/XoEOGx/xWPeFl/BSiYou6tv0ZyTRuo9NjlnOBEDVH5Md/pS4pIWmgHQ== X-Received: by 2002:a05:620a:1713:b0:767:1c73:6a06 with SMTP id az19-20020a05620a171300b007671c736a06mr3442737qkb.0.1691779769501; Fri, 11 Aug 2023 11:49:29 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:29 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:49 -0400 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/download.scm (%mirrors): Augment with qt mirrors. --- guix/download.scm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/guix/download.scm b/guix/download.scm index 30d7c5a86e..d5da866179 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -358,7 +358,15 @@ (define %mirrors "https://mirror.esc7.net/pub/OpenBSD/") (mate "https://pub.mate-desktop.org/releases/" - "http://pub.mate-desktop.org/releases/")))) + "http://pub.mate-desktop.org/releases/") + (qt + "https://download.qt.io/official_releases/" + "https://ftp.jaist.ac.jp/pub/qtproject/official_releases/" + "https://ftp.nluug.nl/languages/qt/official_releases/" + "https://mirrors.cloud.tencent.com/qt/official_releases/" + "https://mirrors.sjtug.sjtu.edu.cn/qt/official_releases/" + "https://qtproject.mirror.liquidtelecom.com/official_releases/" + "https://mirrors.ocf.berkeley.edu/qt/official_releases/")))) (define %mirror-file ;; Copy of the list of mirrors to a file. This allows us to keep a single From patchwork Fri Aug 11 18:44:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52752 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 BAF1027BBE2; Fri, 11 Aug 2023 19:50:59 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, 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 D940F27BBE9 for ; Fri, 11 Aug 2023 19:50:56 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD9-0003dD-3t; Fri, 11 Aug 2023 14:50:11 -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 1qUXD5-0003aw-NX for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:07 -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 1qUXD5-000092-Ek for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD2-0007r1-GL; Fri, 11 Aug 2023 14:50:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 03/13] gnu: qt: Streamline qt-urls. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: andreas@enge.fr, maxim.cournoyer@gmail.com, iyzsong@envs.net, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Andreas Enge , Maxim Cournoyer , =?utf-8?b?5a6L5paH5q2m?= X-Debbugs-Original-Xcc: Andreas Enge , Maxim Cournoyer , =?utf-8?b?5a6L5paH5q2m?= Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177978230020 (code B ref 65230); Fri, 11 Aug 2023 18:50:04 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:42 +0000 Received: from localhost ([127.0.0.1]:47978 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCf-0007o6-Ut for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:42 -0400 Received: from mail-oo1-xc35.google.com ([2607:f8b0:4864:20::c35]:51649) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCb-0007nF-UE for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:40 -0400 Received: by mail-oo1-xc35.google.com with SMTP id 006d021491bc7-56c85b723cfso1755422eaf.3 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779772; x=1692384572; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=n8k7ZZryUKVg4FHV2L/LuUrlcx1PoTqlk72te9oZb/4=; b=EZAtwU4LuCQShT1FAJTTx8E/wPuXQZevA0sfldMq1B+XG59qqlzEJG46UqBpdW5Vpd PJ0UPLvbAGbI6uYPKRmrVL7Sxw71yk7KpKqHRlz2GkXIcJhMb41O2kDqLCMCsdz0WTm0 R0H8zBSwOjptaGkxrA+R9GluUOvjZCjAQv5IfksbnXRNysVQehmwTig8UnFiU+4XLanv 9LbPhksTRDIWCmtk00HCj99JABXJxestxoEij2hd/i9azjxFZ1+/iqRL3NLTWjP/a/sI IuqGPxgU7dgqzK/X33OGAf83HJHJNkka8Y/tXTrj5r4Ny6ySFA+yLlBst4TcnHcRKcDX HHzQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779772; x=1692384572; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=n8k7ZZryUKVg4FHV2L/LuUrlcx1PoTqlk72te9oZb/4=; b=jZyUTn7Wfy8E0Hlc0bBDpR2BxpEPFFwnwvX10WN7uoA1/ShWtO1JlhYZpXUYTaRHpz GrN7zrOjbD/yTOg9TgJqLKfUwsHRrxtR44+yvr4BjdHE8M2szQHYUDfxc7QOmq1o17RE nlFwjYSSAc26mr29Ufvr5kHP7vv0RQY+QZ6vlulEE9UCnNOi0BZJz+hRFdZhbBw9ONmu 97wxFiwtPaC4kPNY5nUTBoHCdPGAQhSDVxTWlfAfMmveYdhORbfKtXTJCIOhWwzsJ6Ew a+POyX3ODfg/BdsW3rDCqqqKNjkjr7SQFqE4ZY6sICPCkvcpTEJoUKFFb9RA74BdXC+v kXDQ== X-Gm-Message-State: AOJu0Yw8v0RHJdWFLV1PVqo2+xzx9KGZyckKqvMMXF0Cu/+CEASlgaKK VeO/PvXEuOIRlax5Lz5tG7R0nP1sMactmw== X-Google-Smtp-Source: AGHT+IHBRY7t8JPrgGYaPVJK79PCbmIn6XahpRMXNtPKx5Xkv2UN6XHO2jol0rdeWe3yC+60KNERwQ== X-Received: by 2002:a05:6358:4288:b0:131:b4c:b871 with SMTP id s8-20020a056358428800b001310b4cb871mr3160610rwc.22.1691779771870; Fri, 11 Aug 2023 11:49:31 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:31 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:50 -0400 Message-ID: <76bb044cb9c269e848167136d5132648b354651c.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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/packages/qt.scm (qt-urls): Rename to... (qt-url): ... this. Return a single URL built using the mirror:// scheme. Adjust all callers accordingly. --- gnu/packages/qt.scm | 124 +++++++++++++++++++++----------------------- 1 file changed, 58 insertions(+), 66 deletions(-) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 1184a85938..b73acef3c5 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -124,6 +124,7 @@ (define-module (gnu packages qt) #:use-module (gnu packages xiph) #:use-module (gnu packages xorg) #:use-module (gnu packages xml) + #:use-module (ice-9 match) #:use-module (srfi srfi-1)) (define %qt-version "5.15.8") @@ -315,27 +316,18 @@ (define-public grantlee system, and the core design of Django is reused in Grantlee.") (license license:lgpl2.1+))) -(define (qt-urls component version) - "Return a list of URLs for VERSION of the Qt5 COMPONENT." +(define (qt-url component version) + "Return a mirror URL for the Qt5 COMPONENT at VERSION." ;; We can't use a mirror:// scheme because these URLs are not exact copies: ;; the layout differs between them. - (list (string-append "https://download.qt.io/official_releases/qt/" - (version-major+minor version) "/" version - "/submodules/" component "-everywhere-opensource-src-" - version ".tar.xz") - (string-append "https://download.qt.io/official_releases/qt/" - (version-major+minor version) "/" version - "/submodules/" component "-everywhere-src-" - version ".tar.xz") - (string-append "https://download.qt.io/archive/qt/" - (version-major+minor version) "/" version - "/submodules/" component "-everywhere-opensource-src-" - version ".tar.xz") - (let ((directory (string-append "qt5" (string-drop component 2)))) - (string-append "http://sources.buildroot.net/" directory "/" - component "-everywhere-opensource-src-" version ".tar.xz")) - (string-append "https://distfiles.macports.org/qt5/" - component "-everywhere-opensource-src-" version ".tar.xz"))) + (let ((x (match (version-major version) + ("5" "-everywhere-opensource-src-") + ;; Version 6 and later dropped 'opensource' from the archive + ;; names. + (_ "-everywhere-src-")))) + (string-append "mirror://qt/qt/" + (version-major+minor version) "/" version + "/submodules/" component x version ".tar.xz"))) (define-public qtbase-5 (package @@ -343,7 +335,7 @@ (define-public qtbase-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "175ynjndpzsw69vnsq4swykn9f48568ww9b4z3yw7azkqwk13cdz")) @@ -596,7 +588,7 @@ (define-public qtbase (version "6.3.2") (source (origin (inherit (package-source qtbase-5)) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "19m9r8sf9mvyrwipn44if3nhding4ljys2mwf04b7dkhz16vlabr")) @@ -899,7 +891,7 @@ (define-public qt3d-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "18hbv4l9w0czaxcch6af9130fgs4sf400xp0pfzl81c78fwrkfsb")))) @@ -961,7 +953,7 @@ (define-public qt5compat (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1k30hnwnlbay1hnkdavgf6plsdzrryzcqd2qz8x11r477w7sr8wi")))) @@ -991,7 +983,7 @@ (define-public qtsvg-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0qnmcvp5jap4qq9w7xak66g6fsb48q1lg02rn4lycvnhgwzblbww")))) @@ -1059,7 +1051,7 @@ (define-public qtsvg (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "14i3f23k9k0731akpwa6zzhw5m3c0m2l5r7irvim4h4faah445ac")))) @@ -1090,7 +1082,7 @@ (define-public qtimageformats (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0c6fq9zcw5hbkiny56wx2fbm123x14l7habydv6zhvnhn3rhwi31")) @@ -1117,7 +1109,7 @@ (define-public qtx11extras (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1gzmf0y2byzrgfbing7xk3cwlbk1cyjlhqjbfh8n37y09gg65maf")))) @@ -1183,7 +1175,7 @@ (define-public qtxmlpatterns (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1inf7ar32a557faqpwdsmafhz1p6k8hywpw3wbsdjlj74dkgdq35")))) @@ -1212,7 +1204,7 @@ (define-public qtdeclarative-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1kb8nj17vmnky0ayiwypim7kf6rmlmfcjf6gnrw8rydmp61w0vh2")))) @@ -1258,7 +1250,7 @@ (define-public qtdeclarative ;; TODO: Package 'masm' and unbundle from sources. (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1hbw63828pp8vm9b46i2pkcbcpr4mq9nblhmpwrw2pflq0fi24xq")))) @@ -1390,7 +1382,7 @@ (define-public qtconnectivity (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1j6qgkg77ycwcjxnhh38i9np1z8pjsqrzvfk3zsyq07f6k563fnc")))) @@ -1408,7 +1400,7 @@ (define-public qtwebsockets-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "12h520lpj2pljgkyq36p1509mw4pxgb76n30d32kg52crjsk34pa")))) @@ -1431,7 +1423,7 @@ (define-public qtwebsockets (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1smbvidaybphvsmaap9v1pbkibwmng11hb925g0ww4ghwzpxkb8q")))) @@ -1471,7 +1463,7 @@ (define-public qtsensors (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1fdpgbikvxjacyipcyac0czqhv96pvc75dl9cyafslws8m53fm56")))) @@ -1500,7 +1492,7 @@ (define-public qtmultimedia-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1fz0ffpckvbg6qfhab2rrzfnvh4mlalqxcn0kbkd21mi44apjirk")) @@ -1544,7 +1536,7 @@ (define-public qtshadertools (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) ;; Note: the source bundles *patched* glslang and SPIRV-Cross ;; sources. (sha256 @@ -1573,7 +1565,7 @@ (define-public qtmultimedia (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0hqwq0ad6z8c5kyyvbaddj00mciijn2ns2r60jc3mqh98nm2js3z")) @@ -1639,7 +1631,7 @@ (define-public qtwayland-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (patches (search-patches "qtwayland-gcc-11.patch" "qtwayland-dont-recreate-callbacks.patch" "qtwayland-cleanup-callbacks.patch")) @@ -1689,7 +1681,7 @@ (define-public qtwayland (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0rwiirkibgpvx05pg2842j4dcq9ckxmcqxhaf50xx2i55z64ll83")))) (build-system cmake-build-system) @@ -1739,7 +1731,7 @@ (define-public qtserialport (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "04i8pdyml1sw4dkk9vyw2xy5bz3fp6f90fws7ag5y8iizfgs5v2v")))) @@ -1770,7 +1762,7 @@ (define-public qtserialbus (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0ws3pjbp4g8f49k8q0qa5hgyisbyk3m7kl8pwzkfws048glvz570")))) @@ -1797,7 +1789,7 @@ (define-public qtwebchannel-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1pfmy6fqis47awjb590r63y13vvsfm0fq70an3ylsknhyq3firgn")))) @@ -1815,7 +1807,7 @@ (define-public qtwebchannel (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0gqm09yqdq27kgb02idx5ycj14k5mjhh10ddp9jfs8lblimlgfni")))) @@ -1853,7 +1845,7 @@ (define-public qtwebglplugin (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1gvzhgfn55kdp5g11fg5yja5xb6wghx5sfc8vfp8zzpxnak7pbn1")))) @@ -1882,7 +1874,7 @@ (define-public qtwebview (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1b03dzlff840n2i53r105c7sv91ivwzxn7ldpgnhiyrhr897i9kj")))) @@ -1900,7 +1892,7 @@ (define-public qtlocation (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0r16qxy0pfpwvna4gpz67jk3qv3qizfd659kc9iwdh8bhz7lpjrw")))) @@ -1924,7 +1916,7 @@ (define-public qtlottie (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1c092hmf114r8jfdhkhxnn3vywj93mg33whzav47gr9mbza44icq")))) @@ -1957,7 +1949,7 @@ (define-public qttools-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1i79fwsn799x3n3jidp3f4gz9d5vi9gg6p8g8lbswb832gggigm3")))) @@ -1977,7 +1969,7 @@ (define-public qttools (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1lmfk5bhgg4daxkqrhmx4iyln7pyiz40c9cp6plyp35nz8ppvc75")))) @@ -2017,7 +2009,7 @@ (define-public qttranslations (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1h66n9cx4g65c9wrgp32h9gm3r47gyh1nrcn3ivbfbvngfawqxpg")))) @@ -2039,7 +2031,7 @@ (define-public qtscript (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0rjj1pn0fwdq0qz0nzisxza671ywfrq5cv6iplywfyflh7q4dmcs")) @@ -2058,7 +2050,7 @@ (define-public qtquickcontrols-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0yp47bpkfckms76vw0hrwnzchy8iak23ih6w9pnwrnjkmbc65drc")))) @@ -2078,7 +2070,7 @@ (define-public qtquickcontrols2-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "058dkj6272za47vnz3mxsmwsj85gxf6g0ski645fphk8s3jp2bk5")))) @@ -2105,7 +2097,7 @@ (define-public qtgraphicaleffects (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0wypji8i19kjq18qd92z8kkd3fj2n0d5hgh6xiza96833afvibj9")))) @@ -2128,7 +2120,7 @@ (define-public qtgamepad (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0vgxprgk7lak209wsg2ljzfkpwgjzscpbxmj5fyvvwm2pbnpspvk")))) @@ -2154,7 +2146,7 @@ (define-public qtscxml (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "17j6npvgr8q3lyrqmvfh1n47mkhfzk18r998hcjm2w75xj46km1n")) @@ -2181,7 +2173,7 @@ (define-public qtpositioning (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0zh45lf164nzwl1hh96qm64nyw9wzzrnm5s7sx761glz54q6l5xz")))) @@ -2212,7 +2204,7 @@ (define-public qtpurchasing (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0bjky5ncg9yhz4a63g3jl1r5pa6i09f6g8wgzs591mhybrbmhcw8")))) @@ -2228,7 +2220,7 @@ (define-public qtcharts (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1q11ank69l9qw3iks2svr0g2g6pzng9v8p87dpsmjs988f4ysmll")))) @@ -2257,7 +2249,7 @@ (define-public qtdatavis3d (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1mr2kdshahxrkjs9wlgpr59jbqvyvlax16rlnca4iq00w3v5hrdh")))) @@ -2279,7 +2271,7 @@ (define-public qtnetworkauth-5 (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0fsmpjwkzzy3281shld7gs1gj217smb1f8ai63gdvnkp0jb2fhc5")))) @@ -2294,7 +2286,7 @@ (define-public qtnetworkauth (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "0mjnz87splyxq7jwydi5ws2aqb6j7czscrkns193w425x0dgy94l")))) @@ -2314,7 +2306,7 @@ (define-public qtremoteobjects (version "6.3.2") (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "099b3vchi458i4fci9kfwan871jplqlk5l8q78mfnh33g80qnasi")))) @@ -2352,7 +2344,7 @@ (define-public qtspeech (version %qt-version) (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1q56lyj7s05sx52j5z6gcs000mni4c7mb7qyq4lfval7c06hw5p6")))) @@ -2461,7 +2453,7 @@ (define-public qtwebengine-5 (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "1qv15g5anhlfsdwnjxy21vc3zxxm8149vysi774l93iab6mxqmjg")) @@ -2789,7 +2781,7 @@ (define-public qtwebengine (source (origin (method url-fetch) - (uri (qt-urls name version)) + (uri (qt-url name version)) (sha256 (base32 "09j4w9ax8242d1yx3hmic7jcwidwdrn8sp7k89hj4l0n8mzkkd35")) From patchwork Fri Aug 11 18:44:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52760 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 0DAC127BBE9; Fri, 11 Aug 2023 19:51:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, 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 3EF2127BBE2 for ; Fri, 11 Aug 2023 19:51:17 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXDI-0003eO-00; Fri, 11 Aug 2023 14:50:20 -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 1qUXD5-0003au-KY for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:07 -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 1qUXD5-00008y-CD for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD3-0007r9-5T; Fri, 11 Aug 2023 14:50:05 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 04/13] gnu: qt-creator: Use mirror://qt for source URI. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: andreas@enge.fr, maxim.cournoyer@gmail.com, iyzsong@envs.net, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Andreas Enge , Maxim Cournoyer , =?utf-8?b?5a6L5paH5q2m?= X-Debbugs-Original-Xcc: Andreas Enge , Maxim Cournoyer , =?utf-8?b?5a6L5paH5q2m?= Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177978530036 (code B ref 65230); Fri, 11 Aug 2023 18:50:05 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:45 +0000 Received: from localhost ([127.0.0.1]:47981 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCi-0007oN-St for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:45 -0400 Received: from mail-oo1-xc2c.google.com ([2607:f8b0:4864:20::c2c]:61529) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCd-0007nN-Ow for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:40 -0400 Received: by mail-oo1-xc2c.google.com with SMTP id 006d021491bc7-56ce1bd7fc4so1789813eaf.2 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779774; x=1692384574; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=PPAOUGYthaAziHNrBPb+NZpEQ+bd0R8nP7TgCp8gplc=; b=PbYZRYQ9oyIQkF+FE2pBsuBBpqgRonksn1snQT/jgnJDAfyNSa8tz4f/tIDDq+ITDa LtJnCKPbMcoCBdOqZTNlcvGq5NmIrJWJZaZW6x+GoSHjdeipJbM0QCcOhN788+R/LgTm 10rADyj0J972mcVWxhvrQVC1g7t8dtN9w07UaY2OR4h391oebgH7ztV7ofREmGKYaxz7 YlDaoliDzS7tWoapFN50fOWLyMQx4tmJto0RyfhkGHbcBIL5FlI4EcangS4MRIi/dGZv kAa4eyHJGg7qbXtqU9jBewDmH5BZy7EEOxK4S8VoaW8Z0ZbZQHa63LwLVi8DXv5Q3C19 MqlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779774; x=1692384574; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PPAOUGYthaAziHNrBPb+NZpEQ+bd0R8nP7TgCp8gplc=; b=U7q1t00H8s0kx7LNqlE51x0q3NGOA0vMwp21BFabeaZBuOI33bm049PvNR7f11j5Xc sr2wVKqHXrjl5QhCXpRgY1pGfjLCAbzV/v+ZarSWaSWdtVUIisAMpm+QYL+sKyiCepLZ BWbxH9u/RfPbx5hcGx2rfMp0awgt2ixYAYr4H3aGaX8NlUBry/QX9dZB1D9FrHlZXC54 NAqnGXvq8zQitO7VhU65rxhUMhA7ivjoNeMGk9fQQ6jkAXCw56iZlxyKa47YS5I2ZWnC K+GETSFu/ADeBFrDT1KVbQ1dqiD66jS8XIAg7PAKgkX9p6elntqotSJ4cVTE0bjx0km1 Z6Ug== X-Gm-Message-State: AOJu0Yxwu161lEdfvpTwWuIBvEaj2s1iux3ZUoAxn1WxYcVaxEXNoD/f PokZIRLxMGyy9wJ1v7UPXuZoOYaA8Z45ag== X-Google-Smtp-Source: AGHT+IGkZNahrjMEtf6E0c7XVO4H74DB9dEJAg5tDw3pKzKBQZkkCvFk2Z2nu72wqGy3mCYigXrgEw== X-Received: by 2002:a05:6358:9925:b0:134:ce27:223c with SMTP id w37-20020a056358992500b00134ce27223cmr3221548rwa.27.1691779773971; Fri, 11 Aug 2023 11:49:33 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:33 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:51 -0400 Message-ID: <28496b4b3e232bb354e7f34c09e9386e7beb909c.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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/packages/qt.scm (qt-creator) [source]: Use mirror://qt for origin URI. --- gnu/packages/qt.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index b73acef3c5..2ca03b77d1 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -4703,7 +4703,7 @@ (define-public qt-creator (source (origin (method url-fetch) (uri (string-append - "https://download.qt.io/official_releases/qtcreator/" + "mirror://qt/qtcreator/" (version-major+minor version) "/" version "/qt-creator-opensource-src-" version ".tar.gz")) (modules '((guix build utils))) From patchwork Fri Aug 11 18:44:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52751 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 8C58B27BBEA; Fri, 11 Aug 2023 19:50:55 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 DA5C127BBE2 for ; Fri, 11 Aug 2023 19:50:54 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD9-0003dW-On; Fri, 11 Aug 2023 14:50:11 -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 1qUXD6-0003bi-MJ for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:09 -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 1qUXD6-00009f-C5; Fri, 11 Aug 2023 14:50:08 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD3-0007rK-Ox; Fri, 11 Aug 2023 14:50:05 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 05/13] gnu-maintenance: Fix docstring. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177978530043 (code B ref 65230); Fri, 11 Aug 2023 18:50:05 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:45 +0000 Received: from localhost ([127.0.0.1]:47983 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCj-0007oP-9O for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:45 -0400 Received: from mail-qt1-x829.google.com ([2607:f8b0:4864:20::829]:61935) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCf-0007nW-Dm for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:41 -0400 Received: by mail-qt1-x829.google.com with SMTP id d75a77b69052e-40694b191cfso15197171cf.3 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779776; x=1692384576; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=f7c8W+vzagx8JuxYLR+CV5RAiIA7yNaEglgjTtWHad8=; b=qn1hRoW9KvdwxeNToAqaXB19ZQoOWD4gv1sxvU26Q0enYup0VrerlUaBRgTSD2VNIy Z+JaHJHBeIMxJx671dYSFaukWpCUO7EJLbCsj4kuDKliBlskMJRI0pZ3AU21sDyyi+RW n7l1l2MXbvNZRHIWgApgzleqQHibTBX+JPv+pT9VwicwYaIyr5TzMO9HJwT+PX0fFidD HO7QaFNb8BZcWPsLCmw0U7ArapHQobPtTiD58eDTH6vmPqovzziwLTaabfMYO7tchPOS iqs0wiv3x9aNJK2K6d5p7HWyjYxQoxEZWCqV9nmd1DWlrHc1Y/pt1rPEuI0rCgmJermE nsgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779776; x=1692384576; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=f7c8W+vzagx8JuxYLR+CV5RAiIA7yNaEglgjTtWHad8=; b=gUOEs0odQf088RzlW4Qu3kvdR/EMuh/Lbs8bOhzOfogse8KEyp40RvP86i78m+syyo 1TgJl4ObcWKq2yA9j+A2lVJznOUlZwDrc8RGzZjMOj05qWqekCc7XBv28Qw0P5VygheA 4JqS4yDyEvG7DGQemiOdPeAVTPRKO1vRqmfQ0+afo5Dkc6KCQRSIXyxHEBCdRqR3q9+c oyw5nANgx+4AMNaUngRFQ8b6sn+SNn5D5qMsKwbEp3dt8PlTwHiulAdvohoIAvN+SwQ3 mKj8pli7KH+8kRa6X2VG8PppTlZCf+x2jK8zlT0bvVdGVZgovuPXiBbaWLlq0G7f0VcP 7IXA== X-Gm-Message-State: AOJu0Yyvmf5R7mslmFAIIoPPvh2942lZqxtrfYQiKrB6ZfbFXlH8eQxY yxxIpWU6e6WcrZVKdMRtwT0Z+3fV69uDOA== X-Google-Smtp-Source: AGHT+IH65ICuDfY3pUSU0ZWxXTPqDE3eCBZMxQ6a20iWLEwy3ilQcItBNODRrRdEQOSL7ZaGGO4xCQ== X-Received: by 2002:a05:622a:188f:b0:40f:2230:efc with SMTP id v15-20020a05622a188f00b0040f22300efcmr3201883qtc.55.1691779775826; Fri, 11 Aug 2023 11:49:35 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:35 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:52 -0400 Message-ID: <75e6bb603a81efd97fdfa316ebb669e29fddee29.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (import-kernel.org-release): Fix docstring. --- guix/gnu-maintenance.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index b95a45824e..a314923d3b 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -489,7 +489,7 @@ (define* (import-html-release base-url package (directory (string-append "/" package)) file->signature) "Return an for the latest release of PACKAGE (a string) -under DIRECTORY at BASE-URL, or #f. Optionally include a VERSION string to +under DIRECTORY at BASE-URL, or #f. Optionally include a VERSION string to fetch a specific version. BASE-URL should be the URL of an HTML page, typically a directory listing as @@ -806,7 +806,7 @@ (define* (import-xorg-release package #:key (version #f)) (string-append "/pub/xorg/" (dirname (uri-path uri))))))) (define* (import-kernel.org-release package #:key (version #f)) - "Return the latest release of PACKAGE, the name of a kernel.org package. + "Return the latest release of PACKAGE, a Linux kernel package. Optionally include a VERSION string to fetch a specific version." (define %kernel.org-base ;; This URL and sub-directories thereof are nginx-generated directory From patchwork Fri Aug 11 18:44:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52749 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 6D40127BBEA; Fri, 11 Aug 2023 19:50:32 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 2427027BBE2 for ; Fri, 11 Aug 2023 19:50:30 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD9-0003da-Rh; Fri, 11 Aug 2023 14:50:12 -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 1qUXD6-0003bE-3w for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:08 -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 1qUXD5-00009E-RD; Fri, 11 Aug 2023 14:50:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD4-0007rT-6T; Fri, 11 Aug 2023 14:50:06 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 06/13] gnu-maintenance: Extract url->links procedure. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:06 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177978630054 (code B ref 65230); Fri, 11 Aug 2023 18:50:06 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:46 +0000 Received: from localhost ([127.0.0.1]:47986 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCj-0007ob-LY for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:45 -0400 Received: from mail-qt1-x835.google.com ([2607:f8b0:4864:20::835]:60517) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCh-0007ne-BS for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:43 -0400 Received: by mail-qt1-x835.google.com with SMTP id d75a77b69052e-4039f7e1d3aso15353371cf.0 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779777; x=1692384577; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8GYkcMLDbzOAcGgCc1nCyv1frv9pP3ExUd45hqYSgHg=; b=oJ3/8ihgcuhuoTyxy9GjyUnuYo1r5xYlwqhTik/nBUKKz0MIWC+J4VzINj5OKVToyk uXiZAM9QTyLNwQcTlcWjRZsm1Ah44Qez+jAklx/Z0z1TyhWZagkWxcs/bSL0xKR5L7iq c+4gcZdgun/fwbQTdCep7xV77eeWy3rqcrMJGsO+OTvODAj/SdmX5Lk3h7jE1kYOoeUD RXJWyPbtmCV0ArdcEnSzf6kZmRH/Ioex/61Emx+5re5pesJjMqWVD8QVSX0bvpVvAVy8 /qXgnzZVdnz2g/byaVrDcm45kTuCWja5fV21pjk5l3IK27jDQ5vWnI2kv8RNxJWNvVR0 SNLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779777; x=1692384577; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8GYkcMLDbzOAcGgCc1nCyv1frv9pP3ExUd45hqYSgHg=; b=MxLYVaTqNR0SM2CFFnDDhD3g7bcQGKVA2+YbO0wTUB5RQYNFrEB1zO13epsxVU2aTX HVFXJRBNAZU1Mmwtva5G4Sh245E1EiscjLXnQ67Nq4mmTc5mNlKbAWN1lj5zPGtyz5qN MffejAvPNloCqJkPXL9Z6U/uaSzRhG8WMOXbcnzCRL1C6ZzOrgWvfFDz7J/OLfcWl1Au VnT4qWBtXChJs5ZWZDzIMgB0scsvaciRpbeas9/mpsXCGmdPAzIxPNKmQ2DzzKOt5aOh 7j2L0iiknpjQfOiOGvbpLEhz5TcFdw/ouAHgs8FWYs3j1BVlG3b+cmrk5N4bid8LYPTe NbYw== X-Gm-Message-State: AOJu0YwYT41g+e0cRt8tj++GNnDAaHRHsSsrx7MElRlO5z1nZ98qpRQ6 YQJUtsU9C7y8MkoOKyacNUG+QtUG5/xZ1Q== X-Google-Smtp-Source: AGHT+IFciT8MGMOjkSPn21wwKBKa0W8+0U/m8bddW0x+ZWVyhdVfszU5vMsmG9DuIMyo+CCnvUF9Zw== X-Received: by 2002:a05:622a:1a87:b0:403:be2b:590b with SMTP id s7-20020a05622a1a8700b00403be2b590bmr3132930qtc.44.1691779777741; Fri, 11 Aug 2023 11:49:37 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:37 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:53 -0400 Message-ID: <980150ff4fa380d47b016247063d7c3da52a6b55.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (url->links): New procedure. (import-html-release): Use it. --- guix/gnu-maintenance.scm | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index a314923d3b..2e0fc3e8ab 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -483,6 +483,14 @@ (define (html-links sxml) (_ links)))) +(define (url->links url) + "Return the unique links on the HTML page accessible at URL." + (let* ((uri (string->uri url)) + (port (http-fetch/cached uri #:ttl 3600)) + (sxml (html->sxml port))) + (close-port port) + (delete-duplicates (html-links sxml)))) + (define* (import-html-release base-url package #:key (version #f) @@ -499,12 +507,10 @@ (define* (import-html-release base-url package if any. Otherwise, FILE->SIGNATURE must be a procedure; it is passed a source file URL and must return the corresponding signature URL, or #f it signatures are unavailable." - (let* ((uri (string->uri (if (string-null? directory) - base-url - (string-append base-url directory "/")))) - (port (http-fetch/cached uri #:ttl 3600)) - (sxml (html->sxml port)) - (links (delete-duplicates (html-links sxml)))) + (let* ((url (if (string-null? directory) + base-url + (string-append base-url directory "/"))) + (links (url->links url))) (define (file->signature/guess url) (let ((base (basename url))) (any (lambda (link) @@ -562,7 +568,6 @@ (define* (import-html-release base-url package (define candidates (filter-map url->release links)) - (close-port port) (match candidates (() #f) ((first . _) From patchwork Fri Aug 11 18:44:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52759 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 4621227BBEA; Fri, 11 Aug 2023 19:51:20 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 4537E27BBEC for ; Fri, 11 Aug 2023 19:51:17 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD7-0003cC-Cc; Fri, 11 Aug 2023 14:50:09 -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 1qUXD6-0003bF-6c for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:08 -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 1qUXD5-00009F-TK; Fri, 11 Aug 2023 14:50:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD4-0007rc-KZ; Fri, 11 Aug 2023 14:50:06 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 07/13] gnu-maintenance: Fix indentation. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:06 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979130083 (code B ref 65230); Fri, 11 Aug 2023 18:50:06 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:51 +0000 Received: from localhost ([127.0.0.1]:47990 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCp-0007p7-1I for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:51 -0400 Received: from mail-oo1-xc2d.google.com ([2607:f8b0:4864:20::c2d]:48603) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCj-0007no-G7 for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:45 -0400 Received: by mail-oo1-xc2d.google.com with SMTP id 006d021491bc7-56c87f89178so1803201eaf.1 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779780; x=1692384580; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=H38W5XtSqRyP9rCQDBZBsL26tMu9BP0S+XiJPPuR46Q=; b=rHA2Lv/PQ7jPOhcf8xfLaPMVhOuVMYZ7m2LGJo+AoYi51Us83Tth3HGOMnkZJCE+yF rfdTIVPlTUwXLleIRj892jNnCxMd+LqJ+Z4naenNqH7E4qxsYRK9oUhT8NgJzr2PxdvB usZLFw0IHyVhWnEeJFp2s2HjUHV3W9MLEdPlZCkbPV5dygZtKeziD3ofA38iHf5zJqRx Is/bU/HAfnSn8UTaDHcDkgA830DkNiQfQdk3BQyp8xkPu34VnzIu2XopV4ZUkTvrcbyo uC4ScgMBAcFEQW0WCJB8IG1jLWuMYCUdaXoajDPoBzp1m7Hlb3RedZ7JgXro60Hzb6ab kXjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779780; x=1692384580; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=H38W5XtSqRyP9rCQDBZBsL26tMu9BP0S+XiJPPuR46Q=; b=dNMXUyWcjuG8MBsv99FE0uorUX75bnW1cF+zLvaJFAT87CIrySFA0Xt36NXWMOSrGw 2YVqILJTdsA2qlwwx3+E82uC5r7sKW/SgN6ksHE06UNiRsc0EIdRyGCyX3yLukP0kpYr 13DruV2CkYxwsLlSG2Q4Fh/+vUL8hyGQyC+mbdNkRCKc6mfS6TPy46KN8QWjsnIvA2fQ ChtC+xOeFImSdAGsSmz+Bl1bnMgHetrNK4+05r0VUzcIHvZ8jfjDFHH8YjClRtsfGSmK A1C0lu2DVMXExVE+tpsXlhvwPhirQNJZn3eOEsLLG1OJ0IsfBRLvv45ioJOoga7EgroZ Qkcg== X-Gm-Message-State: AOJu0YwGOR4t3LnVtKSm0uOREba2hBPezrLoZvnmY7a4829JWT0Uodpr hYoFmvBMZXNkQQMPBX/Ss+k2hL5DgWU53w== X-Google-Smtp-Source: AGHT+IEcnbNIqRXXhg3KbKqOU4SSwY4IXaa6+t+YuE8brVoCroiC+LflmgCDY1S7rEGh6gCcyaNn1w== X-Received: by 2002:a05:6358:908:b0:135:48d9:eb90 with SMTP id r8-20020a056358090800b0013548d9eb90mr3279692rwi.13.1691779779616; Fri, 11 Aug 2023 11:49:39 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:39 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:54 -0400 Message-ID: <31253e9ab7c25b82b2a625a14fcfe22c4af9eb28.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm: Re-indent file. --- guix/gnu-maintenance.scm | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 2e0fc3e8ab..67abbc1c5a 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -578,11 +578,11 @@ (define* (import-html-release base-url package (coalesce-sources candidates)) ;; Select the most recent release and return it. (reduce (lambda (r1 r2) - (if (version>? (upstream-source-version r1) - (upstream-source-version r2)) - r1 r2)) - first - (coalesce-sources candidates))))))) + (if (version>? (upstream-source-version r1) + (upstream-source-version r2)) + r1 r2)) + first + (coalesce-sources candidates))))))) ;;; @@ -656,20 +656,20 @@ (define* (import-gnu-release package #:key (version #f)) (tarballs (filter (lambda (file) (string=? version (tarball->version file))) relevant))) - (match tarballs - (() #f) - (_ - (upstream-source - (package name) - (version version) - (urls (map (lambda (file) - (string-append "mirror://gnu/" - (string-drop file - (string-length "/gnu/")))) - ;; Sort so that the tarball with the same compression - ;; format as currently used in PACKAGE comes first. - (sort tarballs better-tarball?))) - (signature-urls (map (cut string-append <> ".sig") urls)))))))) + (match tarballs + (() #f) + (_ + (upstream-source + (package name) + (version version) + (urls (map (lambda (file) + (string-append "mirror://gnu/" + (string-drop file + (string-length "/gnu/")))) + ;; Sort so that the tarball with the same compression + ;; format as currently used in PACKAGE comes first. + (sort tarballs better-tarball?))) + (signature-urls (map (cut string-append <> ".sig") urls)))))))) (define %package-name-rx ;; Regexp for a package name, e.g., "foo-X.Y". Since TeXmacs uses From patchwork Fri Aug 11 18:44:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52755 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 705BE27BBE9; Fri, 11 Aug 2023 19:51:07 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 7DEB227BBEA for ; Fri, 11 Aug 2023 19:51:04 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXDJ-0003fV-BF; Fri, 11 Aug 2023 14:50:21 -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 1qUXD6-0003bg-Hz for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:09 -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 1qUXD6-00009a-7n; Fri, 11 Aug 2023 14:50:08 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD5-0007rk-24; Fri, 11 Aug 2023 14:50:07 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 08/13] gnu-maintenance: Accept package object in 'import-html-release' procedure. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979230096 (code B ref 65230); Fri, 11 Aug 2023 18:50:07 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:52 +0000 Received: from localhost ([127.0.0.1]:47993 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCp-0007pA-Ci for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:51 -0400 Received: from mail-qt1-x835.google.com ([2607:f8b0:4864:20::835]:56583) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCl-0007o7-2F for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:47 -0400 Received: by mail-qt1-x835.google.com with SMTP id d75a77b69052e-4103c24a989so3351651cf.1 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779781; x=1692384581; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=nJsQXrgXGbwtflP2tufaD4dT9tVxGKDfykO+85cknIU=; b=bLX4NDo0djFvFul2Zu0oDRNbpXOUfQ+QqY3Q8/mPWYAkb6gnWk/UVAQ4SvneJwMjBA +3B7GnuUUMzcxpB6YXfHHJC+Ba0iUabj0FlRp1l0fJAIUy/7MHt0OnL3r3Au0xEB7mDy Ah77nyPs1R+TIhPpuz6VNnKafuKBXPzwIWnyx3jOKVPv6u+qRgQ1MOFyFZe1cCc+zyJm +IWyxDFXJcIK12Wxt8hgsPrzGfUuF4LqucKSQGFaQdrQKBoFw/pkmGkoAt8Me+ECBmFZ EGmIXPJVoJ5TtMadvruW2jHHUegCtHeJn0UrQnYAkLiCoXxThAE+i5VoFgYkZEZnabSU HC8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779781; x=1692384581; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=nJsQXrgXGbwtflP2tufaD4dT9tVxGKDfykO+85cknIU=; b=VWnDx+/TvFdU+4r1I27a4vUAqksyDhv1BZgP5Q+UI3IznxSRalUrnBWA+xLTq+D34S 4/5LTTo8OKy+59xTH+hq0UuEzHuRTo+ENp+PKwrI42RSPLBx0u8XS57XNiqvxHrYF6pT nKyDRVsiNJveeOR4A6JjE9nHaPl9o8mRc2yZztgHomRS+SWDufRMlvYbTCJMWaVHooAU /IubRJL9cMyghfOwmiV2fg8L714HXDXsf3PQYm6og7GAiSV5zKzJQIFW0NAET/PEtdAB BJDvt0wi4bW2WLbxE5QYTL154S4qJu5GiyumJhFdV3TLLJs0SSj48aBi57lSSrCFcJKA wL7A== X-Gm-Message-State: AOJu0Yyq7O6xOc4hQdLz7BniiEtSfeHxxoTIsnJQOM19zMc0uzGbNZrY kAoNR0dpWa2wBuLZflDgl3dQwyIkeEkXvw== X-Google-Smtp-Source: AGHT+IEoMrKxgkL9kk4ThIflzHKql+/bdjR9BS8lfeOm/i3EZemAjFXRDelcuJUB79JBk5GpPAA6PQ== X-Received: by 2002:a05:622a:13c8:b0:3f6:c0f7:a5d7 with SMTP id p8-20020a05622a13c800b003f6c0f7a5d7mr3562839qtk.35.1691779781444; Fri, 11 Aug 2023 11:49:41 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:41 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:55 -0400 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 This is in preparation for a new URL rewriting feature, which will need to have the current version information available. * guix/gnu-maintenance.scm (import-html-release): Update doc. Adjust default value of the DIRECTORY argument. Bind PACKAGE in lexical scope so that its value there is unchanged. (import-savannah-release, import-kernel.org-release) (import-html-updatable-release): Adjust accordingly. --- guix/gnu-maintenance.scm | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 67abbc1c5a..13d6c1c7f2 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -494,11 +494,12 @@ (define (url->links url) (define* (import-html-release base-url package #:key (version #f) - (directory (string-append "/" package)) + (directory (string-append + "/" (package-upstream-name package))) file->signature) - "Return an for the latest release of PACKAGE (a string) -under DIRECTORY at BASE-URL, or #f. Optionally include a VERSION string to -fetch a specific version. + "Return an for the latest release of PACKAGE under +DIRECTORY at BASE-URL, or #f. Optionally include a VERSION string to fetch a +specific version. BASE-URL should be the URL of an HTML page, typically a directory listing as found on 'https://kernel.org/pub'. @@ -507,7 +508,8 @@ (define* (import-html-release base-url package if any. Otherwise, FILE->SIGNATURE must be a procedure; it is passed a source file URL and must return the corresponding signature URL, or #f it signatures are unavailable." - (let* ((url (if (string-null? directory) + (let* ((package (package-upstream-name package)) + (url (if (string-null? directory) base-url (string-append base-url directory "/"))) (links (url->links url))) @@ -730,7 +732,6 @@ (define* (import-savannah-release package #:key (version #f)) (match (origin-uri (package-source package)) ((? string? uri) uri) ((uri mirrors ...) uri)))) - (package (package-upstream-name package)) (directory (dirname (uri-path uri)))) ;; Note: We use the default 'file->signature', which adds ".sig", ".asc", ;; or whichever detached signature naming scheme PACKAGE uses. @@ -825,7 +826,6 @@ (define* (import-kernel.org-release package #:key (version #f)) (match (origin-uri (package-source package)) ((? string? uri) uri) ((uri mirrors ...) uri)))) - (package (package-upstream-name package)) (directory (dirname (uri-path uri)))) (import-html-release %kernel.org-base package #:version version @@ -869,8 +869,7 @@ (define* (import-html-updatable-release package #:key (version #f)) "://" (uri-host uri)))) (directory (if custom "" - (dirname (uri-path uri)))) - (package (package-upstream-name package))) + (dirname (uri-path uri))))) (false-if-networking-error (import-html-release base package #:version version From patchwork Fri Aug 11 18:44:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52753 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 757A727BBE9; Fri, 11 Aug 2023 19:51:03 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 9B4C027BBE2 for ; Fri, 11 Aug 2023 19:51:02 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD9-0003dE-C5; Fri, 11 Aug 2023 14:50:11 -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 1qUXD7-0003by-6Z for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:09 -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 1qUXD6-0000A2-Sz; Fri, 11 Aug 2023 14:50:08 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD5-0007s0-Hs; Fri, 11 Aug 2023 14:50:07 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 09/13] gnu-maintenance: Document nested procedures in 'import-html-release'. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979230103 (code B ref 65230); Fri, 11 Aug 2023 18:50:07 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:52 +0000 Received: from localhost ([127.0.0.1]:47995 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCp-0007pN-Ts for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:52 -0400 Received: from mail-qt1-x82d.google.com ([2607:f8b0:4864:20::82d]:57685) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCm-0007oG-P9 for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:49 -0400 Received: by mail-qt1-x82d.google.com with SMTP id d75a77b69052e-4103cec468fso2778371cf.3 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779783; x=1692384583; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=5I9rceGXcH20fgH2Z7SMk5CkvVXegx7nRdTB4S8WdA4=; b=F1rYmum9EqCbI4r9usk5np4pHApfr8UYsoOlXxVUcY9S7IiHyjb5qC85/vewzJReHX 1Vmu5trlSj8FLy1LClM6A9THhjPhoEBveGNVCkXl4nM27V2uxinH/rjDjRpewdmfF3M2 sidygSsc3djm4EEns6pHjeEFL0KpYXh/nCfPHd+BEbYhKAqkA/u4ew46RXVZkWW7n7RZ Y/Wvj8Q24oTHJXRXEw4/B0POyanvKF8MplrKZw5KyNuULtTaUzpvB+cguZsKr/rx69qt coDFgUgRO9+2o9HouvX6w/JgRZCaes/gPsq2TKdY50+1xiuP3YJF+Rxb6KGgOYZjw1DQ 4mZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779783; x=1692384583; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5I9rceGXcH20fgH2Z7SMk5CkvVXegx7nRdTB4S8WdA4=; b=OHPqS9ko9OMIg3/c8Za0iOBTWA+6NfijPJnPMxti/RL4vH71lRw+O4HU94RQlzrjwi ipN4gxCUeJlCvFURFnqQV6f7Ug+6SALrhEXefZ8S+/p9e5e/hZMJYUL6rjt6o56tKuJ7 h0dUQV+11w133cYO0RceiuhRRkQiiThYa8lhHE2AfQMQBA6Us6556NPYTml+HHs5PTXP fP8hwOW5PKh7BsKljYERJSyvrdVVs+po+7/KwcrjV/z3JwC120sq+06dziwvSUEFXjpV nsHLWMsPhSrMGPnjoMOBJuivbETyHF7g41jRTcdPrb/P1GuRdaqv4BTdBZUCrYAmlzJc V6XA== X-Gm-Message-State: AOJu0Yz7zvchUz8eu+Ng/NNgq7UjrCjEwDZRNzKa1C7xWA1yeuauMj1e d+2QMPC/Tt7onEkT7ULKczUhrxYJJL727w== X-Google-Smtp-Source: AGHT+IH4MpUc3lnv4nyvm9UwGnvpqJm/XJAcX53q6dk5nlfWhfhE6WmBVEx+h3ZCUoA5dGEAt/No+Q== X-Received: by 2002:ac8:57cc:0:b0:404:c430:6695 with SMTP id w12-20020ac857cc000000b00404c4306695mr3236642qta.53.1691779783098; Fri, 11 Aug 2023 11:49:43 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:42 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:56 -0400 Message-ID: <0d5d4a22cf8e465d95b8462627af55815b3a823a.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (import-html-release): Add docstring to the 'file->signature/guess' and 'url->release' nested procedures. --- guix/gnu-maintenance.scm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 13d6c1c7f2..9bab8e9e5f 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -514,6 +514,7 @@ (define* (import-html-release base-url package (string-append base-url directory "/"))) (links (url->links url))) (define (file->signature/guess url) + "Return the first link that matches a signature extension, else #f." (let ((base (basename url))) (any (lambda (link) (any (lambda (extension) @@ -524,6 +525,8 @@ (define* (import-html-release base-url package links))) (define (url->release url) + "Return an object if a release file was found at URL, +else #f." (let* ((base (basename url)) (base-url (string-append base-url directory)) (url (cond ((and=> (string->uri url) uri-scheme) ;full URL? @@ -574,7 +577,7 @@ (define* (import-html-release base-url package (() #f) ((first . _) (if version - ;; find matching release version and return it + ;; Find matching release version and return it. (find (lambda (upstream) (string=? (upstream-source-version upstream) version)) (coalesce-sources candidates)) From patchwork Fri Aug 11 18:44:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52757 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 5B4DB27BBEA; Fri, 11 Aug 2023 19:51:14 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 4870B27BBE2 for ; Fri, 11 Aug 2023 19:51:11 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXDJ-0003es-6q; Fri, 11 Aug 2023 14:50:21 -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 1qUXD8-0003cs-E8 for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:10 -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 1qUXD7-0000AQ-Nv; Fri, 11 Aug 2023 14:50:10 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD6-0007sH-0Q; Fri, 11 Aug 2023 14:50:08 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 10/13] gnu-maintenance: Extract 'canonicalize-url' from 'import-html-release'. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979730132 (code B ref 65230); Fri, 11 Aug 2023 18:50:07 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:57 +0000 Received: from localhost ([127.0.0.1]:48000 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCv-0007pu-9i for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:57 -0400 Received: from mail-oo1-xc2b.google.com ([2607:f8b0:4864:20::c2b]:58563) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCp-0007og-6C for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:51 -0400 Received: by mail-oo1-xc2b.google.com with SMTP id 006d021491bc7-56d263da4f2so1826940eaf.0 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779785; x=1692384585; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=g55NbxC8II99lN9uEIluIYDExiUPKIyvBcyQhN04wk4=; b=bpQDAW66tsNnkkqLEjUQ3xBZbsyt2uH3WClbwLVwVTbkVbVIzrPAzQr7g4cYJgg2wW NlPBKYvuiVLUwcWz4jCy470D3zfefxOoRo2hhgezBbVdXTAcXeKg7HPw7f3NmVp3haKD UBzNwzDBfTP8CqRyRpNH84wPK/dVkt6ykDVDGVeZSLlUv3+D9R2jqVvUmLAYY3/HdUEg /KB0tKql0CWv7Gza7j0H3Nu99bqjNaKI7K82OObQkCT9QVv0xYgiBGQPF6lo0eY/chTV 3hq/KROrZJRsTPce4gg9lkMgSGaONqn8pCZwc9UQ1vgP2AylMm31zbpv2sPNLHQnPNug ZFBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779785; x=1692384585; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=g55NbxC8II99lN9uEIluIYDExiUPKIyvBcyQhN04wk4=; b=W2LnXP9BqS7QIV5nTgsvCz8D9XavlJP3OseFLYaJZ1bsfZQeSHb71QA+WjBoQzpcGZ NcB+O49r/G6mK1JxFoi4zN4kcxc+U+4wqA71KpeCLuHo+gJ161yU2vH40MYJto/zCxIq Iy6bWZyvMW32UUatNSA4Oj9xyxAbJFyG0sJgg7yFJtEMlJKTKghxVgJRL60xOWeMNAN5 5+Yl/+jBkiGZ0p3wFEYfQonvC+YlNDBU+MrRzHHp1qauL+EK0j2mNSkcVnVcNr/zXb1A LZTi0Yq4LldcVDe4N8rM8Ud1RJ9AzG4Vs88Irx8LsGJZ/hRFkaHpRyXi/EgzIJyKGTQx IezA== X-Gm-Message-State: AOJu0YxMnsNqjsP1M+o06PRSylElao5yfLafHF1uZqfEYYGqHJKRdoOp +GGFSztUHnkZ2oMOOq/EAwymski2I6WIOQ== X-Google-Smtp-Source: AGHT+IEbwN71y4Mywsd/AHywID/6Z+gca27mVk9vyyHWyvWDZbP3tgDMkac00oTTXZpiLPgR/p2g2w== X-Received: by 2002:a05:6358:2612:b0:133:595:1c with SMTP id l18-20020a056358261200b001330595001cmr2641878rwc.31.1691779785336; Fri, 11 Aug 2023 11:49:45 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:45 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:57 -0400 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (canonicalize-url): New procedure, extracted from... (import-html-release): ... here. Use it. Rename inner PACKAGE variable to NAME, to explicit it is a string and not a package object. --- guix/gnu-maintenance.scm | 70 +++++++++++++++++++--------------------- 1 file changed, 34 insertions(+), 36 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 9bab8e9e5f..abba891d4b 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -491,6 +491,33 @@ (define (url->links url) (close-port port) (delete-duplicates (html-links sxml)))) +(define (canonicalize-url url base-url) + "Make relative URL absolute, by appending URL to BASE-URL as required. If +URL is a directory instead of a file, it should be suffixed with a slash (/)." + (cond ((and=> (string->uri url) uri-scheme) + ;; Fully specified URL. + url) + ((string-prefix? "//" url) + ;; Full URL lacking a URI scheme. Reuse the URI scheme of the + ;; document that contains the URL. + (string-append (symbol->string (uri-scheme (string->uri base-url))) + ":" url)) + ((string-prefix? "/" url) + ;; Absolute URL. + (let ((uri (string->uri base-url))) + (uri->string + (build-uri (uri-scheme uri) + #:host (uri-host uri) + #:port (uri-port uri) + #:path url)))) + ;; URL is relative to BASE-URL, which is assumed to be a directory. + ((string-suffix? "/" base-url) + (string-append base-url url)) + (else + ;; URL is relative to BASE-URL, which is assumed to denote a file + ;; within a directory. + (string-append (dirname base-url) "/" url)))) + (define* (import-html-release base-url package #:key (version #f) @@ -508,11 +535,12 @@ (define* (import-html-release base-url package if any. Otherwise, FILE->SIGNATURE must be a procedure; it is passed a source file URL and must return the corresponding signature URL, or #f it signatures are unavailable." - (let* ((package (package-upstream-name package)) + (let* ((name (package-upstream-name package)) (url (if (string-null? directory) base-url (string-append base-url directory "/"))) - (links (url->links url))) + (links (map (cut canonicalize-url <> url) (url->links url)))) + (define (file->signature/guess url) "Return the first link that matches a signature extension, else #f." (let ((base (basename url))) @@ -526,42 +554,12 @@ (define* (import-html-release base-url package (define (url->release url) "Return an object if a release file was found at URL, -else #f." - (let* ((base (basename url)) - (base-url (string-append base-url directory)) - (url (cond ((and=> (string->uri url) uri-scheme) ;full URL? - url) - ;; full URL, except for URI scheme. Reuse the URI - ;; scheme of the document that contains the link. - ((string-prefix? "//" url) - (string-append - (symbol->string (uri-scheme (string->uri base-url))) - ":" url)) - ((string-prefix? "/" url) ;absolute path? - (let ((uri (string->uri base-url))) - (uri->string - (build-uri (uri-scheme uri) - #:host (uri-host uri) - #:port (uri-port uri) - #:path url)))) - - ;; URL is a relative path and BASE-URL may or may not - ;; end in slash. - ((string-suffix? "/" base-url) - (string-append base-url url)) - (else - ;; If DIRECTORY is non-empty, assume BASE-URL - ;; denotes a directory; otherwise, assume BASE-URL - ;; denotes a file within a directory, and that URL - ;; is relative to that directory. - (string-append (if (string-null? directory) - (dirname base-url) - base-url) - "/" url))))) - (and (release-file? package base) +else #f. URL is assumed to fully specified." + (let ((base (basename url))) + (and (release-file? name base) (let ((version (tarball->version base))) (upstream-source - (package package) + (package name) (version version) ;; uri-mirror-rewrite: Don't turn nice mirror:// URIs into ftp:// ;; URLs during "guix refresh -u". From patchwork Fri Aug 11 18:44:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52754 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 BF98D27BBE2; Fri, 11 Aug 2023 19:51:06 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, 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 E5FBE27BBE9 for ; Fri, 11 Aug 2023 19:51:03 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXD9-0003dG-EJ; Fri, 11 Aug 2023 14:50:11 -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 1qUXD6-0003bk-Ss for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:09 -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 1qUXD6-00009p-JZ; Fri, 11 Aug 2023 14:50:08 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD6-0007sT-Fl; Fri, 11 Aug 2023 14:50:08 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 11/13] gnu-maintenance: Add support to rewrite version in URL path. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:08 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979830139 (code B ref 65230); Fri, 11 Aug 2023 18:50:08 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:58 +0000 Received: from localhost ([127.0.0.1]:48002 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCv-0007px-Nf for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:58 -0400 Received: from mail-qt1-x82f.google.com ([2607:f8b0:4864:20::82f]:56519) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCq-0007ox-VU for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:53 -0400 Received: by mail-qt1-x82f.google.com with SMTP id d75a77b69052e-40ffbc3488eso15008511cf.0 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779787; x=1692384587; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=2MryDjP85367E1blpVTVEb5PE2rGYkRHteqJG7124uc=; b=UfsLeCzWkceDmQbz+Jov1cyuevQ0tGayiKkilbYSa03Mot9GDoaTLJaoEC4KXPfNZZ 8SULmgMK9RAidyP5IeZtOoHXo7HQ9G/5UiAv2+VyU8Bb79RZ26G0c4tkD0fV2WdOLeGp fIXLGkVPdUoQmFIpXpxzxnjIGRCqyOSG9jOnosZZAyeXcPppOyExVsSKzinotdfpNxa4 gArZcJnmvO/yZzU6FX77hb/N9TSgTQMvoBC/0rUrg7VO/gAjRzNoRFTOZe8WDvBcZZSk iwS2Rj5AyJfHpQriG9ixV9wtghgt1gSCthIyYGsLy4Zj6GXm3vQIS3GCa5dWjaJU1WHS 2LLw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779787; x=1692384587; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2MryDjP85367E1blpVTVEb5PE2rGYkRHteqJG7124uc=; b=QckdXnjcF4fW1OwVQwX1a9PT702nfZEU2t4Z8cm8pCNBgMFWoNDHp/Err8EGcPf3VP FsDcqLIKG8VEKfGL0AX73c32I6fOMxdJyEpsyqTJXx2034hQytijt6CUvxcICa67Ucqi 18GVLIu6oZRL4sQuBvGrYjrTOzVkUQb+U2TH7+ZJFk686HVC5hhBaJLkClqYxQr+BfoJ le/13mDwcBC2+RW5PDtjNgAAPO9f2maG9t1ma7Plyvdb+RIJ0PbxdwBkog8AgER6jtJi T3QCi8yGRpA7Ggc46CCgVn8iYql4w6+AiSlnGqugzuzlxLbH21zvDKDoN3/CEj7xt11O kIzw== X-Gm-Message-State: AOJu0YyfV02GbfToMZWz0/r5RyKE2JWkFoPRORElToRX0yJ9rvwWrMnj wICl6APC1OLcUKRpJheGKIRZy+k3U4qVpg== X-Google-Smtp-Source: AGHT+IEZunt0/X44gwmXSj+yT14xFLxyMzkIbaVJXuVNwLjIjWFHmVuKa7w5Scqo63YBzJ/hfBzUVw== X-Received: by 2002:a05:622a:1353:b0:40d:9d0d:bdd with SMTP id w19-20020a05622a135300b0040d9d0d0bddmr3443074qtk.3.1691779787176; Fri, 11 Aug 2023 11:49:47 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:46 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:58 -0400 Message-ID: <28844ba1a02358a9a2cde42aa06e888fd7c250b1.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 Fixes . Previously, the generic HTML updater would only look for the list of files found at the parent of its current source URL, ignoring that the URL may embed the version elsewhere in its path. This could cause 'guix refresh' to report no updates available, while in fact there were, such as for 'libuv'. * guix/gnu-maintenance.scm (strip-trailing-slash): New procedure. (%version-rx): New variable. (rewrite-url): New procedure. (import-html-release): New rewrite-url? argument. When true, use the above procedure. (import-html-updatable-release): Call import-html-release with #:rewrite-url set to #t. * tests/gnu-maintenance.scm ("rewrite-url, to-version specified") ("rewrite-url, without to-version"): New tests. --- guix/gnu-maintenance.scm | 102 ++++++++++++++++++++++++++++++++++++-- tests/gnu-maintenance.scm | 43 ++++++++++++++++ 2 files changed, 142 insertions(+), 3 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index abba891d4b..3cd84ee3d7 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2012, 2013 Nikita Karetnikov ;;; Copyright © 2021 Simon Tournier ;;; Copyright © 2022 Maxime Devos +;;; Copyright © 2023 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -26,6 +27,7 @@ (define-module (guix gnu-maintenance) #:use-module (ice-9 regex) #:use-module (ice-9 match) #:use-module (srfi srfi-1) + #:use-module (srfi srfi-2) #:use-module (srfi srfi-11) #:use-module (srfi srfi-26) #:use-module (rnrs io ports) @@ -61,6 +63,7 @@ (define-module (guix gnu-maintenance) gnu-package? uri-mirror-rewrite + rewrite-url release-file? releases @@ -518,9 +521,93 @@ (define (canonicalize-url url base-url) ;; within a directory. (string-append (dirname base-url) "/" url)))) +(define (strip-trailing-slash s) + "Strip any trailing slash from S, a string." + (if (string-suffix? "/" s) + (string-drop-right s 1) + s)) + +;;; TODO: Extend to support the RPM and GNOME version schemes? +(define %version-rx "[0-9.]+") + +(define* (rewrite-url url version #:key to-version) + "Rewrite URL so that the URL path components matching the current VERSION or +VERSION-MAJOR.VERSION-MINOR are updated with that of the latest version found +by crawling the corresponding URL directories. Alternatively, when TO-VERSION +is specified, rewrite version matches directly to it without crawling URL. + +For example, the URL +\"https://dist.libuv.org/dist/v1.45.0/libuv-v1.45.0.tar.gz\" could be +rewritten to something like +\"https://dist.libuv.org/dist/v1.46.0/libuv-v1.46.0.tar.gz\"." + ;; XXX: major-minor may be #f if version is not a triplet but a single + ;; number such as "2". + (let* ((major-minor (false-if-exception (version-major+minor version))) + (to-major-minor (false-if-exception + (and=> to-version version-major+minor))) + (uri (string->uri url)) + (url-prefix (string-drop-right url (string-length (uri-path uri)))) + (url-prefix-components (string-split url-prefix #\/)) + (path (uri-path uri)) + ;; Strip a forward slash on the path to avoid a double slash when + ;; string-joining later. + (path (if (string-prefix? "/" path) + (string-drop path 1) + path)) + (path-components (string-split path #\/))) + (string-join + (reverse + (fold + (lambda (s parents) + (if to-version + ;; Direct rewrite case; the archive is assumed to exist. + (let ((u (string-replace-substring s version to-version))) + (cons (if (and major-minor to-major-minor) + (string-replace-substring u major-minor to-major-minor) + u) + parents)) + ;; More involved HTML crawl case. + (let* ((pattern (if major-minor + (format #f "(~a|~a)" version major-minor) + (format #f "(~a)" version))) + (m (string-match pattern s))) + (if m + ;; Crawl parent and rewrite current component. + (let* ((parent-url (string-join (reverse parents) "/")) + (links (url->links parent-url)) + ;; The pattern matching the version. + (pattern (string-append "^" (match:prefix m) + "(" %version-rx ")" + (match:suffix m) "$")) + (candidates (filter-map + (lambda (l) + ;; Links may be followed by a + ;; trailing '/' in the case of + ;; directories. + (and-let* + ((l (strip-trailing-slash l)) + (m (string-match pattern l)) + (v (match:substring m 1))) + (cons v l))) + links))) + ;; Retrieve the item having the largest version. + (if (null? candidates) + (error "no candidates found in rewrite-url") + (cons (cdr (first (sort candidates + (lambda (x y) + (version>? (car x) + (car y)))))) + parents))) + ;; No version found in path component; continue. + (cons s parents))))) + (reverse url-prefix-components) + path-components)) + "/"))) + (define* (import-html-release base-url package #:key - (version #f) + rewrite-url? + version (directory (string-append "/" (package-upstream-name package))) file->signature) @@ -534,11 +621,19 @@ (define* (import-html-release base-url package When FILE->SIGNATURE is omitted or #f, guess the detached signature file name, if any. Otherwise, FILE->SIGNATURE must be a procedure; it is passed a source file URL and must return the corresponding signature URL, or #f it signatures -are unavailable." - (let* ((name (package-upstream-name package)) +are unavailable. + +When REWRITE-URL? is #t, versioned components in BASE-URL and/or DIRECTORY are +also updated to the latest version, as explained in the doc of the +\"rewrite-url\" procedure used." + (let* ((current-version (package-version package)) + (name (package-upstream-name package)) (url (if (string-null? directory) base-url (string-append base-url directory "/"))) + (url (if rewrite-url? + (rewrite-url url current-version #:to-version version) + url)) (links (map (cut canonicalize-url <> url) (url->links url)))) (define (file->signature/guess url) @@ -873,6 +968,7 @@ (define* (import-html-updatable-release package #:key (version #f)) (dirname (uri-path uri))))) (false-if-networking-error (import-html-release base package + #:rewrite-url? #t #:version version #:directory directory)))) diff --git a/tests/gnu-maintenance.scm b/tests/gnu-maintenance.scm index 516e02ec6a..196a6f9092 100644 --- a/tests/gnu-maintenance.scm +++ b/tests/gnu-maintenance.scm @@ -147,4 +147,47 @@ (define-module (test-gnu-maintenance) (equal? (list expected-signature-url) (upstream-source-signature-urls update)))))) +(test-equal "rewrite-url, to-version specified" + "https://download.qt.io/official_releases/qt/6.5/6.5.2/\ +submodules/qtbase-everywhere-src-6.5.2.tar.xz" + (rewrite-url "https://download.qt.io/official_releases/qt/6.3/6.3.2/\ +submodules/qtbase-everywhere-src-6.3.2.tar.xz" "6.3.2" #:to-version "6.5.2")) + +(test-equal "rewrite-url, without to-version" + "https://dist.libuv.org/dist/v1.46.0/libuv-v1.46.0.tar.gz" + (with-http-server + ;; First reply, crawling https://dist.libuv.org/dist/. + `((200 "\ + + +Index of dist + +../ +v1.44.0/ +v1.44.1/ +v1.44.2/ +v1.45.0/ +v1.46.0/ + +") + ;; Second reply, crawling https://dist.libuv.org/dist/v1.46.0/. + (200 "\ + + +Index of dist/v1.46.0 + +../ + + libuv-v1.46.0-dist.tar.gz +libuv-v1.46.0-dist.tar.gz.sign + + libuv-v1.46.0.tar.gz + + libuv-v1.46.0.tar.gz.sign + +")) + (rewrite-url "https://dist.libuv.org/dist/v1.45.0/libuv-v1.45.0.tar.gz" + "1.45.0"))) + (test-end) From patchwork Fri Aug 11 18:44:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52758 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 C5E3027BBE9; Fri, 11 Aug 2023 19:51:18 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, 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 746F427BBE9 for ; Fri, 11 Aug 2023 19:51:15 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXDD-0003di-Cn; Fri, 11 Aug 2023 14:50: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 1qUXD8-0003cr-E8 for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:10 -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 1qUXD7-0000AR-TT; Fri, 11 Aug 2023 14:50:10 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD6-0007si-VW; Fri, 11 Aug 2023 14:50:08 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 12/13] gnu-maintenance: Allow mirror URLs to fallback to the generic HTML updater. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:08 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177979930146 (code B ref 65230); Fri, 11 Aug 2023 18:50:08 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:49:59 +0000 Received: from localhost ([127.0.0.1]:48004 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCw-0007q4-Gv for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:59 -0400 Received: from mail-qt1-x830.google.com ([2607:f8b0:4864:20::830]:58551) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCs-0007p4-LR for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:56 -0400 Received: by mail-qt1-x830.google.com with SMTP id d75a77b69052e-40ffc70e740so14748271cf.0 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779789; x=1692384589; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8zda/LFJy2MCKDfhB5aN39WP1zFDBKdo3JV4vlknS0E=; b=gOkHqED52dbyCCZrwQshw4ZHwpRFET5WsOQDUkSkQdTA1FkMALeQTbiQIYykk4HLqJ DmM3iFQsBOydBtkDriKtVRX3YiCkb1JsPqRIn9bM03IfvyZfJBP3B5rN1bVnBbxe3iWp aWCUQHDXCalpxF6+UGCg4FdPciJClxIkk8gsxDJ/Wutf0iHtI4ODAcFs2ryZOkZj8sJc y6dqgmp9o1dLrD9pVTLlOVZE+c9YQFMbDIXHFpopduaKUo+jIWYGgtjbkjN8iE5uM65O 8Qr+kcCuZtwe2aCr5XmbkUumDZAw/oKuSTnM24rxFtc6bAscg6H+eGhdpmxRW1AO3LRo corw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779789; x=1692384589; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8zda/LFJy2MCKDfhB5aN39WP1zFDBKdo3JV4vlknS0E=; b=e/dxjhOzEoW2HLsxsej325jIZMe/6/Ub7GqV5Ktp6SuKljqJpuYHnuv6nHFYmUL9tX kkjClxd27vESRvbBfVy6TrefAImWBMXVEzdV9RhHsCL+BNS8ST89TR3ueHuhmoFn95UR UFeT4A6HErPXqp9eyknQQEnWQkswVSzF0BKQcH+J7MeSz8IOhvmddMpAaxS2l8X7L951 z+KjmBVAYgRFX+NaXVXemo1tf8LbWnoIPftrl/YwejVmJ+1wed5ctvIIm5Ovmc81zEIP r607iLoMjp/vPmF2oKey/X3Ff8Vk86ZlqnfZ9vCB7bToazTneXlGlp3iCGCmXJmTxRFC 0A2w== X-Gm-Message-State: AOJu0YzYO7QtiRDY7MC6Gdhyw/ZBKajzdjnvXClwWMWLrdJiwUfJvqR5 lHUwGV+VsjIjcoryZVSSJSuGEMD9VqMANA== X-Google-Smtp-Source: AGHT+IGcGAvtRKq6ANNKQCwbsEXsjYLd3ksy+JC+YX9uEShiFI3/RXYlcGAvMrdIiYobX2b+uPu9ig== X-Received: by 2002:ac8:7d43:0:b0:40f:f45c:742a with SMTP id h3-20020ac87d43000000b0040ff45c742amr3309688qtb.56.1691779788890; Fri, 11 Aug 2023 11:49:48 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:48 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:44:59 -0400 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (http-url?): Extract from html-updatable-package?, modify to return the HTTP URL, and support the mirror:// scheme. (%disallowed-hosting-sites): New variable, extracted from html-updatable-package. (html-updatable-package?): Rewrite a mirror:// URL to an HTTP or HTTPS one. * guix/download.scm (%mirrors): Update comment. --- guix/download.scm | 4 ++- guix/gnu-maintenance.scm | 58 +++++++++++++++++++++++++--------------- 2 files changed, 40 insertions(+), 22 deletions(-) diff --git a/guix/download.scm b/guix/download.scm index d5da866179..accffae9c8 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -51,7 +51,9 @@ (define-module (guix download) ;;; Code: (define %mirrors - ;; Mirror lists used when `mirror://' URLs are passed. + ;; Mirror lists used when `mirror://' URLs are passed. The first mirror + ;; entry of each set should ideally be the most authoritative one, as that's + ;; what the generic HTML updater will pick to look for updates. (let* ((gnu-mirrors '(;; This one redirects to a (supposedly) nearby and (supposedly) ;; up-to-date mirror. diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 3cd84ee3d7..2574e0f827 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -928,27 +928,40 @@ (define* (import-kernel.org-release package #:key (version #f)) #:directory directory #:file->signature file->signature))) -(define html-updatable-package? - ;; Return true if the given package may be handled by the generic HTML - ;; updater. - (let ((hosting-sites '("github.com" "github.io" "gitlab.com" - "notabug.org" "sr.ht" "gitlab.inria.fr" - "ftp.gnu.org" "download.savannah.gnu.org" - "pypi.org" "crates.io" "rubygems.org" - "bioconductor.org"))) - (define http-url? - (url-predicate (lambda (url) - (match (string->uri url) - (#f #f) - (uri - (let ((scheme (uri-scheme uri)) - (host (uri-host uri))) - (and (memq scheme '(http https)) - (not (member host hosting-sites))))))))) - - (lambda (package) - (or (assoc-ref (package-properties package) 'release-monitoring-url) - (http-url? package))))) +;;; These sites are disallowed for the generic HTML updater as there are +;;; better means to query them. +(define %disallowed-hosting-sites + '("github.com" "github.io" "gitlab.com" + "notabug.org" "sr.ht" "gitlab.inria.fr" + "ftp.gnu.org" "download.savannah.gnu.org" + "pypi.org" "crates.io" "rubygems.org" + "bioconductor.org")) + +(define (http-url? url) + "Return URL if URL has HTTP or HTTPS as its protocol. If URL uses the +special mirror:// protocol, substitute it with the first HTTP or HTTPS URL +prefix from its set." + (match (string->uri url) + (#f #f) + (uri + (let ((scheme (uri-scheme uri)) + (host (uri-host uri))) + (or (and (memq scheme '(http https)) + (not (member host %disallowed-hosting-sites)) + url) + (and (eq? scheme 'mirror) + (and=> (find http-url? + (assoc-ref %mirrors + (string->symbol host))) + (lambda (url) + (string-append (strip-trailing-slash url) + (uri-path uri)))))))))) + +(define (html-updatable-package? package) + "Return true if the given package may be handled by the generic HTML +updater." + (or (assoc-ref (package-properties package) 'release-monitoring-url) + ((url-predicate http-url?) package))) (define* (import-html-updatable-release package #:key (version #f)) "Return the latest release of PACKAGE. Do that by crawling the HTML page of @@ -956,6 +969,9 @@ (define* (import-html-updatable-release package #:key (version #f)) string to fetch a specific version." (let* ((uri (string->uri (match (origin-uri (package-source package)) + ((? (cut string-prefix? "mirror://" <>) url) + ;; Retrieve the authoritative HTTP URL from a mirror. + (http-url? url)) ((? string? url) url) ((url _ ...) url)))) (custom (assoc-ref (package-properties package) From patchwork Fri Aug 11 18:45:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Cournoyer X-Patchwork-Id: 52750 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 02BF527BBEA; Fri, 11 Aug 2023 19:50:41 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS 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 0C37727BBE2 for ; Fri, 11 Aug 2023 19:50:41 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUXDR-0003hj-TN; Fri, 11 Aug 2023 14:50:31 -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 1qUXD9-0003dK-FF for guix-patches@gnu.org; Fri, 11 Aug 2023 14:50:11 -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 1qUXD8-0000Ai-OD; Fri, 11 Aug 2023 14:50:11 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qUXD7-0007st-D9; Fri, 11 Aug 2023 14:50:09 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65230] [PATCH 13/13] gnu-maintenance: Consider Qt source tarballs as "release files". Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Fri, 11 Aug 2023 18:50:09 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65230 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65230@debbugs.gnu.org Cc: Maxim Cournoyer , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 65230-submit@debbugs.gnu.org id=B65230.169177980430191 (code B ref 65230); Fri, 11 Aug 2023 18:50:09 +0000 Received: (at 65230) by debbugs.gnu.org; 11 Aug 2023 18:50:04 +0000 Received: from localhost ([127.0.0.1]:48008 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXD1-0007qh-A2 for submit@debbugs.gnu.org; Fri, 11 Aug 2023 14:50:04 -0400 Received: from mail-qt1-x832.google.com ([2607:f8b0:4864:20::832]:53515) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qUXCu-0007p8-BI for 65230@debbugs.gnu.org; Fri, 11 Aug 2023 14:49:56 -0400 Received: by mail-qt1-x832.google.com with SMTP id d75a77b69052e-40fd6da0325so14734361cf.3 for <65230@debbugs.gnu.org>; Fri, 11 Aug 2023 11:49:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691779791; x=1692384591; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=QaohA+dy69QkEjcD4sjHe5rrSSfIqHDitiK9AuY5DhU=; b=NuHQkioXxn9lQwzrmTjVQ8mNmvCmJg9VQxNd1iD4pJD2CfFVRwU/I3pCMttBvHTarv XKmNNanFGXxUGI7bFLXELJngxEYziPefS25fvQRa6gU5pw308kSc5gzO++LqVfGJnC4D aRYugSxv1t3RCuKgrZzrSzMHd2IBo7iuoyo23brv03o+7YBUfGpmjeBdw0KfdXu+k40X 8tn+oJyBIuxhxNq51n6mG5UsoKsVH0zFeY8xy5N53aG47xgpXYfv8/eGsK43i/kSW0D1 Pv+iEE2CAGbwvF+LESVwguUZrlJ9c3rx2tHO38Aix9yE7WcFRd2S1b1RkL5tJdyCom+7 Udvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691779791; x=1692384591; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=QaohA+dy69QkEjcD4sjHe5rrSSfIqHDitiK9AuY5DhU=; b=Z5rhf+n2kaZ1a5TwjbFnU2GDzkp/qLvmWN/NBchFYKpKx4aA1lzfxdXKSaFmLkS3Wa PRFWXqKjDcrbZTk+Q6E/2Omf2dB3Urs30bLzzD865N2t2jp961RNjQflB0JHODEY6Lqd Td9K5VxtIOaO1KrKebyZ2Zj/UjZ57GS4+5IhI2Gw8Dww4MAvpggmiZBLxacC0p1Ojyf+ xvOUlG2B3Ek3Q/1hVril1ePby1j5k1YikU42DAcxw0wETxtN+sjJF7oGvClfG1in0EYz K9ZPAzXikA/pd5gAFQ8iqUJR79LcCKJHCfjz3XsZxVOw7bxcNgOLUgo7MA1/GbUgF0yi M4yg== X-Gm-Message-State: AOJu0YxxGk1hTJfzhqBSF7K14ESAIfkb9OFDkUYPAgWwNIvMmS0O3w8P ZHCc6Dkg3xmqGb910aXqVfpLhXhS39DIIQ== X-Google-Smtp-Source: AGHT+IGmAi45fqcOc+T+qUUknHsaVMxBqL/ueUQ4PMndaf6wt4zqBP7aXzwuGjAFRZL1xgmegjpJig== X-Received: by 2002:ac8:5744:0:b0:403:b103:248 with SMTP id 4-20020ac85744000000b00403b1030248mr3784644qtx.4.1691779790785; Fri, 11 Aug 2023 11:49:50 -0700 (PDT) Received: from localhost.localdomain (dsl-205-236-230-92.b2b2c.ca. [205.236.230.92]) by smtp.gmail.com with ESMTPSA id e29-20020ac8011d000000b00405553305casm1366398qtg.86.2023.08.11.11.49.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Aug 2023 11:49:50 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 11 Aug 2023 14:45:00 -0400 Message-ID: <1f62bdda36a196ae2c2be3b848f76cc00905e5a6.1691779500.git.maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> References: <4f0ffa940ca39719ffa9719a9593190620855769.1691779500.git.maxim.cournoyer@gmail.com> 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 * guix/gnu-maintenance.scm (release-file?): Use positive logic in doc. Add a special case for Qt source archives. * tests/gnu-maintenance.scm ("release-file?"): Update test. --- guix/gnu-maintenance.scm | 14 +++++++++----- tests/gnu-maintenance.scm | 4 +++- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 2574e0f827..1661ae3bf3 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -258,8 +258,7 @@ (define %alpha-tarball-rx (make-regexp "^.*-.*[0-9](-|~|\\.)?(alpha|beta|rc|RC|cvs|svn|git)-?[0-9\\.]*\\.tar\\.")) (define (release-file? project file) - "Return #f if FILE is not a release tarball of PROJECT, otherwise return -true." + "Return true if FILE is a release tarball of PROJECT." (and (not (member (file-extension file) '("sig" "sign" "asc" "md5sum" "sha1sum" "sha256sum"))) @@ -268,12 +267,17 @@ (define (release-file? project file) ;; Filter out unrelated files, like `guile-www-1.1.1'. ;; Case-insensitive for things like "TeXmacs" vs. "texmacs". ;; The "-src" suffix is for "freefont-src-20120503.tar.gz". + ;; The '-everywhere-src' suffix is for Qt modular components. (and=> (match:substring match 1) (lambda (name) (or (string-ci=? name project) - (string-ci=? name - (string-append project - "-src"))))))) + (string-ci=? name (string-append project "-src")) + (string-ci=? + name (string-append project "-everywhere-src")) + ;; For older Qt releases such as version 5. + (string-ci=? + name (string-append + project "-everywhere-opensource-src"))))))) (not (regexp-exec %alpha-tarball-rx file)) (let ((s (tarball-sans-extension file))) (regexp-exec %package-name-rx s)))) diff --git a/tests/gnu-maintenance.scm b/tests/gnu-maintenance.scm index 196a6f9092..5e9c006ee9 100644 --- a/tests/gnu-maintenance.scm +++ b/tests/gnu-maintenance.scm @@ -40,7 +40,9 @@ (define-module (test-gnu-maintenance) ("exiv2" "exiv2-0.27.3-Source.tar.gz") ("mpg321" "mpg321_0.3.2.orig.tar.gz") ("bvi" "bvi-1.4.1.src.tar.gz") - ("hostscope" "hostscope-V2.1.tgz"))) + ("hostscope" "hostscope-V2.1.tgz") + ("qtbase" "qtbase-everywhere-src-6.5.2.tar.xz") + ("qtbase" "qtbase-everywhere-opensource-src-5.15.10.tar.xz"))) (every (lambda (project+file) (not (apply release-file? project+file))) '(("guile" "guile-www-1.1.1.tar.gz")