Add rubocop-bundle-safe executable

Within a bundled project, rubocop is executed via "bundle exec", while
outside of a project it's run executed directly.
This commit is contained in:
2017-05-26 15:32:24 +01:00
parent c39ab843f9
commit 71a669b5bc

7
bin/rubocop-bundle-safe Executable file
View File

@@ -0,0 +1,7 @@
#! /usr/bin/env bash
if bundle check &>/dev/null; then
exec bundle exec rubocop "$@"
else
exec rubocop "$@"
fi