Não pode escolher mais do que 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

43 linhas
1018 B

há 13 anos
há 13 anos
há 13 anos
há 13 anos
há 13 anos
há 13 anos
  1. #!/usr/bin/env bash
  2. #
  3. # Summary: Run an executable with the selected Ruby version
  4. #
  5. # Usage: rbenv exec <command> [arg1 arg2...]
  6. #
  7. # Runs an executable by first preparing PATH so that the selected Ruby
  8. # version's `bin' directory is at the front.
  9. #
  10. # For example, if the currently selected Ruby version is 1.9.3-p327:
  11. # rbenv exec bundle install
  12. #
  13. # is equivalent to:
  14. # PATH="$RBENV_ROOT/versions/1.9.3-p327/bin:$PATH" bundle install
  15. set -e
  16. [ -n "$RBENV_DEBUG" ] && set -x
  17. # Provide rbenv completions
  18. if [ "$1" = "--complete" ]; then
  19. exec rbenv shims --short
  20. fi
  21. export RBENV_VERSION="$(rbenv-version-name)"
  22. RBENV_COMMAND="$1"
  23. if [ -z "$RBENV_COMMAND" ]; then
  24. rbenv-help --usage exec >&2
  25. exit 1
  26. fi
  27. RBENV_COMMAND_PATH="$(rbenv-which "$RBENV_COMMAND")"
  28. RBENV_BIN_PATH="${RBENV_COMMAND_PATH%/*}"
  29. for script in $(rbenv-hooks exec); do
  30. source "$script"
  31. done
  32. shift 1
  33. if [ "$RBENV_VERSION" != "system" ]; then
  34. export PATH="${RBENV_BIN_PATH}:${PATH}"
  35. fi
  36. exec -a "$RBENV_COMMAND" "$RBENV_COMMAND_PATH" "$@"