[Cmake-commits] CMake branch, next, updated. v2.8.6-1645-gae13f7e

Brad King brad.king at kitware.com
Mon Oct 24 10:42:25 EDT 2011


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  ae13f7e0233b867669f43a1aedafa3f47e9d0ffb (commit)
       via  b2d6adf1266554de222fd438e9501c1eb67b429a (commit)
       via  3d5869ca3c065c872d6365164b301d2f8d7e2b64 (commit)
      from  0896b316f6d03c65764aaf369d8a1d4e73a9ec20 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ae13f7e0233b867669f43a1aedafa3f47e9d0ffb
commit ae13f7e0233b867669f43a1aedafa3f47e9d0ffb
Merge: 0896b31 b2d6adf
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Mon Oct 24 10:42:22 2011 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Oct 24 10:42:22 2011 -0400

    Merge topic 'local-hooks' into next
    
    b2d6adf pre-commit: Reject changes to KWSys through Git
    3d5869c Add pre-commit|commit-msg|prepare-commit-msg hook placeholders


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=b2d6adf1266554de222fd438e9501c1eb67b429a
commit b2d6adf1266554de222fd438e9501c1eb67b429a
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Mon Oct 24 10:36:15 2011 -0400
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Mon Oct 24 10:40:59 2011 -0400

    pre-commit: Reject changes to KWSys through Git
    
    Explain in the rejection message why KWSys cannot be changed in Git.

diff --git a/Utilities/Git/pre-commit b/Utilities/Git/pre-commit
index e4f9fd0..110e9ee 100755
--- a/Utilities/Git/pre-commit
+++ b/Utilities/Git/pre-commit
@@ -19,5 +19,29 @@ die() {
   exit 1
 }
 
-# This is a placeholder for future pre-commit checks.
-exit 0
+if test -z "$HOOKS_ALLOW_KWSYS"; then
+  # Disallow changes to KWSys
+  files=$(git diff-index --name-only --cached HEAD -- Source/kwsys) &&
+  if test -n "$files"; then
+    die 'Changes to KWSys files
+
+'"$(echo "$files" | sed 's/^/  /')"'
+
+cannot be committed through Git.  KWSys is kept in a CVS repository
+shared by several projects.  A robot replays changes committed there
+into the Source/kwsys directory in CMake.  Please send changes to
+this directory separately.  Run
+
+  git reset HEAD -- Source/kwsys
+
+to unstage these changes and then
+
+  git diff -- Source/kwsys > kwsys.patch
+
+to construct the patch.  Alternatively, set environment variable
+
+  HOOKS_ALLOW_KWSYS=1
+
+to disable this check and commit the changes locally.'
+  fi
+fi

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=3d5869ca3c065c872d6365164b301d2f8d7e2b64
commit 3d5869ca3c065c872d6365164b301d2f8d7e2b64
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Mon Oct 24 10:18:36 2011 -0400
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Mon Oct 24 10:18:36 2011 -0400

    Add pre-commit|commit-msg|prepare-commit-msg hook placeholders
    
    Add CMake-specific hook placeholders that chain from the main hooks
    branch after it is installed into the local .git/hooks directory.

diff --git a/.gitattributes b/.gitattributes
index 43676a9..d9d64d6 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -1,4 +1,5 @@
 .gitattributes   export-ignore
+.hooks*          export-ignore
 
 bootstrap        crlf=input
 configure        crlf=input
diff --git a/.hooks-config.bash b/.hooks-config.bash
new file mode 100644
index 0000000..97152f6
--- /dev/null
+++ b/.hooks-config.bash
@@ -0,0 +1,18 @@
+#=============================================================================
+# CMake - Cross Platform Makefile Generator
+# Copyright 2000-2011 Kitware, Inc., Insight Software Consortium
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+
+# Loaded by .git/hooks/(pre-commit|commit-msg|prepare-commit-msg)
+# during git commit after local hooks have been installed.
+
+hooks_chain_pre_commit="Utilities/Git/pre-commit"
+hooks_chain_commit_msg="Utilities/Git/commit-msg"
+hooks_chain_prepare_commit_msg="Utilities/Git/prepare-commit-msg"
diff --git a/Utilities/Git/commit-msg b/Utilities/Git/commit-msg
new file mode 100755
index 0000000..9a5d1c1
--- /dev/null
+++ b/Utilities/Git/commit-msg
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+#=============================================================================
+# CMake - Cross Platform Makefile Generator
+# Copyright 2000-2011 Kitware, Inc., Insight Software Consortium
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+
+die() {
+  echo 'commit-msg hook failure' 1>&2
+  echo '-----------------------' 1>&2
+  echo '' 1>&2
+  echo "$@" 1>&2
+  exit 1
+}
+
+# This is a placeholder for future commit-msg checks.
+exit 0
diff --git a/Utilities/Git/pre-commit b/Utilities/Git/pre-commit
new file mode 100755
index 0000000..e4f9fd0
--- /dev/null
+++ b/Utilities/Git/pre-commit
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+#=============================================================================
+# CMake - Cross Platform Makefile Generator
+# Copyright 2000-2011 Kitware, Inc., Insight Software Consortium
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+
+die() {
+  echo 'pre-commit hook failure' 1>&2
+  echo '-----------------------' 1>&2
+  echo '' 1>&2
+  echo "$@" 1>&2
+  exit 1
+}
+
+# This is a placeholder for future pre-commit checks.
+exit 0
diff --git a/Utilities/Git/prepare-commit-msg b/Utilities/Git/prepare-commit-msg
new file mode 100755
index 0000000..1517bb2
--- /dev/null
+++ b/Utilities/Git/prepare-commit-msg
@@ -0,0 +1,15 @@
+#!/usr/bin/env bash
+#=============================================================================
+# CMake - Cross Platform Makefile Generator
+# Copyright 2000-2011 Kitware, Inc., Insight Software Consortium
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+
+# This is a placeholder for future prepare-commit-msg hooks.
+exit 0

-----------------------------------------------------------------------

Summary of changes:
 .gitattributes                                     |    1 +
 DartConfig.cmake => .hooks-config.bash             |   14 +++---
 DartConfig.cmake => Utilities/Git/commit-msg       |   19 +++++---
 Utilities/Git/pre-commit                           |   47 ++++++++++++++++++++
 .../Git/prepare-commit-msg                         |   10 ++--
 5 files changed, 72 insertions(+), 19 deletions(-)
 copy DartConfig.cmake => .hooks-config.bash (58%)
 copy DartConfig.cmake => Utilities/Git/commit-msg (63%)
 mode change 100644 => 100755
 create mode 100755 Utilities/Git/pre-commit
 copy Modules/FLTKCompatibility.cmake => Utilities/Git/prepare-commit-msg (70%)
 mode change 100644 => 100755


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list