From 100d189e8efa9c131c2a281e23351fbf39f46bdb Mon Sep 17 00:00:00 2001 From: CMK Date: Fri, 15 Jul 2022 13:32:02 +0800 Subject: [PATCH] chore: set custom GEM_HOME due to default one cannot access without sudo --- ci_scripts/ci_post_clone.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ci_scripts/ci_post_clone.sh b/ci_scripts/ci_post_clone.sh index 0264103d9..ee67ff0b5 100755 --- a/ci_scripts/ci_post_clone.sh +++ b/ci_scripts/ci_post_clone.sh @@ -16,8 +16,14 @@ echo $PWD brew install ruby ruby --version +# workaround default installation location cannot access without sudo problem +echo 'export GEM_HOME=$HOME/gems' >>~/.bash_profile +echo 'export PATH=$HOME/gems/bin:$PATH' >>~/.bash_profile +export GEM_HOME=$HOME/gems +export PATH="$GEM_HOME/bin:$PATH" + # install bundle gem -gem install bundler +gem install bundler --install-dir $GEM_HOME # setup gems bundle install