From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 8N8RI8GpYWAyLgAAgWs5BA (envelope-from ) for ; Mon, 29 Mar 2021 12:19:45 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id oDHzHMGpYWC8NwAAbx9fmQ (envelope-from ) for ; Mon, 29 Mar 2021 10:19:45 +0000 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 1A456294CB for ; Mon, 29 Mar 2021 12:19:45 +0200 (CEST) Received: from localhost ([::1]:60552 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lQozo-0007JS-9A for larch@yhetil.org; Mon, 29 Mar 2021 06:19:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34288) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lQozK-0006oy-Dp for guix-patches@gnu.org; Mon, 29 Mar 2021 06:19:14 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:36374) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lQozA-0003mE-46 for guix-patches@gnu.org; Mon, 29 Mar 2021 06:19:07 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lQozA-0008Lc-0F for guix-patches@gnu.org; Mon, 29 Mar 2021 06:19:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#47464] [PATCH 2/8] scripts: discover: Replace 'args-fold*' by 'parse-command-line'. Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 29 Mar 2021 10:19:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47464 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 47464@debbugs.gnu.org Cc: zimoun Received: via spool by 47464-submit@debbugs.gnu.org id=B47464.161701311131993 (code B ref 47464); Mon, 29 Mar 2021 10:19:03 +0000 Received: (at 47464) by debbugs.gnu.org; 29 Mar 2021 10:18:31 +0000 Received: from localhost ([127.0.0.1]:47909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lQoyc-0008Jq-Vu for submit@debbugs.gnu.org; Mon, 29 Mar 2021 06:18:31 -0400 Received: from mail-wr1-f43.google.com ([209.85.221.43]:34594) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lQoyR-0008IY-Uk for 47464@debbugs.gnu.org; Mon, 29 Mar 2021 06:18:21 -0400 Received: by mail-wr1-f43.google.com with SMTP id j7so12289557wrd.1 for <47464@debbugs.gnu.org>; Mon, 29 Mar 2021 03:18:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=4pnSw7IctYJsCOiJHUlF31q5Gdz6Z6kBPHoEZjIkNoU=; b=DjPKNWrEZpHrm1OSSE4IZtjsAZQsYcDLquA0DbRdz4/h+1Be6bRmVjns8r7zU2Xt7T M34o5Bw14VIcTXZ/BNB07D5qdEKfm8T+J6LosZ90gNzr215elCfkEaDwCOoiEj8WtAgD e3rV/iCOId0GHN+fA2L51RqUPbUEx1F/9FMHpvH7nI+Bgx682v9OMrgRk11NHe+WU7kO 3ZktEfhNLzDqsqIWfNpHfsUQ0azMGYjdYtmS7ix/5SaRUl2WDaGuTijd6NI4kdZIuAuZ oGn4cR4LoBj/G60C1MXule3r7tCqnCtjZxD9ugdH03lr01rszSE8hj3r6K2oKrWyM4vP Xx9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=4pnSw7IctYJsCOiJHUlF31q5Gdz6Z6kBPHoEZjIkNoU=; b=P+BvZNpYSrSIL1YnQoA+yQ3qvuAjWygJBOPVvuxpyvfpNtccU6Lfv+N9/2hK4W+Wxo V6IzHA3fZiFx39Qb28ulo57uGouTaGD2LaxkGJbwlKRdq58P1UOGWBJaMrSPI20umbFw O8hai+O93zci2v1tRnKic6eE9pBrIAGQFAC8mafy16YI5+7nsPT0JXCc2APQLEVUO72Z /9YSFUUPpu9n7/Dzx3p/ooJcnZMIpAbsqOU8rtv+H8rsN+cf3HBbqQcZtKczW0C9lSTj WR32SYBBE97foRjjAN2C1/UH0xP/JOeDDTZZVk6Vf7i4EcZlax5ihPnCL4v2itJTLEjM KHRA== X-Gm-Message-State: AOAM532GRSMsmq5usDwB+J3t/Vf3+2j0A/6xIHMpD+lxEm4q61scUb+r t8ASw+y5wM+7Zbr3wCKeer9fJEHsi1c= X-Google-Smtp-Source: ABdhPJzkydzSXi7W6cfOnURaqhRkyfGFQ3NY7JA30DBZgB6KFWtZ5N8sx338XtU//bDiqyMjhSybnw== X-Received: by 2002:adf:d1cd:: with SMTP id b13mr27549966wrd.47.1617013094396; Mon, 29 Mar 2021 03:18:14 -0700 (PDT) Received: from localhost.localdomain ([193.48.40.110]) by smtp.gmail.com with ESMTPSA id 135sm25291792wma.44.2021.03.29.03.18.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Mar 2021 03:18:14 -0700 (PDT) From: zimoun Date: Mon, 29 Mar 2021 12:18:00 +0200 Message-Id: <20210329101806.54004-2-zimon.toutoune@gmail.com> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210329101806.54004-1-zimon.toutoune@gmail.com> References: <20210329101806.54004-1-zimon.toutoune@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1617013185; 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=4pnSw7IctYJsCOiJHUlF31q5Gdz6Z6kBPHoEZjIkNoU=; b=D3XhkypfJxUPyWwA6woBjxInu8z6iliTiteURw3oyUJE3IamqIUdTfqEp7my/eoYa/WBMZ g2RiTJankgWxf3VG736KKeXM6i4yw7sbYk3ks4fRaGO4TilT68Ol5+3y+W+qN6F7vpx+GE 2fddEdeXr1DTLwxc+s1mzNu4bqs4fcMwyM29Qodo1JFfR9Esd8MpfQtGMonunLYugJwgWQ aN3jsiEJG/gJ6BqpxRrvCKHqkmwuzl+zifUPQnQb9jNujf5DqWyStuQ4AraUQjpYUc+ufL l0oKMUVP9ppEnzizTTSIsgIay8exJ9FBYD+IeKLC53r2jxOpOOpOLyBPScH+bw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1617013185; a=rsa-sha256; cv=none; b=t/E+jCXAs+eCw0EBUz3TFMYvl8dIdNtfoak9d9kr2tIc2MQL5McT3Z6yCd185661bed/+E rxkcvSdkpZiUayjve4SW8fJbpEXB86i+/4QCuDJjW3fyGy82PI1cYcrJd9qHTyd+dS5/zC mjocXY6iIl0YEm11Fd2xyEisuIMrsiTsr/wz4h1SZmMfesFtUyC70xrA/Lh/KEnhVkazJI 3ag+jg3+1AINeurP8jpdoF9D45AhwRebyf3Ly+s8KK4X2nsxt9W3RiekdO1bGuDg5wv6hH jLwrLcnYRfALvAT0l7UMITHLvaMXFhz1ojux8hrvdWKVvSl0ZWxKzR4f8j73UA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=DjPKNWrE; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.32 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=DjPKNWrE; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 1A456294CB X-Spam-Score: -1.32 X-Migadu-Scanner: scn0.migadu.com X-TUID: 8Y501DzQdFCT * guix/scripts/discover.scm (define-command): Replace 'args-fold*' by 'parse-command-line'. --- guix/scripts/discover.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/guix/scripts/discover.scm b/guix/scripts/discover.scm index 6aade81ed1..be1eaa6e95 100644 --- a/guix/scripts/discover.scm +++ b/guix/scripts/discover.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2020 Mathieu Othacehe +;;; Copyright © 2021 Simon Tournier ;;; ;;; This file is part of GNU Guix. ;;; @@ -127,12 +128,11 @@ to synchronize with the writer." (synopsis "discover Guix related services using Avahi") (with-error-handling - (let* ((opts (args-fold* args %options - (lambda (opt name arg result) - (leave (G_ "~A: unrecognized option~%") name)) - (lambda (arg result) - (leave (G_ "~A: extraneous argument~%") arg)) - %default-options)) + (let* ((opts (parse-command-line args %options (list %default-options) + #:build-options? #f + #:argument-handler + (lambda (arg result) + (leave (G_ "~A: extraneous argument~%") arg)))) (cache (assoc-ref opts 'cache)) (publish-file (publish-file cache))) (parameterize ((%publish-file publish-file)) -- 2.30.1