mroth / scmpuff

:1234: Numeric file shortcuts for common git commands
https://mroth.github.io/scmpuff/
MIT License
384 stars 22 forks source link

Allow semicolons to be used in commit messages #7

Closed creature closed 9 years ago

creature commented 9 years ago

If I'm committing two semi-related bits of functionality, I'll often use a semicolon in the commit message to separate them:

git commit -m "Fix escaping of semicolons; unit test to ensure it works."

scmpuff didn't treat the semicolon as a special character. This results in abridged commit messages, and errors in the output:

[master (root-commit) cc10013] Fix escaping of semicolons
 1 file changed, 0 insertions(+), 0 deletions(-)
 create mode 100644 a.txt
bash:  unit test to ensure it works.: command not found

This PR fixes that. I also tested that actual semicolons are unaffected (eg. git commit -m "Foo; bar"; say "Commit finished"), but I couldn't see a good way to write a test for that case.

mroth commented 9 years ago

This looks great @creature. I can't for the life of me figure out why Travis-CI didn't run on the PR, though... :confused:

mroth commented 9 years ago

Okay, I ran the tests manually locally on this PR, all looks good. Thanks so much for the contribution!

creature commented 9 years ago

No problem! Glad to have helped. :) I've also got no idea why Travis didn't run on it.