summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--describe.c2
-rw-r--r--git.c2
-rw-r--r--merge-tree.c2
3 files changed, 5 insertions, 1 deletions
diff --git a/describe.c b/describe.c
index 5dd8b2e397..5ed052d3a1 100644
--- a/describe.c
+++ b/describe.c
@@ -161,6 +161,8 @@ int main(int argc, char **argv)
usage(describe_usage);
}
+ setup_git_directory();
+
if (i == argc)
describe("HEAD", 1);
else
diff --git a/git.c b/git.c
index 335f405c20..47c85e10d1 100644
--- a/git.c
+++ b/git.c
@@ -224,7 +224,7 @@ static void handle_internal_command(int argc, const char **argv, char **envp)
{ "checkout-index", cmd_checkout_index, RUN_SETUP },
{ "check-ref-format", cmd_check_ref_format },
{ "commit-tree", cmd_commit_tree, RUN_SETUP },
- { "count-objects", cmd_count_objects },
+ { "count-objects", cmd_count_objects, RUN_SETUP },
{ "diff", cmd_diff, RUN_SETUP },
{ "diff-files", cmd_diff_files, RUN_SETUP },
{ "diff-index", cmd_diff_index, RUN_SETUP },
diff --git a/merge-tree.c b/merge-tree.c
index 60df758c41..c154dcfc02 100644
--- a/merge-tree.c
+++ b/merge-tree.c
@@ -340,6 +340,8 @@ int main(int argc, char **argv)
if (argc < 4)
usage(merge_tree_usage);
+ setup_git_directory();
+
buf1 = get_tree_descriptor(t+0, argv[1]);
buf2 = get_tree_descriptor(t+1, argv[2]);
buf3 = get_tree_descriptor(t+2, argv[3]);