aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar David Bremner <david@tethera.net>2014-04-12 13:30:32 -0300
committerGravatar David Bremner <david@tethera.net>2014-04-15 17:20:19 -0300
commitdd24fdd33a3c06b2c2ad6bcb8e7d18bc8442f51f (patch)
treea7f0b9217c0dad9c354cf0064f6eed7f302ded38
parenta63ca54b1f2453593519dd0e609e63878ef22056 (diff)
nmbug: mark repository as bare on clone
If a git repository is non-bare, and core.worktree is not set, git tries to deduce the worktree. This deduction is not always helpful, e.g. % git --git-dir=$HOME/.nmbug clean -f would likely delete most of the files in the current directory
-rwxr-xr-xdevel/nmbug/nmbug1
1 files changed, 1 insertions, 0 deletions
diff --git a/devel/nmbug/nmbug b/devel/nmbug/nmbug
index d6f5213a..b18ded7b 100755
--- a/devel/nmbug/nmbug
+++ b/devel/nmbug/nmbug
@@ -134,6 +134,7 @@ sub do_clone {
$repository, $tempwork) == 0
or die "'git clone' exited with nonzero value\n";
git ('config', '--unset', 'core.worktree');
+ git ('config', 'core.bare', 'true');
}
sub is_committed {