Return-Path: X-Original-To: apmail-subversion-users-archive@minotaur.apache.org Delivered-To: apmail-subversion-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 25F9FD667 for ; Tue, 7 Aug 2012 18:51:01 +0000 (UTC) Received: (qmail 50010 invoked by uid 500); 7 Aug 2012 18:50:59 -0000 Delivered-To: apmail-subversion-users-archive@subversion.apache.org Received: (qmail 49993 invoked by uid 500); 7 Aug 2012 18:50:59 -0000 Mailing-List: contact users-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@subversion.apache.org Received: (qmail 49985 invoked by uid 99); 7 Aug 2012 18:50:58 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Aug 2012 18:50:58 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of blair@orcaware.com designates 108.0.197.17 as permitted sender) Received: from [108.0.197.17] (HELO orca4.orcaware.com) (108.0.197.17) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Aug 2012 18:50:52 +0000 Received: from orca4.orcaware.com (localhost [127.0.0.1]) by orca4.orcaware.com (8.14.4/8.14.4/Debian-2ubuntu2) with ESMTP id q77IoLM0001194; Tue, 7 Aug 2012 11:50:21 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=orcaware.com; s=default; t=1344365422; bh=8nHHxqwbvvelnv6CZ6TyiyP74TTkW29cuQ9n8Czhu+w=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=wys5q43SOmzOpkhlxkNY7Bp1Xfl2o+jEvaqZMlyUj0yfCsuzga8qHJ+su3ID6dE6v uem7viAz236uUHZcfyyJbqJAPa42tk+tbYpql3C/UYT28bxRkMiX02jRm5sL3oDPvP dPqPsomyskM9K5JsnSyQf6iMeiUy+7f5q9GrDRFc= Message-ID: <5021636D.80103@orcaware.com> Date: Tue, 07 Aug 2012 11:50:21 -0700 From: Blair Zajac User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120714 Thunderbird/14.0 MIME-Version: 1.0 To: Ryan Schmidt CC: Subodh Singh , Subversion Users Subject: Re: How to stop delete files/directory from SVN Repo Browser References: <000b01cd739c$b1b78820$15269860$@singh@proficientinfosoft.com> <030551E2-5362-4E78-8116-7E21E5B876A1@ryandesign.com> <001001cd747b$22dbec10$6893c430$@singh@proficientinfosoft.com> <3B889F4D-A359-4FAD-ABEF-B0C3F8604167@ryandesign.com> In-Reply-To: <3B889F4D-A359-4FAD-ABEF-B0C3F8604167@ryandesign.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 08/07/2012 02:13 AM, Ryan Schmidt wrote: > > On Aug 7, 2012, at 04:00, Subodh Singh wrote: > >> Ryan Schmidt wrote: >> >>> On Aug 6, 2012, at 01:28, Subodh Singh wrote: >>> >>>> I am new to SVN Repository. I need help to stop deletion of >>> files/directory from Repo Browser, so that user can't commit if any delete >>> operation is occurred. I can get this information using svnlook but after >>> commit. I need to catch any delete action before commit. I tried it using >>> svn hooks but not able to do so. Please guide me. >>> >>> It should definitely be possible to write a pre-commit hook to do this. >> >> Dear Ryan, >> >> Thanks for reply. Problem is that I tried it to do with svn pre-commit hook >> but not able to catch delete action. If you have any script for this then >> kindly send it to me. > > I'm sorry, I don't have time to write this script for you, but it should be easy to write. You'll use "svnlook changed -t" to inspect the incoming transaction, and look for any lines of output starting with "D" meaning "deleted". Note that by preventing deletes you also prevent moves, because in svn a 'svn mv A B' is the same as 'svn cp A B; svn rm A'. Blair