Class HookUtil


  • public class HookUtil
    extends Object
    Static utilities for writing git protocol hooks.
    • Method Detail

      • ensureAllRefsAdvertised

        public static Map<String,​org.eclipse.jgit.lib.Ref> ensureAllRefsAdvertised​(org.eclipse.jgit.transport.ReceivePack rp)
                                                                                  throws org.eclipse.jgit.transport.ServiceMayNotContinueException
        Scan and advertise all refs in the repo if refs have not already been advertised; otherwise, just return the advertised map.
        Parameters:
        rp - receive-pack handler.
        Returns:
        map of refs that were advertised.
        Throws:
        org.eclipse.jgit.transport.ServiceMayNotContinueException - if a problem occurred.