From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id kMtmAaTka2LtIwAAbAwnHQ (envelope-from ) for ; Fri, 29 Apr 2022 15:14:12 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id sCmOAaTka2LBwAAAauVa8A (envelope-from ) for ; Fri, 29 Apr 2022 15:14:12 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 8C3D9B806 for ; Fri, 29 Apr 2022 15:14:11 +0200 (CEST) Received: from localhost ([::1]:39942 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nkQRm-0005y1-Bl for larch@yhetil.org; Fri, 29 Apr 2022 09:14:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42580) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkQRe-0005wQ-5V for guix-patches@gnu.org; Fri, 29 Apr 2022 09:14:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:57336) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nkQRd-0001nE-SL for guix-patches@gnu.org; Fri, 29 Apr 2022 09:14:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nkQRd-0000vw-Nw for guix-patches@gnu.org; Fri, 29 Apr 2022 09:14:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#54796] [PATCH v3 00/22] Add importer for hex.pm and rebar3 build-system for Erlang Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 29 Apr 2022 13:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54796 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Hartmut Goebel Cc: 54796@debbugs.gnu.org Received: via spool by 54796-submit@debbugs.gnu.org id=B54796.16512380033532 (code B ref 54796); Fri, 29 Apr 2022 13:14:01 +0000 Received: (at 54796) by debbugs.gnu.org; 29 Apr 2022 13:13:23 +0000 Received: from localhost ([127.0.0.1]:51233 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkQQu-0000ul-Lx for submit@debbugs.gnu.org; Fri, 29 Apr 2022 09:13:22 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49112) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkQQs-0000uZ-C5 for 54796@debbugs.gnu.org; Fri, 29 Apr 2022 09:13:15 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:48274) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkQQl-0001j7-F5; Fri, 29 Apr 2022 09:13:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=VDnvOagOJwTbQ+niuIJQJBEhtsRbIp84LvicmItmjTQ=; b=pRHB9l5gJ1GorAjtHcMj GfbRQN/O9rxdBIJsVjdt4MC3IntM7JQHsz4V/xmjRIPLtdFRDNqePr33twgg+3T5DSMkY7fRAaYk8 D6udXeU7Zqg1r7eZxESM1swP+1WpdWmYBDZVUuUsZUPmX45iXMUi2e1O7oJ8ZU3M8N/hYLv6U37u5 hq/4JMAI5hdwZlg46l5E8JfKVRHNRhp5pS7Xvl+rVMpYkOsVNnFZ03TtD21Rum0XB6tmuA9tQRDpq dpecasy7knGjalVg08vEpaBzkjeCzPMHXGOSSHxQdORveUbuxLjqonynEEQcGgXRC9d0gB7OykpsB +m0Jr5VLYNWhtw==; Received: from [193.50.110.83] (port=54064 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkQQk-0006LE-QS; Fri, 29 Apr 2022 09:13:07 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <1b7d1999ae7d090d17ad8953b835da9c5dc3cf54.1649616716.git.h.goebel@crazy-compilers.com> Date: Fri, 29 Apr 2022 15:13:04 +0200 In-Reply-To: <1b7d1999ae7d090d17ad8953b835da9c5dc3cf54.1649616716.git.h.goebel@crazy-compilers.com> (Hartmut Goebel's message of "Sun, 10 Apr 2022 20:56:59 +0200") Message-ID: <8735hw823j.fsf_-_@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1651238051; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=VDnvOagOJwTbQ+niuIJQJBEhtsRbIp84LvicmItmjTQ=; b=JgxZI/OQScaBfkvhGIoBY4YkbL5FhHPWJi/Z/kYWxdsNAsGbCtnMqVzmAOlUnCuYW42Txy fmvSY5tP2oEg/j0Z1jH40gamS9C5xrFsebn5EvgnV1dVFRGP/GwpbWAA+n7CSDk8kO6wfW In07ikHGvg9G8KVBmqcDVl2UTW3BO9BXPWbuKc6WU8i8ORkm3gCKuKV/ZFsUghlVNHMbNE scejdlA1i06pEipIDF3aYrv5tf/aF8d95+QUaG3LA233tqIRBxktYARl2bXbcxTMAaMdby odl6KvTmO5p0prf1JWyoYlo1bdxd1LzpvyfnpS2/bJfwZJBX7FaVvCXqhufl4A== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1651238051; a=rsa-sha256; cv=none; b=KoSC3IDUCAQ29W12BIm0Mh/Yg8whi483E94Z0+oicDD7MwLDmvDdUw2/GcFlfL80DiWDEW 2qGopdvVgST4bl1XSIlfVvpZnLl4WmTF8JTvcXBvGyAj7ZGIQt7KOTUKuWoQU5lhGVq/bd hxSXenfFA62migQZuLwWuC/r/l3E4gW+gltkVFfey7L7oE38XaZsxNeZpkWznEU+rVZV2Z UHujs5K+mhPomMUuYM2V9uNJutDWWPUEb31XqEYq8lB9ZPjFCdSpy+ddEh/Ue/izupbGtO tnCNcXEoqTBfGBrFdjumgN95cOMCCDIPcRm0iSsEHw31pem2M2aJcXF1/lrEDw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=pRHB9l5g; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.90 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=pRHB9l5g; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 8C3D9B806 X-Spam-Score: -3.90 X-Migadu-Scanner: scn1.migadu.com X-TUID: TMjz22oYNjlT Hartmut Goebel skribis: > hex.pm is a package repository for Erlang and Elixir. > > * guix/scripts/import.scm (importers): Add "hexpm". > * guix/scripts/import/hexpm.scm, guix/import/hexpm.scm, > guix/hexpm-download.scm: New files. > * guix/import/utils.scm (source-spec->object): Add "hexpm-fetch" to list = of > fetch methods. > * guix/upstream.scm (package-update/hexpm-fetch): New function. > (%method-updates) Add it. > * Makefile.am: Add them. Please mention tests/hexpm.scm. [...] > +(define-module (guix hexpm-download) > + #:use-module (srfi srfi-26) > + #:export (hexpm-package-url > + hexpm-uri)) How about moving these two procedures to (guix build-system rebar3)? This is what is done in similar cases, for example with =E2=80=98pypi-uri= =E2=80=99. > +++ b/guix/scripts/import/hexpm.scm > @@ -0,0 +1,109 @@ > +;;; GNU Guix --- Functional package management for GNU > +;;; Copyright =C2=A9 2014 David Thompson > +;;; Copyright =C2=A9 2016 David Craven > +;;; Copyright =C2=A9 2019 Martin Becze > +;;; Copyright =C2=A9 2020, 2022 Hartmut Goebel I think it=E2=80=99s fine to keep just your name here; it=E2=80=99s a short= file and one could argue that the bits found in all these files aren=E2=80=99t inventive= . :-) > + #:use-module (srfi srfi-11) > + #:use-module (srfi srfi-71) I think you can drop these two imports. > +++ b/guix/upstream.scm > @@ -464,6 +464,7 @@ SOURCE, an ." > #:key-download key-download))) > (values version tarball source)))))) >=20=20 > + Oops. :-) > +++ b/tests/hexpm.scm > @@ -0,0 +1,257 @@ > +;;; GNU Guix --- Functional package management for GNU > +;;; Copyright =C2=A9 2015 David Thompson > +;;; Copyright =C2=A9 2016 Ricardo Wurmus > +;;; Copyright =C2=A9 2018 Oleg Pykhalov > +;;; Copyright =C2=A9 2021 Sarah Morgensen > +;;; Copyright =C2=A9 2022 Hartmut Goebel Same comment here. > +(test-assert "hexpm->guix-package" > + ;; Replace network resources with sample data. > + (mock ((guix http-client) http-fetch > + (lambda (url . rest) I have a preference for spawning an HTTP server, if that=E2=80=99s possible= , as is done in tests/cpan.scm for instance. But it=E2=80=99s already been a long ride, so we can keep that for later. Otherwise LGTM. Great to see this new importer! Ludo=E2=80=99.