Skip to content

Commit

Permalink
Merge branch 'master' of github.com:sm/sm
Browse files Browse the repository at this point in the history
  • Loading branch information
mpapis committed Aug 27, 2012
2 parents 4271855 + 2b8929c commit 3c9f280
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions core/internal/shell/extensions/execution/functions
Expand Up @@ -3,7 +3,7 @@
__sm.extension.actions.type() __sm.extension.actions.type()
{ {
typeset -g action_type typeset -g action_type
typeset _path _path_type extension shebang typeset _path _path_type extension shebang binary
_path="${action_path:-}" _path="${action_path:-}"


case "${action}" in case "${action}" in
Expand Down Expand Up @@ -43,7 +43,7 @@ __sm.extension.actions.type()


case "${shebang}" in case "${shebang}" in
*ruby|*rbx|*jruby|*macruby) *ruby|*rbx|*jruby|*macruby)
binary="${shebang##*(#|!)}" binary="${shebang##*(\#|!)}"
binary="${binary##* }" binary="${binary##* }"
action_type="ruby" action_type="ruby"
;; ;;
Expand Down Expand Up @@ -191,7 +191,10 @@ __sm.extension.run()
requires=() requires=()
for script in functions initialize for script in functions initialize
do do
requires+=( "-r${__sm_modules_path}/ruby/core/${script}.rb" ) if [[ -f "${__sm_modules_path}/ruby/core/${script}.rb" ]]
then
requires+=( "-r${__sm_modules_path}/ruby/core/${script}.rb" )
fi
done done


exec "${binary:-ruby}" -I"${__sm_modules_path}/ruby" -I"${extension_modules_path}/ruby" \ exec "${binary:-ruby}" -I"${__sm_modules_path}/ruby" -I"${extension_modules_path}/ruby" \
Expand Down

0 comments on commit 3c9f280

Please sign in to comment.