summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorJimmie Wester <jimmie.wester@stericsson.com>2012-10-24 14:35:05 +0200
committerDavid Pursehouse <david.pursehouse@sonymobile.com>2015-02-03 16:01:15 +0900
commit38e4387f8eb8cffd6359d726c38a7c524fef07e3 (patch)
tree897b7f640822d21019d740fd45aa564fba6a18f9 /docs
parentee6908442102008df57b46271323d9b06d5fdfbf (diff)
downloadgit-repo-38e4387f8eb8cffd6359d726c38a7c524fef07e3.tar.gz
Implementation of manifest defined githooks
When working within a team or corporation it is often useful/required to use predefined git templates. This change teaches repo to use a per-remote git hook template structure. The implementation is done as a continuation of the existing projecthook functionality. The terminology is therefore defined as projecthooks. The downloaded projecthooks are stored in the .repo directory as a metaproject separating them from the users project forest. The projecthooks are downloaded and set up when doing a repo init and updated for each new repo init. When downloading a mirror the projecthooks gits are not added to the bare forest since the intention is to ensure that the latest are used (allows for company policy enforcement). The projecthooks are defined in the manifest file in the remote element as a subnode, the name refers to the project name on the server referred to in the remote. <remote name="myremote ..> <projecthook name="myprojecthookgit" revision="myrevision"/> </remote> The hooks found in the projecthook revision supersede the stock hooks found in repo. This removes the need for updating the projecthook gits for repo stock hook changes. Change-Id: I6796b7b0342c1f83c35f4b3e46782581b069a561 Signed-off-by: Patrik Ryd <patrik.ryd@stericsson.com> Signed-off-by: Ian Kumlien <ian.kumlien@gmail.com>
Diffstat (limited to 'docs')
-rw-r--r--docs/manifest-format.txt15
1 files changed, 14 insertions, 1 deletions
diff --git a/docs/manifest-format.txt b/docs/manifest-format.txt
index 1aa93965..4b979c79 100644
--- a/docs/manifest-format.txt
+++ b/docs/manifest-format.txt
@@ -31,7 +31,7 @@ following DTD:
31 31
32 <!ELEMENT notice (#PCDATA)> 32 <!ELEMENT notice (#PCDATA)>
33 33
34 <!ELEMENT remote (EMPTY)> 34 <!ELEMENT remote (projecthook?)>
35 <!ATTLIST remote name ID #REQUIRED> 35 <!ATTLIST remote name ID #REQUIRED>
36 <!ATTLIST remote alias CDATA #IMPLIED> 36 <!ATTLIST remote alias CDATA #IMPLIED>
37 <!ATTLIST remote fetch CDATA #REQUIRED> 37 <!ATTLIST remote fetch CDATA #REQUIRED>
@@ -73,6 +73,10 @@ following DTD:
73 <!ATTLIST extend-project path CDATA #IMPLIED> 73 <!ATTLIST extend-project path CDATA #IMPLIED>
74 <!ATTLIST extend-project groups CDATA #IMPLIED> 74 <!ATTLIST extend-project groups CDATA #IMPLIED>
75 75
76 <!ELEMENT projecthook (EMPTY)>
77 <!ATTLIST projecthook name CDATA #REQUIRED>
78 <!ATTLIST projecthook revision CDATA #REQUIRED>
79
76 <!ELEMENT remove-project (EMPTY)> 80 <!ELEMENT remove-project (EMPTY)>
77 <!ATTLIST remove-project name CDATA #REQUIRED> 81 <!ATTLIST remove-project name CDATA #REQUIRED>
78 82
@@ -306,6 +310,15 @@ target manifest to include - it must be a usable manifest on its own.
306Attribute `name`: the manifest to include, specified relative to 310Attribute `name`: the manifest to include, specified relative to
307the manifest repository's root. 311the manifest repository's root.
308 312
313Element projecthook
314-------------------
315
316This element is used to define a per-remote hook git that is
317fetched and applied to all projects using the remote. The project-
318hook functionality allows for company/team .git/hooks to be used.
319The hooks in the supplied project and revision are supplemented to
320the current repo stock hooks for each project. Supplemented hooks
321overrule any stock hooks.
309 322
310Local Manifests 323Local Manifests
311=============== 324===============