Resolves: #1900809 - prepend ~/.local/bin and ~/bin to $PATH
... for newly created users
This commit is contained in:
parent
717b27b08b
commit
5ac50934d3
12
dotzprofile
Normal file
12
dotzprofile
Normal file
@ -0,0 +1,12 @@
|
||||
# this file is installed as ~/.zprofile for newly created users
|
||||
|
||||
# prepend ~/.local/bin and ~/bin to $PATH unless it is already there
|
||||
if ! [[ "$PATH" =~ "$HOME/bin" ]]
|
||||
then
|
||||
PATH="$HOME/bin:$PATH"
|
||||
fi
|
||||
if ! [[ "$PATH" =~ "$HOME/.local/bin:" ]]
|
||||
then
|
||||
PATH="$HOME/.local/bin:$PATH"
|
||||
fi
|
||||
export PATH
|
@ -2,9 +2,6 @@
|
||||
# /etc/zprofile and ~/.zprofile are run for login shells
|
||||
#
|
||||
|
||||
PATH="$PATH:$HOME/bin"
|
||||
export PATH
|
||||
|
||||
_src_etc_profile()
|
||||
{
|
||||
# Make /etc/profile happier, and have possible ~/.zshenv options like
|
||||
|
7
zsh.spec
7
zsh.spec
@ -1,7 +1,7 @@
|
||||
Summary: Powerful interactive shell
|
||||
Name: zsh
|
||||
Version: 5.8
|
||||
Release: 7%{?dist}
|
||||
Release: 8%{?dist}
|
||||
License: MIT
|
||||
URL: http://zsh.sourceforge.net/
|
||||
Source0: https://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.xz
|
||||
@ -11,6 +11,7 @@ Source3: zprofile.rhs
|
||||
Source4: zshrc.rhs
|
||||
Source5: zshenv.rhs
|
||||
Source6: dotzshrc
|
||||
Source7: dotzprofile
|
||||
|
||||
# complete file arguments after rpmbuild -r/-b/-t
|
||||
Patch1: 0001-zsh-5.8-comp-rpm.patch
|
||||
@ -117,6 +118,7 @@ done
|
||||
|
||||
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/skel
|
||||
install -m 644 %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/skel/.zshrc
|
||||
install -m 644 %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/skel/.zprofile
|
||||
|
||||
# This is just here to shut up rpmlint, and is very annoying.
|
||||
# Note that we can't chmod everything as then rpmlint will complain about
|
||||
@ -161,6 +163,9 @@ fi
|
||||
%doc Doc/*.html
|
||||
|
||||
%changelog
|
||||
* Tue Jan 04 2022 Kamil Dudka <kdudka@redhat.com> - 5.8-8
|
||||
- prepend ~/.local/bin and ~/bin to $PATH for newly created users (#1900809)
|
||||
|
||||
* Thu Nov 25 2021 Debarshi Ray <rishi@fedoraproject.org> - 5.8-7
|
||||
- Overwrite PROMPT only if it's set to the built-in default (#2026749)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user