Skip to content

Suggestion: GrumPHP to have a git checkout hook capability as well as commit hook. #1208

@Spudley

Description

@Spudley

My suggestion is for GrumPHP to be extended to allow it to manage a git checkout hook in addition to the commit hook it currently uses.

Here's the scenario:

We have a team of devs each working on multiple branches of our code. These branches can sometimes be in entirely different versions.

Switching from one branch to another always requires running composer install and npm install to ensure that all the dependencies are in sync with the version of the code you just checked out. But devs frequently seem to forget to do this, which has resulted in a number of issues caused by working against the wrong dependencies.

It would therefore seem like a good idea to force composer update, etc to be run whenever a dev switch branch. A git hook on checkout would seem to be the ideal solution to this, and configuring it via a tool like GrumPHP would make it a lot easier to manage and ensure the team are all on the same page.

If feels like this would be a natural extension for GrumPHP. Is it something that could be added?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions