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 ms0.migadu.com with LMTPS id 8Gm1BJH++WFEfwEAgWs5BA (envelope-from ) for ; Wed, 02 Feb 2022 04:46:25 +0100 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 EDVLAZH++WFriQAAauVa8A (envelope-from ) for ; Wed, 02 Feb 2022 04:46:25 +0100 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 62E3A17692 for ; Wed, 2 Feb 2022 04:46:24 +0100 (CET) Received: from localhost ([::1]:59666 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nF6b9-0004Ar-Hd for larch@yhetil.org; Tue, 01 Feb 2022 22:46:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47306) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nF6Zq-00048o-3v for guix-patches@gnu.org; Tue, 01 Feb 2022 22:45:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:57210) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nF6Zp-0004xO-OS for guix-patches@gnu.org; Tue, 01 Feb 2022 22:45:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nF6Zp-0000IQ-Mc for guix-patches@gnu.org; Tue, 01 Feb 2022 22:45:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53676] [PATCH 4/5] services: pulseaudio: Add an extra-script-files configuration field. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 02 Feb 2022 03:45:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53676 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Liliana Marie Prikler Cc: 53676@debbugs.gnu.org Received: via spool by 53676-submit@debbugs.gnu.org id=B53676.16437734601054 (code B ref 53676); Wed, 02 Feb 2022 03:45:01 +0000 Received: (at 53676) by debbugs.gnu.org; 2 Feb 2022 03:44:20 +0000 Received: from localhost ([127.0.0.1]:51107 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nF6ZA-0000Gw-0H for submit@debbugs.gnu.org; Tue, 01 Feb 2022 22:44:20 -0500 Received: from mail-qt1-f179.google.com ([209.85.160.179]:33769) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nF6Z8-0000GW-Os for 53676@debbugs.gnu.org; Tue, 01 Feb 2022 22:44:19 -0500 Received: by mail-qt1-f179.google.com with SMTP id i4so16386936qtr.0 for <53676@debbugs.gnu.org>; Tue, 01 Feb 2022 19:44:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=f8QSU8giIps1u8DYdATkmd8QFzLmh9+/1m8W1xi778A=; b=jKs+Bk+vM188qW0+eCbEeiA6KoQ7jSVwWEHbA4dMlJtXKporIDvZL3pJmwGRRuIVKE A9lBnqhJLLCK0pz4/j4wzMSfECMI3NzmDOlCvD2d9k0bKuBi7p+WT4ZXwDisltL+MjWL J4mhsa4zi2XULoietJbxYgLGmk835ulYTqKDnOk4DCqGQvmyErYPm5IoXVn2a1MjERfK SUIGGgFOQC7RGNrV/HUhO5MCvEs41G96lewfbzmjyPa1x9ezPljXzw7vf5TYwJc0tcun viPwqSRnMNPxCPTDTNHD7hWQyUl+PeliCV5Zi/Wt6cM//lZwckVRnWjZwIR41VdmYX5C r4BQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=f8QSU8giIps1u8DYdATkmd8QFzLmh9+/1m8W1xi778A=; b=KKfLHZoEvX3gsjq1RCybrXTNf+kzJ0rfWO4w/rhIDr6v56XqmqVofShrzp+3ASVCtl qd4jmHIvQVDBglq6SNnsMidnTdLCbwQA7tf9lFKSWNsXn07MQ2017zDh22QCvIDTPI0c Rqs3PwQ9htZmaiLLjy9QeBnBJMj8MCGz375YZ2w8ndlXFlET6923uJYvPMLhIXn+TRlO mfffPN/lmlo6p36W4Rzh4gr4hUyureCxAbHUe7yCKcqhl+wsOeSVpYYQR9+ctqcw40WH wVhr5MYqom8zGKSwbfVrzZTeCoCgqJcnazgCnISDVLiAs/AgVlVnFrg+77dBlJyVnPFh QcNw== X-Gm-Message-State: AOAM532zS6+7d9olKNetw9mzgH7wwSGoZSWzEj73axjtgnwjqIbPLqXe aR96XrrYuIvRGV9/+WGdiUpri21B0BE= X-Google-Smtp-Source: ABdhPJyjkOQlpDeZdtCleJpmUFTzfNrMUeAoMJWkOFrbXhdczLghrNOiDoMYTfnH7SQ4RPjfb8V5fA== X-Received: by 2002:a05:622a:1cc7:: with SMTP id bc7mr21509597qtb.418.1643773452859; Tue, 01 Feb 2022 19:44:12 -0800 (PST) Received: from hurd (dsl-149-193.b2b2c.ca. [66.158.149.193]) by smtp.gmail.com with ESMTPSA id o13sm4537171qtx.22.2022.02.01.19.44.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Feb 2022 19:44:12 -0800 (PST) From: Maxim Cournoyer References: <20220201041933.16603-1-maxim.cournoyer@gmail.com> <20220201041933.16603-4-maxim.cournoyer@gmail.com> <97111754acacc576aec4eb55889a32474fe71f95.camel@gmail.com> <871r0m1gdy.fsf@gmail.com> <3c9845d7b893dddcd44be41d2ee475c29d9f5a85.camel@gmail.com> Date: Tue, 01 Feb 2022 22:44:11 -0500 In-Reply-To: <3c9845d7b893dddcd44be41d2ee475c29d9f5a85.camel@gmail.com> (Liliana Marie Prikler's message of "Tue, 01 Feb 2022 22:26:54 +0100") Message-ID: <87o83qyltg.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (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-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1643773584; 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=f8QSU8giIps1u8DYdATkmd8QFzLmh9+/1m8W1xi778A=; b=Aylt4HYTu6MpXSM+5MEXdIknjlUFMh3atpByD1dyz4QIseGG9/p5BnpHymU6MWtWJh4IM/ wxaf1iKAYihRbeVuas7yUqnCzhPte8zLPAn4Exm8fYy8kxbDhQNz5c0m+7srncJbkdN22y 2E5CSKXktkkHPKHyU1HpHTlh//C/FVMU9iuWmXWjHb+6RPzS0AX1nhMUcxHB+lxq3KffAs ZxxQZ6TtfXcB33JKFH60OEg8V7XXumGmNxwcBf9P/lSVkgkWx9dxZkfemthKTiYrDtnv2u QdBdA9jtMeAYG1koS20bolpB7EozpDErOHDrneGz5mRNaPzooZxXvbErqjjfww== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1643773584; a=rsa-sha256; cv=none; b=h/c7R29QVuRgNZlDBXWnsM0GzXvc7FzXiDjjjTgyMUgqn0t/nMZiFOeLgE61p7NKMZp7AG g6TzPAYzf8Qbpp3I4C7WRRsRL2Q655eL46PgzhRBGLzPGEcSmDUI0nl5FqEmHhXRfzTzSS 35TUOmfFb+VKmxTddN7Y5rAH/6Pzgqzq8mTSpgPfKtb3PAKho6kWYDgw0ZPnf7O5c1Sn2o 5cH6VBbtd9cDSw58S6Mi1tcSAM0nK22o2ZBxAkiPhA5+vKfiTUm6bkre1MU0G6TJI9q5OC 3BQ1J5WdslGjb9zVJNzpjlscnCDh+SQQmbshQ794EdTOurcaICOphyC1hiZ4FQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=jKs+Bk+v; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=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-Spam-Score: -2.53 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=jKs+Bk+v; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=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: 62E3A17692 X-Spam-Score: -2.53 X-Migadu-Scanner: scn0.migadu.com X-TUID: MpNs36gGH3tE Hello, Liliana Marie Prikler writes: > Hi, > > Am Dienstag, dem 01.02.2022 um 15:27 -0500 schrieb Maxim Cournoyer: >> [...] >> > Is there a particular use-case for this (other than working around >> > the location issue of default.pa et al.)?=C2=A0 If not, I'd rather make >> > it s.t. our other files can more easily be stitched together in- >> > place. >>=20 >> You mean, a use case for extra-script-files?=C2=A0=C2=A0 > Yes. > >> Sorry, I missed something in the "make it s.t. our other [...]"; what >> does "s.t." stands for? > "such that" or "so that". Pretty common among mathematicians, I think > =F0=9F=99=83 Ah! >> My use case is the one I documented in the manual; setting a default >> card profile for example.=C2=A0 Also choosing the default sink and source >> of a card; this can be done in client.conf but that doesn't get >> reflected anywhere on the state of a running pulseaudio server it >> seems, contrary to calling 'set-default-sink ...', which takes effect >> server-side. > And you can't do this inside default.pa, because ... ? I could; but what I want is to *extend*, rather than *replace* the default.pa script; the native PulseAudio mechanism to do so is to put files under '/etc/default.pa.d'. We could simply tell people to use extra-special-file service to achieve that, but that's less discoverable than having a convenient, documented field to do so :-). >> > Also, assuming that we're using file-like objects here, I think we >> > should use the store name minus prefix and hash for the file name.=20 >> > E.g. if Alice adds soundblaster.pa, it'd make sense to label it >> > soundblaster.pa, so that changes to snippet order don't mess up any >> > configuration referring to those files. >>=20 >> I actually wanted to do that but decided against since there's no >> clean API to retrieve the name of a G-Exp file-like object (it could >> be done, currently, but it'd be messy and fragile, it seems). >>=20 >> But good observation, I wanted to document that the extra script >> files are loaded in the order they are listed. > Isn't that what "strip-store-file-name" from (guix build utils) does? > (Let's ignore hard-coded hash length...) 'strip-store-file-name' would be able to get the name from the store item (built derivation), but file-union takes a "two-element list where the first element is the file name to use in the new directory, and the second element is a gexp denoting the target file", e.g., before the file-like object is built. I don't see an easy way to make it work. Thanks, Maxim