From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id gJnCLRXXi2R/0QAASxT56A (envelope-from ) for ; Fri, 16 Jun 2023 05:29:25 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id gGCNLRXXi2QdiQAA9RJhRA (envelope-from ) for ; Fri, 16 Jun 2023 05:29:25 +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 9590443FCC for ; Fri, 16 Jun 2023 05:29:25 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qA093-0005Ma-6e; Thu, 15 Jun 2023 23:29:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qA090-0005MR-Ip for guix-patches@gnu.org; Thu, 15 Jun 2023 23:29:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qA090-0007EC-Ae for guix-patches@gnu.org; Thu, 15 Jun 2023 23:29:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qA090-0003QW-6G for guix-patches@gnu.org; Thu, 15 Jun 2023 23:29:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#61982] [PATCH 2/2] home: services: xdg-base-directories: Deprecate XDG_LOG_HOME. Resent-From: Andrew Tropin Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 16 Jun 2023 03:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61982 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Philip McGrath , Bruno Victal , 61982@debbugs.gnu.org, Ludovic =?UTF-8?Q?Court=C3=A8s?= Received: via spool by 61982-submit@debbugs.gnu.org id=B61982.168688612713152 (code B ref 61982); Fri, 16 Jun 2023 03:29:02 +0000 Received: (at 61982) by debbugs.gnu.org; 16 Jun 2023 03:28:47 +0000 Received: from localhost ([127.0.0.1]:48323 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qA08l-0003Q3-11 for submit@debbugs.gnu.org; Thu, 15 Jun 2023 23:28:47 -0400 Received: from relay6-d.mail.gandi.net ([217.70.183.198]:38435) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qA08i-0003Pp-P7 for 61982@debbugs.gnu.org; Thu, 15 Jun 2023 23:28:45 -0400 X-GND-Sasl: andrew@trop.in DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=trop.in; s=gm1; t=1686886119; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=jkBs9Ci0DgYMuQc/O4fQkXef8FhmJqkGr3o5gKfUUm8=; b=L/TOzWEa2ofeb36DlRc6vpJB/jdeD1E8fGX6w/EoTXOUHzP7XzWzdUHJhY0h/KO4Lny0i8 q9PPtu3JZvLMng8fVKF7gY3xp6dXupz9gWtSOY+uqS5FcJotb1U267GZ3uOxdzLp+8uznh JvOvUPtF1AjTr5EuYbVmmBK6PmcN57DhejKIKRQrC+HvonEeyBzmYc2fDkbRti6TuezzyF fuGn0j+62TBihFdJ6g8N5SI2oX5nD89Evrg+uJ5/i00MTMGHySfARwdswUmpPimVGZqq3u g5su0tEZIQGahKfLPOdEht104TooC/ydfwhFwSPyb4WaOi4ZN+INI64yFeJENg== X-GND-Sasl: andrew@trop.in X-GND-Sasl: andrew@trop.in X-GND-Sasl: andrew@trop.in Received: by mail.gandi.net (Postfix) with ESMTPSA id 3739DC0004; Fri, 16 Jun 2023 03:28:37 +0000 (UTC) From: Andrew Tropin In-Reply-To: References: <3005f8a58ec5afc447f2baf40958956bd0d16099.1678029530.git.mirai@makinata.eu> <0a0764da3fa04f9a02f37a7960a0c9608782854d.1678029530.git.mirai@makinata.eu> <87a5x1rrtv.fsf@trop.in> Date: Fri, 16 Jun 2023 07:28:32 +0400 Message-ID: <877cs4rspr.fsf@trop.in> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1686886165; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: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=jkBs9Ci0DgYMuQc/O4fQkXef8FhmJqkGr3o5gKfUUm8=; b=tdzv8n8jyr20TstuKXw81tBfet+oTgOxwneeg54u6SvjuAPgXC70vIPCFQuDVsLWiPM4oC ngYKqma18Ol5xe/NeRBdBLyDP8aowC0+FfqMQDCA/HgF2YgmZRmU/XRo+UfVZ0atP5lyxe 6uPvmY/w8DqbP7QsIkQxLhmGS+Kl/65eYlogswGe1hO4wjJZQMWGLrjzbwY7Qq1iKd+YSP nJXAkzalAg63SYHItegIDF3qGSOy6gVtk+hVwAQrH8h2624jhcI5lxHyDsAzAvbWhPuKXt Pr06knbiH13Dhy9Ki8kVR4/VHyMj2lZ/cUV61Hg8YASpRVnHJusQVruADhjlRA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=trop.in header.s=gm1 header.b="L/TOzWEa"; dmarc=none; 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1686886165; a=rsa-sha256; cv=none; b=Iqm7HCu+QIsgvkvCWdW8NB9d3FRmKrAQ8oM6nLD/cofIfaYnxBtonLolPQ4b8n5nSk68qj m3i/DA8pgGaDKVUduR/SXnacFhjxGhXjrHFdkrK68ExwNvPcYwznjaN50nrrTlL3URnXkS Zzx6YJKzjH1RoKyoBWhqyC2bNcSylunGcpCWgHYppCrPcRI2gJDLrnxf9X4D4AHGD2CxqB ri+k5RKnGXA+UfzvG8u2FPyvs3WI35nF/OcZXAe5eSw261OpV9ZR2TfVpbCGwypUW8gcZe j90RRuP4gUSfuB2lpzMCEV7z9naLu0JSfXyUVWuEn3K0GP08bgIG/3kOb5/oag== X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: -2.43 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=trop.in header.s=gm1 header.b="L/TOzWEa"; dmarc=none; 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: 9590443FCC X-Spam-Score: -2.43 X-TUID: 09mvXQEBuK8h --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On 2023-06-15 14:09, Philip McGrath wrote: > Hi, > > On Thu, Jun 15, 2023, at 5:35 AM, Andrew Tropin wrote: >> >> WDYT about adding (home-log-dir) function to (guix build utils)? >> So we can prevent copypasting the same code all over home modules. >> >> Something like: >> --8<---------------cut here---------------start------------->8--- >> (define (home-log-dir) >> "Returns a directory for user applications logs." >> (string-append >> (or (getenv "XDG_STATE_HOME") >> (format #f "~a/.local/state" >> (getenv "HOME"))) >> "/log")) >> --8<---------------cut here---------------end--------------->8--- >> > > I still think idiomatic XDG structure is NOT to have a "/log" > subdirectory like this, as I explained in > . With a brief look I didn't find information about this idiom in specification, but you can highlight it with quote or link. Anyway, I'm ok with storing logs in app subdirectory or "/log", not so ok with storing them in the root of state home. > > Aside from that, though, I thought the conclusion from > was that it is the > responsibility of Guix System or the installation mechanism for Guix > on a foreign distribution (e.g. "/etc/profile.d/zzz-guix.sh") to > initialize all of the XDG variables, so code like this can use > `(getenv "XDG_STATE_HOME")` unconditionally (or indeed with a checked > assertion). Maybe there's some context I'm forgetting, though. I've > been looking into these things again as I attempt to solve > : > I noticed in the attached environment variables that entries under > /home/philip/.guix-home/profile/ are duplicated in many search paths. home-state-dir function can also be useful, which can later become just (getenv ("XDG_STATE_HOME")). =2D-=20 Best regards, Andrew Tropin --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEKEGaxlA4dEDH6S/6IgjSCVjB3rAFAmSL1uAACgkQIgjSCVjB 3rBUwg//bJXnPFi5qqcYfmK3CicM/6SD3qLZKHzoLk3lTEjBX2sUJPNsBzfNI50r walBdw/DXdMtHv5S019GQKmFfmt8hs8H6v1qv9pV7spDAw8kxZzx1doG94wxKmuL ZStm2ehjQSnlk1aUoRy6/0TC1VvUtKok6gJMmPFfwPovIGU72L3B+XcG5kT3WYfm 9/2hmTdCycw66oCGbdr0Tb3yh6AqcVqFolchVRC3pBxyFyYjgFIHGTri+rTKQQRF LzDI5UpDrF4hqTiHVSc+GXIFd8DYwphSQSe8O8MHOQUA7mlKkVxyQ7PUyU3O5/VS XNNtfKGlMYietNx011iG0jwesJ0rFrwaWPSCOQjoV9747dveKYpuEJZHfFJQ0dk7 qIRXKZIPXRpXm/P8y897MxKNYagfpQf8aY2FSc9F5M6KhybHJEKT9+sxxkj08JIb 0UQ7kq1WP+D/CoI5XwuUq3WGHtLEZoF0PW8/2JTW/UMeSWRAJTLk8ZEZPFkczOnz 9c2lJhCNTY7OFkKAxxByMJcLGh1K1c267l1SMJbWVeRSR1LGZQfnG4lL3hS6KsX5 ni//1uGPDX4iYKKoocBrdEevjkZP3B/45sSM5b02qut+GufhemMSgu7JnSzP+hDA c/Ye6x5NEECt71O7dL936cVxzG6vgDhWaG2+CEIamH58U6mXs+I= =NXhi -----END PGP SIGNATURE----- --=-=-=--