diff options
author | Junio C Hamano <junkio@cox.net> | 2005-11-26 00:50:02 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2005-11-28 23:13:02 -0800 |
commit | 53228a5fb8e80f87803e4a3ba8ed25b70fb4871d (patch) | |
tree | 0097d17996b5c71f3fb386eef354c84ffa3caaf2 /write-tree.c | |
parent | 5a3277133d200151fe526e56e036c933d343958a (diff) | |
download | git-53228a5fb8e80f87803e4a3ba8ed25b70fb4871d.tar.gz |
Make the rest of commands work from a subdirectory.
These commands are converted to run from a subdirectory.
commit-tree convert-objects merge-base merge-index mktag
pack-objects pack-redundant prune-packed read-tree tar-tree
unpack-file unpack-objects update-server-info write-tree
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'write-tree.c')
-rw-r--r-- | write-tree.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/write-tree.c b/write-tree.c index 2b2c6b77af..0aac32f227 100644 --- a/write-tree.c +++ b/write-tree.c @@ -86,9 +86,12 @@ static int write_tree(struct cache_entry **cachep, int maxentries, const char *b int main(int argc, char **argv) { int i, funny; - int entries = read_cache(); + int entries; unsigned char sha1[20]; + setup_git_directory(); + + entries = read_cache(); if (argc == 2) { if (!strcmp(argv[1], "--missing-ok")) missing_ok = 1; |