jzaefferer / commitplease

Validates strings as commit messages
87 stars 17 forks source link

Sanitize: support custom core.commentchar that can be set by git #64

Closed alisianoi closed 8 years ago

alisianoi commented 8 years ago

My problem ended up being twofold:

git returns various non-zeroes when there is something wrong with the setting, see Description -> This command will fail .... So, execSync was throwing that non-zero as an error while I was thinking I must have done something wrong and caused the error. And when I was trying simpler scripts, I was still actually running the original script and getting the same error. Yay.

Closes #27

jzaefferer commented 8 years ago

I assume you've tested this manually, successfully?

alisianoi commented 8 years ago

yes. First I did not change anything and observed the unit-tests pass. Then I set core.commentchar to semicolon ; and observed 18 unit tests fail because the comments were not cut out properly. Then I set it back to #, which passed all the tests.

jzaefferer commented 8 years ago

Diff is looking good now.

I don't think we need automated tests for this. So let's land it.