Fix adding composer_bin to PATH

This commit is contained in:
Shivam Mathur
2022-02-09 03:27:03 +05:30
parent a72a638da4
commit 7854a0cae7
4 changed files with 4 additions and 4 deletions

View File

@ -99,7 +99,7 @@ get_shell_profile() {
# Function to add a path to the PATH variable.
add_path() {
path_to_add=$1
{ [ ! -d "$path_to_add" ] || [[ ":$PATH:" == *":$path_to_add:"* ]]; } && return
[[ ":$PATH:" == *":$path_to_add:"* ]] && return
if [[ -n "$GITHUB_PATH" ]]; then
echo "$path_to_add" | tee -a "$GITHUB_PATH" >/dev/null 2>&1
else