From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 2DDHGzivwmJgIQAAbAwnHQ (envelope-from ) for ; Mon, 04 Jul 2022 11:13:28 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id YDFiGzivwmINrgAAauVa8A (envelope-from ) for ; Mon, 04 Jul 2022 11:13:28 +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 006293A24C for ; Mon, 4 Jul 2022 11:13:28 +0200 (CEST) Received: from localhost ([::1]:38318 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o8I90-0004Ck-HK for larch@yhetil.org; Mon, 04 Jul 2022 05:13:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38750) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o8I8c-0004Bx-Ew for guix-patches@gnu.org; Mon, 04 Jul 2022 05:13:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:52168) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o8I8c-0001vz-6B for guix-patches@gnu.org; Mon, 04 Jul 2022 05:13:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1o8I8c-0004c6-18 for guix-patches@gnu.org; Mon, 04 Jul 2022 05:13:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56050] [PATCH v2 1/2] etc/guix-install.sh: Initialize XDG base directories. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 04 Jul 2022 09:13:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56050 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Philip McGrath Cc: 56050@debbugs.gnu.org Received: via spool by 56050-submit@debbugs.gnu.org id=B56050.165692592317663 (code B ref 56050); Mon, 04 Jul 2022 09:13:01 +0000 Received: (at 56050) by debbugs.gnu.org; 4 Jul 2022 09:12:03 +0000 Received: from localhost ([127.0.0.1]:46065 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o8I7f-0004ap-A6 for submit@debbugs.gnu.org; Mon, 04 Jul 2022 05:12:03 -0400 Received: from eggs.gnu.org ([209.51.188.92]:53614) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o8I7d-0004aJ-K5 for 56050@debbugs.gnu.org; Mon, 04 Jul 2022 05:12:02 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:49804) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o8I7Y-0001my-5o; Mon, 04 Jul 2022 05:11:56 -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=a8ldjhLNMmzS2DShFeVBiWs4GkIweou1XQBn2k5bQMY=; b=AcRTdErUG4IeQYN8dwhb aTr8eSJBFlt01vBqXxjZ/CrpBL4QAon9NMXxsdV5qF1ByHsuOcT0RpFTrTUYGc31lNfK4Zsh1bS+k N6OSmXZm18MvGBUfKaTem46R8X7AthgtUI1Xlzsbeo4gjS18Fa66XofPBzsAZYIfebYBVKzZYfz72 BSNyv9ezAf6S0OPVE0Ouhxn/PdroRpg3T1eEK5O3LGIeZjvHFQaiGsfgPs2xoCvRwnD00Q475Adr/ rlxhM/64Kq0XJN4/G478VfpChRcaO/A/9bhArNpM19NdlS3SYH+qOLMmUUU1TIfUgRL8W7rGhkpKJ ci/wrVIbtJdw0w==; Received: from [193.50.110.235] (port=52740 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o8I7X-00026x-Pt; Mon, 04 Jul 2022 05:11:56 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <605a74b1f064e2b057f6c9d57692dda5bccf8edf.1656899134.git.philip@philipmcgrath.com> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Sextidi 16 Messidor an 230 de la =?UTF-8?Q?R=C3=A9volution, ?= jour du Tabac X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Mon, 04 Jul 2022 11:11:53 +0200 In-Reply-To: <605a74b1f064e2b057f6c9d57692dda5bccf8edf.1656899134.git.philip@philipmcgrath.com> (Philip McGrath's message of "Sun, 3 Jul 2022 22:35:02 -0400") Message-ID: <877d4tgs2u.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (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=1656926008; 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=a8ldjhLNMmzS2DShFeVBiWs4GkIweou1XQBn2k5bQMY=; b=nOzlTMqKnM4EHi4zFQ86TpySOK0GEnJ92CIRHTW4Arq0atpMRyOsc78BW7OGoWDoizG4W8 ttKF2zlnHSqRTJ4Ntt9JPbybFCrdqN78PgZyrT1GRMb1uwjGAZ8zWYtCNmNoJyeEwN/uXT tw1yBHHgsxDOiNoAEATre5y4zXkaDz3XmBaQ5j0535m1pCNj1wDqvAhlmhk2kQgEy+vG3t dev5HPlBKRsZu09dcUJV3z2BvwHPeLDyZZVQ2Mk33gTivv5yL84aE04f+OTe/mTlrRLRlX pMDCkdv8gGXjOlYINgjnWwZO/He/x24vrVmEkG1zfH1hjRKa9jB4cVx+W2ZPlA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1656926008; a=rsa-sha256; cv=none; b=sCeZS5C47JK5f6xswm5hdpCCDlBsGUJXEs5Pnrb5Z0n1LbPwAacniTlu4UMibeRc8Nu+QY cmr00tQeBPQ9cCiB2kM8R69Gc5lr4JdGZBfPMHq5Q1smkdyKBp5jqln3Fx6xHIujbCgT0T WH77Lluit+QL/61bB0eXfsl40Up/DMjswBY8XGZ+HGDCxLhf/XhNPFot9G21nsGLB25mAW aYIgoSQhhcqq7Vrv0pLByw9eeM2NgTp/H6nnkwg1fd8cuddpQtJ3nFsTK2zeIog6nvX/Gf 64A+t4/1YHhotOhgivyjLjn5R70fJWKSETI1cqoCHqbNqGx0Xfpl1CAeX7XiMQ== 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=AcRTdErU; 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: -2.34 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=AcRTdErU; 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: 006293A24C X-Spam-Score: -2.34 X-Migadu-Scanner: scn1.migadu.com X-TUID: BwAjRNlN2rWn Hi! Philip McGrath skribis: > The default values from the XDG base directory specification make little > sense for Guix System, and some scripts in Guix assume that they are not > "empty or unset": for example, see . > On foreign distros, however, omitting the default values is likely to > break software from the distro, perhaps even preventing the desktop > environment from starting. To smooth over the difference, use the > system-wide configuration to ensure the environment variables are always > explicitly set on foreign distros. > > * etc/guix-install.sh (sys_create_init_profile): Explicitly initialize > XDG base directory variables. [...] > +# Explicitly initialize XDG base directory variables to ease compatibili= ty > +# with Guix System: see . > +export XDG_DATA_HOME=3D"${XDG_DATA_HOME:-$HOME/.local/share}" > +export XDG_CONFIG_HOME=3D"${XDG_CONFIG_HOME:-$HOME/.config}" I think variable expansion happens at the wrong time: --8<---------------cut here---------------start------------->8--- $ cat > /tmp/t < export PATH=3D"$PATH:foobar" > EOF $ cat /tmp/t export PATH=3D"/gnu/store/lq7ysaq5qbxh9xavx1zffgwrg4r8yhsy-profile/bin:/gnu= /store/lq7ysaq5qbxh9xavx1zffgwrg4r8yhsy-profile/sbin:/home/ludo/.guix-home/= profile/bin:/home/ludo/.guix-home/profile/sbin:/home/ludo/.guix-home/profil= e/bin:/home/ludo/.guix-home/profile/sbin:/run/setuid-programs:/home/ludo/.c= onfig/guix/current/bin:/home/ludo/.guix-profile/bin:/home/ludo/.guix-profil= e/sbin:/run/current-system/profile/bin:/run/current-system/profile/sbin:/gn= u/store/0c1yfbxyv877mlgychfgvmk5ha2jqh52-gzip-1.10/bin:/gnu/store/8fpk2cja3= f07xls48jfnpgrzrljpqivr-coreutils-8.32/bin:foobar" --8<---------------cut here---------------end--------------->8--- (The problem already exists, and should be fixed, but it=E2=80=99s about variables that are less likely to be used.) Could you address that by escaping dollars? Otherwise LGTM. Thanks, Ludo=E2=80=99.