diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-04-21 20:43:52 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-04-21 20:43:52 (GMT) |
commit | 352f6115d475afa8d0246d24ba80ff6e0405aa55 (patch) | |
tree | 2237bc7d6b07c0bd33de5cb1400cce5886033e3c | |
parent | 427f6b307aa35fc921aa8d8538b8c653219bb065 (diff) | |
download | swift-contrib-352f6115d475afa8d0246d24ba80ff6e0405aa55.zip swift-contrib-352f6115d475afa8d0246d24ba80ff6e0405aa55.tar.bz2 |
Only install Git hooks if there is a git dir.
-rw-r--r-- | BuildTools/SCons/SConstruct | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/BuildTools/SCons/SConstruct b/BuildTools/SCons/SConstruct index 70f89de..e1e8e24 100644 --- a/BuildTools/SCons/SConstruct +++ b/BuildTools/SCons/SConstruct @@ -360,8 +360,9 @@ elif env.get("bonjour", False) : # Set up git hooks ################################################################################ -if not env.GetOption("clean") : - env.Install("#/.git/hooks", Glob("#/BuildTools/Git/Hooks/*")) +if env.Dir("#/.git").exists() : + if not env.GetOption("clean") : + env.Install("#/.git/hooks", Glob("#/BuildTools/Git/Hooks/*")) ################################################################################ # Project files |