git-hipchat-hook icon indicating copy to clipboard operation
git-hipchat-hook copied to clipboard

"-e" showing up in message

Open mattsawyer77 opened this issue 13 years ago • 4 comments

I installed the hook and hipchat-cli. Now when I push, I see this (which I'm unsure whether is related to the problem):

...
Delta compression using up to 8 threads.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (2/2), 449 bytes, done.
Total 2 (delta 0), reused 0 (delta 0)
remote: [: 13: 5a791478013b788df562c6bd5838775a1111136c: unexpected operator
remote: [: 62: 975b2c77036b4491c7e594e0a32ebffc6bd6fc0d: unexpected operator
remote: [: 62: 5a791478013b788df562c6bd5838775a1111136c: unexpected operator
...

The push succeeds, yet in my Hipchat window, I see a "-e" in front of each line in the message, like this:

-e Matt Sawyer pushed to branch master of samplerepo.git
-e - testing git-hipchat integration (975b2c7)

mattsawyer77 avatar May 16 '12 04:05 mattsawyer77

This should be the same as the issue mentioned in f22dc0fce64772f6132bdce53d42fd124bed8991, I'll check. Your repo server OS?

eirc avatar May 16 '12 07:05 eirc

Debian Squeeze.

mattsawyer77 avatar May 16 '12 15:05 mattsawyer77

Switching to /bin/bash works. The "-e" option isn't support in /bin/sh, so it's being echoed out as text.

nickread avatar May 17 '13 00:05 nickread

I think the -e option is implicit when echo is used inside scripts (as opposed to directly in the command line). I've removed it from all echo commands in the hook and it is working perfectly. I've tried commit messages with special chars and they are treated like the -e option was been used.

peterlozano avatar Dec 13 '13 14:12 peterlozano