1

i have created a new local repository and initialize it, then i define ST3 as default editor

git config --global core.editor "'C:\Program Files\Sublime Text 3\sublime_text.exe' -w" 

and when i commit i got this error

hint: Waiting for your editor to close the file... Skipping command-line '"C:\Users\Sony\bin\..\usr\bin\bash.exe"' ('C:\Users\Sony\bin\..\usr\bin\bash.exe' not found) Need a valid command-line; Edit the string recources accordingly error: There was a problem with the editor ''C:\Program Files\Sublime Text 3\sublime_text.exe' -w'. Please supply the message using either -m or -F option 

1 Answer 1

1

Try instead, as shown here:

git config --global core.editor "'C:/Program Files/Sublime Text 3/subl.exe' -w" 

This is also documented by GitHub.

It will work better when done from a CMD (instead of a bash session) because of the way the quotes (simple and double) are interpreted.

Sign up to request clarification or add additional context in comments.

4 Comments

did it before still sme probleme
@IlyesGhomrani Are you doing it in a CMD sesion, or a bash session? What is your current version of Git?
bash session, version : 2.16.2
@IlyesGhomrani Can you try the same git config command I mention in the answer from a CMD session? As well as the next git commit?

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.