We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1878e3b commit 2028b5cCopy full SHA for 2028b5c
templates/hooks/commit-msg
@@ -26,11 +26,15 @@ if [ -z "$GIT_BRANCH_NAME" ]; then
26
exit 0
27
fi
28
29
-if which rvm > /dev/null 2>&1
30
-then cmd="rvm default do ruby"
31
-elif which rbenv > /dev/null 2>&1
32
-then cmd="rbenv exec ruby"
33
-else cmd="ruby"
+# find appropriate Ruby command
+if which rbenv > /dev/null 2>&1; then
+ cmd="rbenv exec ruby"
+elif which ruby-rvm-env > /dev/null 2>&1; then
+ cmd="ruby-rvm-env"
34
+elif which rvm > /dev/null 2>&1; then
35
+ cmd="rvm default do ruby"
36
+else
37
+ cmd="ruby"
38
39
40
# allow user input if running in a terminal
0 commit comments