No Description

psysh 611B

123456789101112131415161718
  1. #!/usr/bin/env sh
  2. dir=$(d=${0%[/\\]*}; cd "$d" > /dev/null; cd "../psy/psysh/bin" && pwd)
  3. # See if we are running in Cygwin by checking for cygpath program
  4. if command -v 'cygpath' >/dev/null 2>&1; then
  5. # Cygwin paths start with /cygdrive/ which will break windows PHP,
  6. # so we need to translate the dir path to windows format. However
  7. # we could be using cygwin PHP which does not require this, so we
  8. # test if the path to PHP starts with /cygdrive/ rather than /usr/bin
  9. if [[ $(which php) == /cygdrive/* ]]; then
  10. dir=$(cygpath -m "$dir");
  11. fi
  12. fi
  13. dir=$(echo $dir | sed 's/ /\ /g')
  14. "${dir}/psysh" "$@"