Skip to content

Commit 91e680d

Browse files
committed
Replace outdated bundle install --binstubs
Use `script/bundle` from monorepo
1 parent f16a163 commit 91e680d

File tree

3 files changed

+25
-6
lines changed

3 files changed

+25
-6
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,7 @@ jobs:
2525
with:
2626
ruby-version: '3.3'
2727
- run: script/update_rubygems_and_install_bundler
28-
- run: bundle install --standalone
29-
- run: bundle binstubs --all
28+
- run: script/bundle
3029
- run: script/run_rubocop
3130

3231
test:
@@ -88,6 +87,6 @@ jobs:
8887
ruby-version: ${{ matrix.ruby }}
8988
- run: script/update_rubygems_and_install_bundler
9089
- run: script/clone_all_rspec_repos
91-
- run: bundle install --binstubs
90+
- run: script/bundle
9291
- run: script/run_build
9392
continue-on-error: ${{ matrix.allow_failure || false }}

script/bundle

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
set -e
2+
3+
ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd )"
4+
SCRIPT_DIR="${ROOT_DIR}/script"
5+
source $SCRIPT_DIR/functions.sh
6+
7+
echo "Set bundle path to .bundle/gems"
8+
bundle config set --local path '.bundle/gems'
9+
10+
if [[ -n "$1" ]]; then
11+
GEMFILE="Gemfile-${1}"
12+
echo "bundle install --standalone --gemfile=${GEMFILE}"
13+
bundle install --standalone --gemfile="${ROOT_DIR}/${GEMFILE}"
14+
else
15+
echo "bundle install --standalone"
16+
bundle install --standalone
17+
18+
echo "bundle binstubs --all --standalone"
19+
bundle binstubs --all --standalone
20+
fi;

script/functions.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,13 +112,13 @@ function check_binstubs {
112112
echo "Install missing binstubs using one of the following:"
113113
echo
114114
echo " # Create the missing binstubs"
115-
echo " $ bundle binstubs$gems"
115+
echo " $ bundle binstubs $gems"
116116
echo
117117
echo " # To binstub all gems"
118-
echo " $ bundle install --binstubs"
118+
echo " $ bundle binstubs --all"
119119
echo
120120
echo " # To binstub all gems and avoid loading bundler"
121-
echo " $ bundle install --binstubs --standalone"
121+
echo " $ bundle binstubs --all"
122122
fi
123123

124124
return $success

0 commit comments

Comments
 (0)