Install the pre-commit hook by running pre-commit install --hook-type prepare-commit-msg
Create a commit (no need to add co-authors)
Expected behavior:
The commit works.
Actual behavior:
Hook fails with the following message:
add-coauthors............................................................Failed
- hook id: add-coauthors
- exit code: 1
Executable `<user_home>/.cache/pre-commit/repo3kja4lqk/blob/master/packages/git-mob/hook-examples/prepare-commit-msg-nodejs` not found
The file is not present in the .cache folder. A visual inspection on the cache files seems to indicate pre-commit checks out the code, not the Github blob files.
I'm not an expert in pre-commit hooks but I think it could be enough updating the .pre-commit-hooks.yaml file removing the /blob/master string from the entry value.
Reproduces how often:
100% reproducible
Versions
operating system and version: Sonoma 14.3
git-mob version (git-mob --version): 2.3.5
git version (git --version): 2.43.0
Additional Information
I tried forking the repo and applying the change in the fork. The suggested change works. However, as I mentioned I'm not an expert on pre-commit hooks and I cannot evaluate the side effects of the change.
Prerequisites
npm i -g git-mob
)brew upgrade git
if installed with Homebrew/Linuxbrew)Description
git mob fails in the CLI when installed via pre-commit hooks.
Steps to Reproduce
.pre-commit-config.yaml
with the following configuration (latest version when this isssue was created):pre-commit install --hook-type prepare-commit-msg
Expected behavior: The commit works.
Actual behavior: Hook fails with the following message:
The file is not present in the
.cache
folder. A visual inspection on the cache files seems to indicate pre-commit checks out the code, not the Github blob files.I'm not an expert in pre-commit hooks but I think it could be enough updating the .pre-commit-hooks.yaml file removing the
/blob/master
string from theentry
value.Reproduces how often: 100% reproducible
Versions
git-mob --version
): 2.3.5git --version
): 2.43.0Additional Information
I tried forking the repo and applying the change in the fork. The suggested change works. However, as I mentioned I'm not an expert on pre-commit hooks and I cannot evaluate the side effects of the change.