From 29d829282c93a2fa31e3f8c429834c05283f1329 Mon Sep 17 00:00:00 2001 From: Hari Sekhon Date: Fri, 6 Dec 2019 17:40:09 +0000 Subject: [PATCH] updated install_aws_cli.sh --- setup/install_aws_cli.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/setup/install_aws_cli.sh b/setup/install_aws_cli.sh index c7b672d1..3c9c41a1 100755 --- a/setup/install_aws_cli.sh +++ b/setup/install_aws_cli.sh @@ -49,9 +49,12 @@ echo # export PATH="$PATH:$HOME/.linuxbrew/bin" #fi -if [ -d ~/.linuxbrew/bin ]; then - export PATH="$PATH:"~/.linuxbrew/bin -fi +# root installs to first one, user installs to the latter +for x in /home/linuxbrew/.linuxbrew/bin ~/.linuxbrew/bin; do + if [ -d "$x" ]; then + export PATH="$PATH:$x" + fi +done brew tap aws/tap echo