Re: [patch]: lib/cedit.menu: portability fixes
- From: Pavel Roskin <proski gnu org>
- To: "Andrew V. Samoilov" <andrew email zp ua>
- Cc: mc-devel gnome org
- Subject: Re: [patch]: lib/cedit.menu: portability fixes
- Date: Fri, 1 Aug 2003 13:44:24 -0400 (EDT)
On Fri, 25 Jul 2003, Andrew V. Samoilov wrote:
> Hello, Pavel!
>
> One more fix for Solaris.
I think it's over-engineered. Isn't $USER standard? Does "id -u" work?
It may be more reliable to use the numeric user ID. I suggest one of the
following, sorted in the order of decreased preference:
awk -F: '$1 == ENVIRON["USER"] {print $5}' /etc/passwd
awk -F: '$1 == "'$USER'" {print $5}' /etc/passwd
awk -F: '$3 == "'`id -u`'" {print $5}' /etc/passwd
awk -F: '$3 == "'`id | sed 's/^.*uid=\([^(]*\).*$/\1/'`'" {print $5}' /etc/passwd
> BTW, it will be fine to rename
> http://www.ibiblio.org/pub/Linux/utils/file/managers/mc/binaries/SunOS/mc-4.6.0-SunOS.tar.Z
> to mc-4.6.0-sol7-sparc-local.tar.Z and to place /usr/local/README from
> this tarball near tarball.
I have no idea why more generic "SunOS" should be replaced with more
specific "sol7" (what would Solaris 8 users think?), but I put README to
the same directory.
By the way, your mail program gives text attachments mime-type plain/text,
but it should be text/plain.
--
Regards,
Pavel Roskin
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]