Skip to content
This repository has been archived by the owner on Aug 16, 2024. It is now read-only.

Commit

Permalink
Check that $HOME is writable before creating .bashrc
Browse files Browse the repository at this point in the history
Signed-off-by: Angel Misevski <amisevsk@redhat.com>
  • Loading branch information
amisevsk committed Jul 23, 2019
1 parent e10774c commit b4d1634
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arbitrary-users-patch/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ if [ ! -d "${HOME}" ]; then
fi

# Setup $PS1 for a consistent and reasonable prompt
if [ ! -f "${HOME}"/.bashrc ]; then
if [ -w "${HOME}" ] && [ ! -f "${HOME}"/.bashrc ]; then
echo "PS1='\s-\v \w \$ '" > "${HOME}"/.bashrc
fi

Expand Down

0 comments on commit b4d1634

Please sign in to comment.