Homec4science

Install pre-commit hooks in Git repositories

Authored by epriestley <git@epriestley.com> on Dec 3 2013, 00:45.

Description

Install pre-commit hooks in Git repositories

Summary:
Ref T4189. T4189 describes most of the intent here:

  • When updating hosted repositories, sync a pre-commit hook into them instead of doing a git fetch.
  • The hook calls into Phabricator. The acting Phabricator user is sent via PHABRICATOR_USER in the environment. The active repository is sent via CLI.
  • The hook doesn't do anything useful yet; it just veifies basic parameters, does a little parsing, and exits 0 to allow the commit.

Test Plan:

  • Performed Git pushes and pulls over SSH and HTTP.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4189

Differential Revision: https://secure.phabricator.com/D7682

Details

Committed
epriestley <git@epriestley.com>Dec 3 2013, 00:45
Pushed
aubortJan 31 2017, 17:16
Parents
rPH95c2b5097447: Shorten extremely long credential names when migrating them
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPH618b5cbbc4e8: Install pre-commit hooks in Git repositories (authored by epriestley <git@epriestley.com>).Dec 3 2013, 00:45