From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 5001 invoked from network); 22 Jan 2021 10:28:50 -0000 Received: from alyss.skarnet.org (95.142.172.232) by inbox.vuxu.org with ESMTPUTF8; 22 Jan 2021 10:28:50 -0000 Received: (qmail 2247 invoked by uid 89); 22 Jan 2021 10:29:14 -0000 Mailing-List: contact supervision-help@list.skarnet.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Received: (qmail 2240 invoked from network); 22 Jan 2021 10:29:13 -0000 From: "Laurent Bercot" To: "Muhammad Mahendra Subrata" , supervision@list.skarnet.org Subject: Re: The multisubstitute commands in the run script generated by s6-usertree-maker are in a wrong order Date: Fri, 22 Jan 2021 10:28:47 +0000 Message-Id: In-Reply-To: <719f5399-2d05-d6d0-7377-e4014aab1ac1@gmail.com> References: <719f5399-2d05-d6d0-7377-e4014aab1ac1@gmail.com> Reply-To: "Laurent Bercot" User-Agent: eM_Client/8.1.979.0 Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeduledrudeigdduiecutefuodetggdotffvucfrrhhofhhilhgvmecupfgfoffgtffkveetuefngfdpqfgfvfenuceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkjghfrhgfgggtgfesthhqredttderjeenucfhrhhomhepfdfnrghurhgvnhhtuceuvghrtghothdfuceoshhkrgdqshhuphgvrhhvihhsihhonhesshhkrghrnhgvthdrohhrgheqnecuggftrfgrthhtvghrnhepvdfgveffueelgedvkedtffetgedvieeifeektefgueehffehleehjefhveeuieejnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmohguvgepshhmthhpohhuth >As shown above, the multisubstitute command that contains XDG_RUNTIME_DIR= is put after the one that contains USER, HOME, UID, GID, and GIDLIST. If fo= r example XDG_RUNTIME_DIR=3D/run/user/$UID, the $UID here will not be subst= ituted with the user's UID since by the time $UID is substituted, $XDG_RUNT= IME_DIR hasn't been substituted yet. So perhaps the order of these two mult= isubstitute should be inverted. You're right, of course. I remember testing it, and it *working*, so I did not think any further, but in retrospect it appears my test was incorrect. Thanks for the report! Fixed in git head. I'll give it the week-end, in case more bug-reports come in, then I'll release 2.10.0.1. Note that skalibs-2.10.0.1 is out already, it fixes a bug that manifests in execline's 'emptyenv -c' command. -- Laurent