diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2012-12-27 17:07:35 +0100 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-12-28 12:04:29 -0400 |
commit | e5742f7ae353f9a675e13fc0b951daeeff82bdae (patch) | |
tree | 8c4ca9333a2bc54b49bd2704d8e18d131c0aecc1 /etckeeper | |
parent | 96d7d866cbd9b3b534e1e9562793f452bb5f922f (diff) |
Auto-detect the VCS setting if there already is a repository in /etc.
Diffstat (limited to 'etckeeper')
-rwxr-xr-x | etckeeper | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -16,6 +16,16 @@ if [ -e $conf ]; then . $conf fi +if [ -d ".git" ]; then + VCS=git +elif [ -d ".hg" ]; then + VCS=hg +elif [ -d "_darcs" ]; then + VCS=darcs +elif [ -d ".bzr" ]; then + VCS=bzr +fi + if [ -z "$VCS" ]; then echo "Please configure a VCS in $conf" >&2 exit 1 |