8000 Hook args are HTML-escaped by gyoshev · Pull Request #15 · wecodemore/grunt-githooks · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Hook args are HTML-escaped #15

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 12, 2013

Conversation

gyoshev
Copy link
Contributor
@gyoshev gyoshev commented Dec 12, 2013

Consider the following hook definition:

'pre-commit': {
    taskNames: 'jshint',
    args: '--files="$(git diff --cached --name-only -diff-filter=ACM)"'
}

It yields the following command from the default template:

'grunt jshint --files="$(git diff --cached --name-only -diff-filter=ACM)"'

... which obviously does not execute correctly, as the shell knows no HTML encoding.

romaricpascal added a commit that referenced this pull request Dec 12, 2013
@romaricpascal romaricpascal merged commit 78a52d1 into wecodemore:master Dec 12, 2013
@romaricpascal
Copy link
Contributor

Arg, hadn't thought about the HTML escaping from handlebars :( Thanks a lot for noticing and submitting the pull request :)

I'll try to publish a new version on NPM by the end of the week.

@gyoshev
Copy link
Contributor Author
gyoshev commented Dec 12, 2013

A new version will be great :) Thanks!

@romaricpascal
Copy link
Contributor

The new version is out :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0