diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/common-utils/devcontainer-feature.json | 2 | ||||
-rw-r--r-- | src/common-utils/main.sh | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/common-utils/devcontainer-feature.json b/src/common-utils/devcontainer-feature.json index dc54e69..329f8de 100644 --- a/src/common-utils/devcontainer-feature.json +++ b/src/common-utils/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "common-utils", - "version": "2.3.0", + "version": "2.3.1", "name": "Common Utilities", "documentationURL": "https://github.com/devcontainers/features/tree/main/src/common-utils", "description": "Installs a set of common command line utilities, Oh My Zsh!, and sets up a non-root user.", diff --git a/src/common-utils/main.sh b/src/common-utils/main.sh index a291f98..26f0a75 100644 --- a/src/common-utils/main.sh +++ b/src/common-utils/main.sh @@ -459,8 +459,10 @@ fi # Optionally configure zsh and Oh My Zsh! if [ "${INSTALL_ZSH}" = "true" ]; then - if [ ! -f "${user_home}/.zprofile" ] || ! grep -Fxq 'source $HOME/.profile' "${user_home}/.zprofile" ; then - echo 'source $HOME/.profile' >> "${user_home}/.zprofile" + if [ ! -f "${user_home}/.zprofile" ]; then + touch "${user_home}/.zprofile" + echo 'source $HOME/.profile' >> "${user_home}/.zprofile" # TODO: Reconsider adding '.profile' to '.zprofile' + chown ${USERNAME}:${group_name} "${user_home}/.zprofile" fi if [ "${ZSH_ALREADY_INSTALLED}" != "true" ]; then |