1#include "cache.h"
2#include "run-command.h"
34
int main(int argc, char **argv)
5{
6struct child_process cp;
7int nogit = 0;
89
setup_git_directory_gently(&nogit);
10if (nogit)
11die("No git repo found");
12if (!strcmp(argv[1], "--setup-work-tree")) {
13setup_work_tree();
14argv++;
15}
16memset(&cp, 0, sizeof(cp));
17cp.git_cmd = 1;
18cp.argv = (const char **)argv+1;
19return run_command(&cp);
20}