Skip to content

Commit

Permalink
fix: add_profile shoud return 0 if no items found in profile
Browse files Browse the repository at this point in the history
  • Loading branch information
dantengsky committed Jun 16, 2022
1 parent fb252ab commit 75e5777
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/setup/dev_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ cd "$SCRIPT_PATH/../.." || exit

function add_to_profile {
eval "$1"
FOUND=$(grep -c "$1" <"${HOME}/.profile")
FOUND=$(grep -c "$1" "${HOME}/.profile" || true)
if [ "$FOUND" == "0" ]; then
echo "$1" >>"${HOME}"/.profile
fi
Expand Down

0 comments on commit 75e5777

Please sign in to comment.