From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id 6FXYNJC4L2enUwAAe85BDQ:P1 (envelope-from ) for ; Sat, 09 Nov 2024 19:31:29 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 6FXYNJC4L2enUwAAe85BDQ (envelope-from ) for ; Sat, 09 Nov 2024 20:31:28 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=rdklein.fr header.s=zoho header.b=Vq7n3DKy; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; arc=reject ("signature check failed: fail, {[1] = sig:zohomail.eu:reject}"); dmarc=none ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1731180688; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=gRMUPDUj8U6WuudYuXwSCNx7oErqjB4h0+KJgnzBPHk=; b=jjGn/stXgdyrYMMFDvkTvODEFxXEmRqak/xY5/zPpwi2b9PZOcHY4pklvPqotA9IJZdcu0 ujcNIGDe9xjhU/NWTGYoMGhO2kWLunDJqlnih3R3Qcj1fshbrYRuYYcqMvJWWlG5Wa5up7 bUWZik7m5EVDZHhqFLcx6t0O9BmHVocS8Z9GBKqeq6nXFe0ipzJjtYIljoyh7X8bVzMzyR 5oQSjm8JiBdRIlNZvt++ZEWoGRNi6MkqKNOuwqOcuC9BsrxQ3HB+BH/Iilzxr4ZWqBRdzm 5OofZycuewIbBfvRhQRzidg7qzKoljUulFMOUDNRj+rQDZhmWbLtTScEK1dg8w== ARC-Seal: i=2; s=key1; d=yhetil.org; t=1731180688; a=rsa-sha256; cv=fail; b=jwq4layUeSNMAjhsPRNrJep+c36JbFGQ1YcNeB4fNeV8fHYlqMbblB42buFY9wQhoAHatQ +L9qC79yYvk+tEybDmLI3orzrPcTidhNGpJlkBJCJX/evmQIEJhnQhOX+mr6XlHsCW8hEm iCALtNGX4ASBp/gXEGB9dd6G2y4NKXFQaZE4ZZ2hh9tpmsqfdeBTYYcrCnWyF7YSt8GkbZ kKDx1tmWM6P/R5AmUCv17PSestsyy2xBnTA6Q0DstHjxsQ4CyUMy4QFAJCg7DSxMx/xkj1 tn58K/sh0pOnJHMpqYWXYIigUId4Oz91d6cQc+U1/eY0Y6rUcqDHBnR1Pi2GiA== ARC-Authentication-Results: i=2; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=rdklein.fr header.s=zoho header.b=Vq7n3DKy; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; arc=reject ("signature check failed: fail, {[1] = sig:zohomail.eu:reject}"); dmarc=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 9E7F45B070 for ; Sat, 09 Nov 2024 20:31:28 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t9rAy-0006F5-KS; Sat, 09 Nov 2024 14:31:16 -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 1t9rAn-0006E3-Eu for help-guix@gnu.org; Sat, 09 Nov 2024 14:31:06 -0500 Received: from sender-op-o18.zoho.eu ([136.143.169.18]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t9rAl-0000sT-KU for help-guix@gnu.org; Sat, 09 Nov 2024 14:31:05 -0500 ARC-Seal: i=1; a=rsa-sha256; t=1731180661; cv=none; d=zohomail.eu; s=zohoarc; b=aVgTRI0CKz+mryJgwwEXazjtzny9Sthfg4CHQkRSoLbwQDDbU36SeuyopuYAtw2hO1oTUHFJE4Y4Kln6QwWuwHLbd55lptDPaCInvgF71NsedyHCRGaiiiloIRJzWNx2mOQ1efjt2zGUWp8KvJVbDdgN/NA0V3XOQF2hTHa4/hM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1731180661; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To:Cc; bh=Oc/0f5KwcAYfq3c7w6c+VtOp2YPJ9V+ksNfcqF2qLTc=; b=Yys8/l9g6dq366EPbJNy1Q6TKiBCdr8eyGD9H4POhdWMu4LjQpzdr3Zg+4OPw9Vs/LD0zP6gaYYPhL3PogUInkbX+VeX9Wyc6UP1cnEvBNj9nlGlx9tWnpsFa98oBMJWsVtse0EhcmZ7VCJmqCK4YS1OtF/QLVHeMe+Qgi7Y4C8= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=rdklein.fr; spf=pass smtp.mailfrom=edou@rdklein.fr; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1731180661; s=zoho; d=rdklein.fr; i=edou@rdklein.fr; h=Date:Date:From:From:To:To:Subject:Subject:In-Reply-To:References:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id:Reply-To:Cc; bh=Oc/0f5KwcAYfq3c7w6c+VtOp2YPJ9V+ksNfcqF2qLTc=; b=Vq7n3DKyMth8xchEzwYT8pi/PR+gVUrUuGH1Gz+HrVHS6wovgGY8JfkY0P1M8VyA pdpvBHYThRUyBLIjNUhaxYNIUOzHIJoWzS7Submaop/Zk/LXclHxJ3vAoKB6fKl5nHv FzEvlxthXz0O78fNwGVzfZAuzu4tg1e0y5bLPKON4RcwAr5ojTlw+WRVOaNMA9uHPIW ygG2/BN0b1LuX9Z20JLwYjmMDgdjIPQNkZh+y9sZbUy65gFwM5ncMxSOePej9Jn6TmE JN8nvN7FQui0EdSvlTd8jA8K4gcGBRrZpy4xAe0bGlolVU5E96V9fC+jX/rSZNLFGSR zhxyayAJnA== Received: by mx.zoho.eu with SMTPS id 1731180657514225.71805326156368; Sat, 9 Nov 2024 20:30:57 +0100 (CET) Date: Sat, 09 Nov 2024 20:30:59 +0100 From: Edouard Klein To: help-guix@gnu.org Subject: Re: Modular home configuration User-Agent: K-9 Mail for Android In-Reply-To: <87y11s1ekj.fsf@meson> References: <87y11s1ekj.fsf@meson> Message-ID: MIME-Version: 1.0 X-ZohoMailClient: External Received-SPF: pass client-ip=136.143.169.18; envelope-from=edou@rdklein.fr; helo=sender-op-o18.zoho.eu 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, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: 2.36 X-Spam-Score: 2.36 X-Migadu-Queue-Id: 9E7F45B070 X-Migadu-Scanner: mx13.migadu.com X-TUID: vun729yVGQ7l The magic is here Le 9 novembre 2024 18:35:10 GMT+01:00, Ian Eure a =C3= =A9crit=C2=A0: >Hi folks, > >I=E2=80=99m trying to make my home configuration more modular, so I can b= etter support system variances=2E For example, I have a laptop I use inter= actively, and a headless machine that runs Cuirass=2E It=E2=80=99s advanta= geous to share certain aspects of the home configuration between the two ma= chines (shell prompt/environment, GPG agent, etc), but not others (anything= X11/graphical stuff shouldn=E2=80=99t be on the build machine)=2E One app= roach to this is to define packages and services and reference them in the = home configuration=2E What I dislike about this is that many things requir= e both packages and services, and I=E2=80=99d prefer to have a way to compl= etely encapsulate that -- for example, the mpd-mpc package to control my mu= sic server, plus a home-environment-variables-service-type to set MPD_HOST= =2E > >I attempted to solve this by writing a procedure: > > (define (+mpd-client home-config) > (home-environment > (inherit home-config) > (packages (cons mpd-mpc (home-environment-packages home-con= fig))) > (services > (cons > (simple-service > 'mpd-environment-service > home-environment-variables-service-type > '(("MPD_HOST" =2E "audio=2Ebox"))) > (home-environment-services home-config))))) > >Which I can then wrap around a home-environment to add the mpd-mpc packag= e and environment variable it needs to work: > > (+mpc-client (home-environment =2E=2E=2E)) > >Surprisingly, this doesn=E2=80=99t work -- it complains that there=E2=80= =99s more than one "home" service type=2E I=E2=80=99m not sure why that is= , and I haven=E2=80=99t been able to see anything obviously wrong in the RE= PL -- though I haven=E2=80=99t been able to get my actual home configuratio= n up in the Emacs-Guix REPL, due to #67290=2E > >Does anyone have a suggestion for a workaround for this issue, explanatio= n of how two home services are ending up in the config, or a better approac= h for building modular home configs? > >Thanks, > > =E2=80=94 Ian >