First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 10724
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: phoen][x <fisi.tilman.klar@gmx.de>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: James Michael Fultz <croooow@gmail.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
zshenv zshenv text/plain James Michael Fultz 2002-11-14 04:18 0000 318 bytes Details
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 10724 depends on: Show dependency tree
Bug 10724 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2002-11-14 03:42 0000
I hope to help solve two problems I've encountered and am sure affects other
Gentoo Linux and Zsh users. One is that Zsh doesn't incorporate the setup from
env.d without adding some code for it to my local startup files.  The other is
that the files `zshenv', `zshrc', and `zlogin' in the directory `/etc/zsh'
should not be installed as global startup files.  They are only meant as
examples and are commented as such.  The following line is taken from
`/etc/zsh/zshenv':

# THIS FILE IS NOT INTENDED TO BE USED AS /etc/zshenv, NOR WITHOUT EDITING

Both `zshrc' and `zlogin' bear similar comments.

My suggestion is that these three files not be installed, but rather the
following `zshenv' I've created be used instead:

--- Begin zshenv ---
if [[ -o rcs ]]
then
	if [[ -e "/etc/profile.env" ]]
	then
		  source /etc/profile.env
	fi

	#077 would be more secure, but 022 is generally quite realistic
	umask 022

	if [[ $(/usr/bin/whoami) == 'root' ]]
	then
		export PATH="/bin:/sbin:/usr/bin:/usr/sbin:${ROOTPATH}"
	else
		export PATH="/bin:/usr/bin:${PATH}"
	fi
	unset ROOTPATH
fi

--- End zshenv ---

Since Zsh is a superset of the POSIX and Bourne shells, I used `/etc/profile' as
template.  I've tested this file on my system and have had no problems.

------- Comment #1 From James Michael Fultz 2002-11-14 04:18:24 0000 -------
Created an attachment (id=5658) [edit]
zshenv

I later made some minor improvements in `zshenv'.  Perhaps increasing
efficiency the tiniest amount, but mostly improving readability by reducing the
level of indent.

------- Comment #2 From phoen][x 2002-11-15 10:03:14 0000 -------
Eek, now who put these files into /etc/zsh in the first place?

I removed zshrc and zshlogin and replaced zshenv with your version.
Works pretty well here, thanks for the contribution James.

-phoen][x-

First Last Prev Next    No search results available      Search page      Enter new bug