- Tweak /etc/zshrc to source /etc/profile.d/*.sh in ksh compat. mode
- Tweak /etc/zprofile to source /etc/profile in ksh compat. mode - Resolves: rhbz#430665
This commit is contained in:
parent
fec3f9a708
commit
87e381feb3
19
zprofile.rhs
19
zprofile.rhs
@ -5,7 +5,18 @@
|
|||||||
PATH="$PATH:$HOME/bin"
|
PATH="$PATH:$HOME/bin"
|
||||||
export PATH
|
export PATH
|
||||||
|
|
||||||
# source profile
|
_src_etc_profile()
|
||||||
if [ -f /etc/profile ]; then
|
{
|
||||||
source /etc/profile
|
# Make /etc/profile happier, and have possible ~/.zshenv options like
|
||||||
fi
|
# NOMATCH ignored.
|
||||||
|
#
|
||||||
|
emulate -L ksh
|
||||||
|
|
||||||
|
# source profile
|
||||||
|
if [ -f /etc/profile ]; then
|
||||||
|
source /etc/profile
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
_src_etc_profile
|
||||||
|
|
||||||
|
unset -f _src_etc_profile
|
||||||
|
2
zsh.spec
2
zsh.spec
@ -3,7 +3,7 @@
|
|||||||
Summary: A powerful interactive shell
|
Summary: A powerful interactive shell
|
||||||
Name: zsh
|
Name: zsh
|
||||||
Version: 4.3.4
|
Version: 4.3.4
|
||||||
Release: 6%{?dist}
|
Release: 7%{?dist}
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: http://zsh.sunsite.dk/
|
URL: http://zsh.sunsite.dk/
|
||||||
Group: System Environment/Shells
|
Group: System Environment/Shells
|
||||||
|
29
zshrc.rhs
29
zshrc.rhs
@ -15,19 +15,24 @@ PROMPT='[%n@%m]%~%# ' # default prompt
|
|||||||
# bindkey -e # emacs key bindings
|
# bindkey -e # emacs key bindings
|
||||||
bindkey ' ' magic-space # also do history expansion on space
|
bindkey ' ' magic-space # also do history expansion on space
|
||||||
|
|
||||||
|
_src_etc_profile_d()
|
||||||
{
|
{
|
||||||
# Make the *.sh things happier, and have possible ~/.zshenv options like
|
# Make the *.sh things happier, and have possible ~/.zshenv options like
|
||||||
# NOMATCH ignored.
|
# NOMATCH ignored.
|
||||||
emulate -L ksh
|
emulate -L ksh
|
||||||
|
|
||||||
|
|
||||||
# from bashrc, with zsh fixes
|
# from bashrc, with zsh fixes
|
||||||
if [[ ! -o login ]]; then # We're not a login shell
|
if [[ ! -o login ]]; then # We're not a login shell
|
||||||
for i in /etc/profile.d/*.sh; do
|
for i in /etc/profile.d/*.sh; do
|
||||||
if [ -r "$i" ]; then
|
if [ -r "$i" ]; then
|
||||||
. $i
|
. $i
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
unset i
|
unset i
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
_src_etc_profile_d
|
||||||
|
|
||||||
|
unset -f _src_etc_profile_d
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user