From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) Subject: bug#25762: bug#25772: [PATCH] guix package: Remove trailing slash from profile path. Date: Thu, 20 Jul 2017 15:31:13 +0200 Message-ID: <87y3rjutem.fsf@gnu.org> References: <20170217100054.25464-1-rekado@elephly.net> <8737fctpc4.fsf@elephly.net> <87d1ee2y8p.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58844) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dYBYk-000813-Uj for bug-guix@gnu.org; Thu, 20 Jul 2017 09:32:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dYBYg-0001C5-R0 for bug-guix@gnu.org; Thu, 20 Jul 2017 09:32:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:46059) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dYBYg-0001By-OX for bug-guix@gnu.org; Thu, 20 Jul 2017 09:32:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dYBYg-0003dq-JA for bug-guix@gnu.org; Thu, 20 Jul 2017 09:32:02 -0400 Sender: "Debbugs-submit" Resent-To: bug-guix@gnu.org Resent-Message-ID: In-Reply-To: <87d1ee2y8p.fsf@gmail.com> (Alex Kost's message of "Sun, 19 Feb 2017 14:53:10 +0300") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Alex Kost Cc: 25772-done@debbugs.gnu.org, 25762-done@debbugs.gnu.org Hello! Alex Kost skribis: > Ricardo Wurmus (2017-02-17 23:38 +0100) wrote: > > [...] >>> (let* ((profiles (match (filter-map (match-lambda >>> - (('profile . p) p) >>> - (_ #f)) >>> + (('profile . p) >>> + (readlink (string-trim-right = p #\/))) >>> + (_ #f)) >>> opts) >>> (() (list %current-profile)) >>> (lst lst))) >> >> I don=E2=80=99t know if this is the right place for this change or if th= is >> should be further upstream. > > I think it is not the right place: you modify only 'process-query' > procedure, but there is also 'process-actions', so the following command > will still fail: > > guix package -p /tmp/test-profile/ -i hello > > while the following succeeds: > > guix package -p /tmp/test-profile -i hello > > So I would rather modify 'canonicalize-profile' procedure in that > module. I think it will be a general solution for --profile option. Indeed. I pushed something along these lines as edbe07cd67d6050d94fe8ac1af15ab15e857b61d, and a related fix as 561f4e450078a06c707d3dcda2cf0e7d6eb5ebae. Thanks! Ludo=E2=80=99.