Warning: Noob question ahead!
I'm using Heroku, and have forgetting to close the quotation marks when committing:
localhost: app myMac$ git commit -m "testing
>
As you can see the last " is missing on the end of testing. Now I've got the > sign and I'm unsure how to get out of it? This must be a trivial thing but I just can't get a grip of it!
This is more of a bash question than a git one.
For a forgotten quotation mark, see this answer on superuser.com.
Basically, press ctrl-c to cancel the current command, then the up arrow ↑ to retrieve your last line typed.
localhost: app myMac$ git commit -m "testing
>
Whoops, hit ctrl-c.
localhost: app myMac$
Now press the up arrow ↑...
localhost: app myMac$ git commit -m "testing
and try again.
Just add " and press enter. If you want to fix the commit message to remove the new line run:
git commit --amend -m "Replacement commit"
This will change the last commit message to the new one.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With