summaryrefslogtreecommitdiff
path: root/plugins/bundler
diff options
context:
space:
mode:
authorMarc Cornellà <marc.cornella@live.com>2020-02-27 22:55:30 +0100
committerGitHub <noreply@github.com>2020-02-27 22:55:30 +0100
commit18ee5dffdc57bb9219ee96b40da006704ac37df1 (patch)
treee1fe420cf18fa7a916d5d43c408c6f92ed33b62d /plugins/bundler
parentd81cd753e0b3a845e8f3549da245dbad102a6e4c (diff)
parent368198b7616eb69b396de86d9ec4ff0f35bd72f0 (diff)
downloadzsh-18ee5dffdc57bb9219ee96b40da006704ac37df1.tar.gz
zsh-18ee5dffdc57bb9219ee96b40da006704ac37df1.tar.bz2
zsh-18ee5dffdc57bb9219ee96b40da006704ac37df1.zip
Merge branch 'master' into clipboard
Diffstat (limited to 'plugins/bundler')
-rw-r--r--plugins/bundler/README.md6
-rw-r--r--plugins/bundler/bundler.plugin.zsh5
2 files changed, 6 insertions, 5 deletions
diff --git a/plugins/bundler/README.md b/plugins/bundler/README.md
index dc2f17008..9f211b02f 100644
--- a/plugins/bundler/README.md
+++ b/plugins/bundler/README.md
@@ -2,7 +2,7 @@
- adds completion for basic bundler commands
- adds short aliases for common bundler commands
- - `be` aliased to `bundle exec`.
+ - `be` aliased to `bundle exec`.
It also supports aliases (if `rs` is `rails server`, `be rs` will bundle-exec `rails server`).
- `bl` aliased to `bundle list`
- `bp` aliased to `bundle package`
@@ -15,7 +15,7 @@
- calls `bundle exec <gem executable>` otherwise
Common gems wrapped by default (by name of the executable):
-`annotate`, `cap`, `capify`, `cucumber`, `foodcritic`, `guard`, `hanami`, `irb`, `jekyll`, `kitchen`, `knife`, `middleman`, `nanoc`, `pry`, `puma`, `rackup`, `rainbows`, `rake`, `rspec`, `shotgun`, `sidekiq`, `spec`, `spork`, `spring`, `strainer`, `tailor`, `taps`, `thin`, `thor`, `unicorn` and `unicorn_rails`.
+`annotate`, `cap`, `capify`, `cucumber`, `foodcritic`, `guard`, `hanami`, `irb`, `jekyll`, `kitchen`, `knife`, `middleman`, `nanoc`, `pry`, `puma`, `rackup`, `rainbows`, `rake`, `rspec`, `rubocop`, `shotgun`, `sidekiq`, `spec`, `spork`, `spring`, `strainer`, `tailor`, `taps`, `thin`, `thor`, `unicorn` and `unicorn_rails`.
## Configuration
@@ -42,7 +42,7 @@ This will exclude the `foreman` and `spin` gems (i.e. their executable) from bei
## Excluded gems
-These gems should not be called with `bundle exec`. Please see [issue #2923](https://github.com/robbyrussell/oh-my-zsh/pull/2923) on GitHub for clarification.
+These gems should not be called with `bundle exec`. Please see [issue #2923](https://github.com/ohmyzsh/ohmyzsh/pull/2923) on GitHub for clarification.
`berks`
`foreman`
diff --git a/plugins/bundler/bundler.plugin.zsh b/plugins/bundler/bundler.plugin.zsh
index 668e15d2f..665cb5e43 100644
--- a/plugins/bundler/bundler.plugin.zsh
+++ b/plugins/bundler/bundler.plugin.zsh
@@ -27,6 +27,7 @@ bundled_commands=(
rainbows
rake
rspec
+ rubocop
shotgun
sidekiq
spec
@@ -81,7 +82,7 @@ _bundler-installed() {
_within-bundled-project() {
local check_dir="$PWD"
while [ "$check_dir" != "/" ]; do
- [ -f "$check_dir/Gemfile" ] && return
+ [ -f "$check_dir/Gemfile" -o -f "$check_dir/gems.rb" ] && return
check_dir="$(dirname $check_dir)"
done
false
@@ -94,7 +95,7 @@ _binstubbed() {
_run-with-bundler() {
if _bundler-installed && _within-bundled-project; then
if _binstubbed $1; then
- ./bin/$@
+ ./bin/${^^@}
else
bundle exec $@
fi