git-extras icon indicating copy to clipboard operation
git-extras copied to clipboard

effort: handling of $'s and \n's, plus make shellcheck happy

Open nicolaiskogheim opened this issue 8 years ago • 2 comments

This fixes an issue that was reported this week, with $'s in a filename breaking git log and take git effort with it. git effort now understands how to treat files with actual newlines in them as well.

Shellcheck had some complaints, and I agreed to all of them. Because of that, there is a lot of code to review, so please look at each commit individually, if that makes it easier.

While I were at it, I expanded upon the docs, and made some small rewordings. If there are many comments on the doc edits, I'll split that out in it's own PR.


Please help test this

  • [x] macOS
  • [x] Linux
  • [ ] BSD

You can use this repo as a test repo. It contains files with names that should produce an error if the issue isn't fixed.

nicolaiskogheim avatar Jan 27 '17 01:01 nicolaiskogheim

Sorry for my missing of this. Pass under Linux with bash 4.3.30.

@nicolaiskogheim Could we merge the pr now?

spacewander avatar Feb 06 '17 03:02 spacewander

I'll fire up a FreeBSD box tomorrow and run the script just to be sure.

nicolaiskogheim avatar Feb 06 '17 21:02 nicolaiskogheim