Re: Update a bare repository
- From
Jeff King <peff@peff.net>
- Date
- Jul 17, 2007, 07:31 UTC
- Message-ID
- <20070717073115.GA14629@coredump.intra.peff.net>
- In-Reply-To
- <20070717072635.GG5823@cip.informatik.uni-erlangen.de>
On Tue, Jul 17, 2007 at 09:26:35AM +0200, Thomas Glanzmann wrote:
Show 5 quoted lines
> > The simplest thing is not to give write access to the repo for your > > pushers. However, you could also put in a pre-receive hook that rejects > > all pushes. > > Is there an example somewhere?
Not that I know of, but it should be as simple as:
echo "echo Sorry, no pushing allowed.; exit 1" >.git/hooks/pre-receive chmod +x .git/hooks/pre-receive
-Peff