From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id mPYECBAfal9CVwAA0tVLHw (envelope-from ) for ; Tue, 22 Sep 2020 15:58:08 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id iLTiAxAfal9JGQAA1q6Kng (envelope-from ) for ; Tue, 22 Sep 2020 15:58:08 +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 84D209404C6 for ; Tue, 22 Sep 2020 15:58:07 +0000 (UTC) Received: from localhost ([::1]:37932 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kKkg9-0006WR-PE for larch@yhetil.org; Tue, 22 Sep 2020 11:58:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41588) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kKkWQ-0007dA-9W for guix-patches@gnu.org; Tue, 22 Sep 2020 11:48:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:49691) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kKkWP-0001nh-VM for guix-patches@gnu.org; Tue, 22 Sep 2020 11:48:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kKkWP-00028z-TR for guix-patches@gnu.org; Tue, 22 Sep 2020 11:48:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41219] [PATCH 2/2] guix: Enforce package.json "files" directive. Resent-From: paul Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 22 Sep 2020 15:48:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41219 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: Jelle Licht , 41219@debbugs.gnu.org Received: via spool by 41219-submit@debbugs.gnu.org id=B41219.16007896497895 (code B ref 41219); Tue, 22 Sep 2020 15:48:01 +0000 Received: (at 41219) by debbugs.gnu.org; 22 Sep 2020 15:47:29 +0000 Received: from localhost ([127.0.0.1]:33004 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kKkVt-000235-0m for submit@debbugs.gnu.org; Tue, 22 Sep 2020 11:47:29 -0400 Received: from confino.investici.org ([212.103.72.250]:35763) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kKkVq-00020F-7I for 41219@debbugs.gnu.org; Tue, 22 Sep 2020 11:47:28 -0400 Received: from mx1.investici.org (unknown [127.0.0.1]) by confino.investici.org (Postfix) with ESMTP id 4Bwm0D2nVCz10ws; Tue, 22 Sep 2020 15:47:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=autistici.org; s=stigmate; t=1600789644; bh=D3u/G1NAaVnjO22hp1L6nUdaIkaV6L4DzQj/ZVKxorM=; h=Subject:From:To:References:Date:In-Reply-To:From; b=IpRtsFYkKUghxyu+Dt3iLH8F/SpGRODpxj0jVbYk0HW5ltCJ4o7Le080WpCcIHwal YtxXyC9zLHTwWz7yiZxw+cWjseBSt70ITd9mw3PXRfLh2fE35AttJcIEoBcox/gdeB NI4FwF/uIClRZoskuk+JsNIQhAi1h2eHJ1zWhSrE= Received: from [212.103.72.250] (mx1.investici.org [212.103.72.250]) (Authenticated sender: goodoldpaul@autistici.org) by localhost (Postfix) with ESMTPSA id 4Bwm0D26DFz10wR; Tue, 22 Sep 2020 15:47:24 +0000 (UTC) From: paul References: <20200512213131.28873-1-goodoldpaul@autistici.org> <20200512213131.28873-2-goodoldpaul@autistici.org> <875z88jkg9.fsf@jlicht.xyz> <7bea951c-c8c8-cca9-4bfe-8d8f5c83e2ab@autistici.org> Message-ID: <6730d1d5-38c7-22ee-ab4e-56430cd1b134@autistici.org> Date: Tue, 22 Sep 2020 17:47:23 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Icedove/68.12.0 MIME-Version: 1.0 In-Reply-To: <7bea951c-c8c8-cca9-4bfe-8d8f5c83e2ab@autistici.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) 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-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=autistici.org header.s=stigmate header.b=IpRtsFYk; dmarc=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-Spam-Score: -0.01 X-TUID: FFjbBivZ87no Hi Jelle, just a quick follow up that I forgot yesterday. >>> +                 (map (lambda (path) >>> +                        (string-drop path 2)) >>                             ^ >>                           If this is meant to drop the "./" prefix, you >>                           should be able to leave it out. >> This seems to be necessary because given the way glob-match? is implemented a string matches a pattern iif either they start with the same character or the pattern starts with a wildcard. So for example: scheme@(guix-user)> ,use (guix glob) scheme@(guix-user)> (string->compiled-sglob "*.json") $1 = (* ".json") scheme@(guix-user)> (string->compiled-sglob "package.json") $2 = "package.json" scheme@(guix-user)> (glob-match? $1 "./package.json") $3 = #t scheme@(guix-user)> (glob-match? $2 "./package.json") $4 = #f Thank you again for your help, Cheers Giacomo