| 1 | #!@BASH@ |
|---|
| 2 | # |
|---|
| 3 | # Copyright (c) 2008, Christopher Cowart and contributors |
|---|
| 4 | # All rights reserved. |
|---|
| 5 | # |
|---|
| 6 | # Redistribution and use in source and binary forms, with or without |
|---|
| 7 | # modification, are permitted provided that the following conditions |
|---|
| 8 | # are met: |
|---|
| 9 | # * Redistributions of source code must retain the above copyright |
|---|
| 10 | # notice, this list of conditions and the following disclaimer. |
|---|
| 11 | # * Redistributions in binary form must reproduce the above copyright |
|---|
| 12 | # notice, this list of conditions and the following disclaimer in the |
|---|
| 13 | # documentation and/or other materials provided with the distribution. |
|---|
| 14 | # |
|---|
| 15 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
|---|
| 16 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
|---|
| 17 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
|---|
| 18 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
|---|
| 19 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
|---|
| 20 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED |
|---|
| 21 | # TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR |
|---|
| 22 | # PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF |
|---|
| 23 | # LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING |
|---|
| 24 | # NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
|---|
| 25 | # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
|---|
| 26 | # |
|---|
| 27 | # $Id: confsync.in 550 2011-12-16 22:17:49Z blee $ |
|---|
| 28 | # |
|---|
| 29 | # This script is meant to be set up as a pre-commit hook for the confman |
|---|
| 30 | # repository. |
|---|
| 31 | |
|---|
| 32 | REPOS="$1" |
|---|
| 33 | TXN="$2" |
|---|
| 34 | |
|---|
| 35 | SVNLOOK=@SVNLOOK@ |
|---|
| 36 | |
|---|
| 37 | version=$($SVNLOOK propget -t "$TXN" --revprop "$REPOS" confman:version) |
|---|
| 38 | |
|---|
| 39 | if [ -n "$version" ] ; then |
|---|
| 40 | exit 0 |
|---|
| 41 | fi |
|---|
| 42 | |
|---|
| 43 | echo "confman client version verification failed." >&2 |
|---|
| 44 | exit 1 |
|---|