Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The heroku command executing on the Git Bash of Windows fails #805

Closed
takamin opened this issue Apr 22, 2018 · 4 comments
Closed

The heroku command executing on the Git Bash of Windows fails #805

takamin opened this issue Apr 22, 2018 · 4 comments

Comments

@takamin
Copy link

takamin commented Apr 22, 2018

$ heroku
sed: -e expression #1, char 7: unterminated `s' command
/c/Program Files/heroku/bin/heroku: line 4: ./../client/bin/heroku.cmd: No such file or directory

I encountered this today with using a latest Heroku CLI downloaded at 22 Apr. 2018.

I am fixing this problem in my local environment by changing a shell script C:\Program Files\heroku\bin\heroku. The problem is that the backslash in the sed command was not escaped.
This outputs following version.

$ heroku --version
heroku-cli/7.0.2 win32-x64 node-v9.11.1
@jiehan1029
Copy link

Hi @takamin , Thanks for posting it!!! I have exactly the same problem and have been searching for a solution for quiiiiiiiiiite a while, glad to see I'm not alone and there IS a solution! Meanwhile, would you provide some more details on how you change the shell script? I'm completely a novice to command line.

@takamin
Copy link
Author

takamin commented May 9, 2018

Hi, thanks @jiehan1029 , Here is the script I fixed on my local.

C:\Program Files\heroku\bin\heroku:

#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")

"$basedir/../client/bin/heroku.cmd" "$@"
ret=$?
exit $ret

But this might have been fixed on the latest release.
You'd better install the latest one.

@jiehan1029
Copy link

@takamin Thanks!! I'll try it out. In fact when using cmder, everything turns out just fine. Only git bash is giving me the problem... I'll see if this fix can resolve it.

@KiburiNjenga
Copy link

i apparently got stuck at the same point ,how do i navigate through it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants