Re: [wmii] Two wmii.rc issues

From: Armando Di Cianno <armando_AT_goodship.net>
Date: Fri, 5 Sep 2008 12:25:03 -0400

FWIW, you really should always use "su -", which is the short form of
"su -l", which simulates a full log in.

The reason I suggest using "su -" as a habit and solely "su" when
explicitly desired, is that there are common administration tasks that
use environment variables and permissions, and over time, using solely
"su", tends to cause a mish-mash of bad permissions on files you touch
-- especially in your main user's home directory.

__armando

On Thu, Aug 28, 2008 at 2:42 AM, Juan Pablo Aroztegi <jpabloae_AT_gmail.com> wrote:
> Unfortunately this problem is still present in portage. A simple
> workaround is to use "su -" to get a clean environment as root, and
> not "su".
>
> Sorry for bringing up this old thread, but I thought other gentoo
> users might find it useful.
>
>
> Juan Pablo
>
> On Sat, May 3, 2008 at 5:56 PM, Kris Maglione <jg_AT_suckless.org> wrote:
>> On Sat, May 03, 2008 at 11:44:03AM +0200, Juan Pablo Aroztegi wrote:
>>>
>>> /var/tmp/portage/sys-devel/bc-1.06-r6/temp/environment: line 1:
>>> *=urxvt: command not found
>>
>> It seems like something does
>> env >$temp/environment; . $temp/environment.
>>
>> Really, this is a bug in their code. Unfortunately, there's no way to unset
>> an envorinment variable in rc (Yes, it's lame. Complane to Tom, if you'd
>> like, but it won't help). I could always switch to the Unix rc port, and
>> earn the neverending ire of some Plan 9 folks, though.
>>
>>> /usr/lib/portage/bin/ebuild.sh: line 1658: /bin/sort: Argument list too
>>> long
>>> /usr/lib/portage/bin/ebuild.sh: line 1658: /bin/tr: Argument list too long
>>> /usr/lib/portage/bin/misc-functions.sh: line 433: /usr/bin/find:
>>
>> These are because rc stores functions in its environment. I'll add code to
>> wi_runcmd to unset them; you're not the first to have this trouble.
>>
>> Something like:
>>
>> fn `{env | sed -n 's/^fn#([^=]+).*/\1/p'}
>>
>> Or, you could use zsh, which automagically strips environment variables that
>> it doesn't like.
>>
>> --
>> Kris Maglione
>>
>> You don't have to be crazy to work here
>> but it sure helps!!!!!!!
>>
>> PGP: http://suckless.org/~jg/pubkey.pgp
>> SHA1 (pubkey.pgp) = 2d464f9dbb186bee6f4faa88e2f6c5802bcfd935
>>
>
>
Received on Fri Sep 05 2008 - 16:25:03 UTC

This archive was generated by hypermail 2.2.0 : Fri Sep 05 2008 - 16:36:06 UTC