tjni / captain-hook

Gradle plugin for installing Git hooks.
MIT License
14 stars 1 forks source link

Make hooks work on Windows #4

Closed kiview closed 1 year ago

kiview commented 3 years ago

Currently, this bash script will be rendered as commit hook script on Windows:

#!/bin/sh -

`dirname "$0"`\git-hooks\pre-commit

The Windows path separators are unwanted in this case, since bash included in Git, which is used to execute the script, won't interpret them as path separators, but as escape characters.

This PR replaces the platform-dependent path separator with / since the script will be executed with bash on Windows as well.

bsideup commented 1 year ago

Hi @tjni, any chance you could PTAL? 🙌

tjni commented 1 year ago

I'm sorry, guys! Life events, blah blah. Thank you both for looking into this.

bsideup commented 1 year ago

@tjni wooo! Thank you for merging it, and no problem at all. The plugin is great and does its job, we are a very happy user of it at @AtomicJar 🙌

eddumelendez commented 1 year ago

Thanks for the release @tjni! but looks like it is not available via maven central.