Skip to content

Having an issue reading the post-commit file #12

Description

@nsthi

When I run your script line-by-line through the console the commits go through to Asana, but when I just straight up commit it seems like there's errors with the file.

I'm getting the following error after adding echo "start" and echo "end" to the beginning and end of the post-commit file under .git/hooks:

neilsethi$ git commit -a
start
.git/hooks/post-commit: line 4: require: command not found
.git/hooks/post-commit: line 5: require: command not found
.git/hooks/post-commit: line 8: message: command not found
.git/hooks/post-commit: line 9: commit: command not found
.git/hooks/post-commit: line 10: author_name: command not found
.git/hooks/post-commit: line 11: author_email: command not found
.git/hooks/post-commit: line 12: Asana.init: command not found
.git/hooks/post-commit: line 16: syntax error near unexpected token `('
.git/hooks/post-commit: line 16: `annotations = message.scan /\[(\w+)?\s*#(\d{10,})\]/'
[DUMMY_BRANCH a7f6c9a] [#6983249164590] This won't work.
 1 files changed, 1 insertions(+), 0 deletions(-)
 create mode 100644 yo

Any ideas?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions