From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id cGcyLfBidWXp/gAA9RJhRA:P1 (envelope-from ) for ; Sun, 10 Dec 2023 08:04:16 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id cGcyLfBidWXp/gAA9RJhRA (envelope-from ) for ; Sun, 10 Dec 2023 08:04:16 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=163.com header.s=s110527 header.b=haHtsrr2; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=163.com (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1702191856; 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:list-id:list-help:list-unsubscribe:list-subscribe: list-post:dkim-signature; bh=nBWyjAJ+NZ32rOVBgwuAw6dpPL9IhxxKXZLMGnu3IDA=; b=Ps3uyBxOMJrXI3WYW1uOVDT4t6v6Py49eaTv00hzzV3lsTe2ign1HKh2r8GGXWfT2w8B0z pdosbCAUPhn20gjhfMPx0KgudBci7xE0maz2vgmLVLG2nx5bQS81KaySvwISPjRkqY35T2 O5fVZDo8MGuJjHcF8gGvwdQuXdHI9hwsA3Axn96HSFTRcuZkctPVESPlnOCTssHrfvJDLr JsqQzO87P/Td5lKDNoEEkgnFPjryb6gwHlo2xvQ/+aD+/Jj9dk5+MOeJtXsdp/VzVOR3DM xm2jtx++x/c8MsvaBEIMTFkiLnrNRdyJx72BDDiGYwck+GCbQ3rkIokbz0rfrw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1702191856; a=rsa-sha256; cv=none; b=CVTG/1uXsmFPmgntDdK/e9INfwRgEIGfIFSBtSvhjh/idDhiUL2XNLdtvfoUAPvUUWmUNz fBtrRjQrpvtl3/P01RWgkrPNK0qzT6cITGCLx5E+Tpt4lDLVs2LqOShay9yrxz5rojNesT ZOuofdwDzduFSOwAeuTIBI+BTXWgwJ7WsFZo0wK8JTc6FL+NDhwGdU8EZKwN9xh6NgPIVK 1q4sO/AOTnc/OgOwer/qCmeDcsfyy+cw/tD0eunyhlaGw/5fEgoeSpi3BxCQ+9Pm7+2Y9M YRbOEnaniQbgPrVrn9wtSBlr/0K23RmyXqviRVuOFU4NkYgN/jxvyFh4MasbSQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=163.com header.s=s110527 header.b=haHtsrr2; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=163.com (policy=none) 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 8146713352 for ; Sun, 10 Dec 2023 08:04:15 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rCDSm-0000rZ-1K; Sun, 10 Dec 2023 01:38:52 -0500 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 1rCDSk-0000rR-FH for bug-guix@gnu.org; Sun, 10 Dec 2023 01:38:50 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rCDSi-0008Em-L1 for bug-guix@gnu.org; Sun, 10 Dec 2023 01:38:50 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rCDSw-00082i-BN for bug-guix@gnu.org; Sun, 10 Dec 2023 01:39:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#67738: xinitrc function in services/xorg.scm do not handle guix-home's direcory. Resent-From: Feng Shu Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 10 Dec 2023 06:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 67738 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 67738@debbugs.gnu.org X-Debbugs-Original-To: "guix-bug" Received: via spool by submit@debbugs.gnu.org id=B.170219028530834 (code B ref -1); Sun, 10 Dec 2023 06:39:02 +0000 Received: (at submit) by debbugs.gnu.org; 10 Dec 2023 06:38:05 +0000 Received: from localhost ([127.0.0.1]:49375 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rCDS1-00081F-4u for submit@debbugs.gnu.org; Sun, 10 Dec 2023 01:38:05 -0500 Received: from lists.gnu.org ([2001:470:142::17]:57180) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rCDRv-00080i-GW for submit@debbugs.gnu.org; Sun, 10 Dec 2023 01:38:03 -0500 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 1rCDRc-0000hZ-1N for bug-guix@gnu.org; Sun, 10 Dec 2023 01:37:40 -0500 Received: from m12.mail.163.com ([220.181.12.197]) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rCDRX-0007qU-PN for bug-guix@gnu.org; Sun, 10 Dec 2023 01:37:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-ID:MIME-Version: Content-Type; bh=nBWyjAJ+NZ32rOVBgwuAw6dpPL9IhxxKXZLMGnu3IDA=; b=haHtsrr2hCZ97dRVdVMMZGlFRvWe4gci/4tJwPUF41CF6mFmVKcNcIfhnvDHy0 QibqVB49nVrKH2XWOTmMKbJMPYxPMt/vlREP4UNcDRmHB2D9nChwb/qE79KMebNL S70YSlDcCv4fcglCkBEXTrNCxGKQRiy+HI6gKNHoK0TXg= Received: from Guix (unknown [117.92.146.182]) by zwqz-smtp-mta-g4-0 (Coremail) with SMTP id _____wD3f22jXHVlLCbvFA--.2519S2; Sun, 10 Dec 2023 14:37:23 +0800 (CST) From: Feng Shu Date: Sun, 10 Dec 2023 14:37:22 +0800 Message-ID: <87bkaysgv1.fsf@163.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-CM-TRANSID: _____wD3f22jXHVlLCbvFA--.2519S2 X-Coremail-Antispam: 1Uf129KBjvJXoW7Cry5GF4xCFyUXr48Jw1kKrg_yoW8JFy3pF y5uryDGr1DAFyDGw1kJFyjgrW7tFWrtrW8XrWkurykAws8Cr18KFy7C3yfJa4DWa1kCwsx ua12v3s5Wr4Dt3DanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07jbjjgUUUUU= X-Originating-IP: [117.92.146.182] X-CM-SenderInfo: 5wxpt2lkx6il2tof0z/xtbBFwVC1Fgi7cQd4AAAsq Received-SPF: pass client-ip=220.181.12.197; envelope-from=tumashu@163.com; helo=m12.mail.163.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_BL=0.001, RCVD_IN_MSPIKE_L4=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: 0.19 X-Spam-Score: 0.19 X-Migadu-Queue-Id: 8146713352 X-Migadu-Scanner: mx11.migadu.com X-TUID: w+55Zg+Ehx18 (define* (xinitrc #:key fallback-session) "Return a system-wide xinitrc script that starts the specified X session, which should be passed to this script as the first argument. If not, the @var{fallback-session} will be used or, if @var{fallback-session} is false, a desktop session from the system or user profile will be used." (define builder #~(begin (use-modules (ice-9 match) (ice-9 regex) (ice-9 ftw) (ice-9 rdelim) (srfi srfi-1) (srfi srfi-26)) ... (define system-profile "/run/current-system/profile") (define user-profile (and=> (getpw (getuid)) (lambda (pw) (string-append (passwd:dir pw) "/.guix-profile")))) I think we should handle '.guix-home' direcory, just like .guix-profile. ... (let* ((home (getenv "HOME")) (xsession-file (string-append home "/.xsession")) (session (match (command-line) ((_) #$(if fallback-session #~(list #$fallback-session) #f)) ((_ x ..1) x)))) (if (file-exists? xsession-file) ;; Run ~/.xsession when it exists. (apply exec-from-login-shell xsession-file (or session '())) ;; Otherwise, start the specified session or a fallback. (apply exec-from-login-shell (or session (find-session user-profile) (find-session system-profile))))))) (program-file "xinitrc" builder)) --