Skip to content

Unable to commit when git hooks use bash syntax. #10060

@b-hayes

Description

@b-hayes

Describe the feature or problem you’d like to solve

Our project have git hooks that were written for Mac and Linux but I am in windows. WSL is my dev env and can run these hooks but Github desktop will not run any git commands in WSL behind the scenes.

Github desktop is unusable by many devs using WSL.

When a git hook is run via GitHub desktop we see:
Commit failed - exit code 1 received, with output: ''.' is not recognized as an internal or external command,
operable program or batch file.'

Also tried using bash as my shell.
Also tried adding "bash -c" etc into the git hooks that run but then I get "bash is not a recognized command" even tho it IS recognized by all my shells.

Proposed solution

Please add WSL integration || or actually use the shell to run already working git cli so that desktop is just an interface running git commands behind the scenes would be nice.

Additional context

Some context.. the hooks are php files with
#!/usr/bin/env php

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions