print unlink(2) errno in copy_or_link_directory
[git] / update-server-info.c
1 #include "cache.h"
2 #include "exec_cmd.h"
3
4 static const char update_server_info_usage[] =
5 "git update-server-info [--force]";
6
7 int main(int ac, char **av)
8 {
9         int i;
10         int force = 0;
11         for (i = 1; i < ac; i++) {
12                 if (av[i][0] == '-') {
13                         if (!strcmp("--force", av[i]) ||
14                             !strcmp("-f", av[i]))
15                                 force = 1;
16                         else
17                                 usage(update_server_info_usage);
18                 }
19         }
20         if (i != ac)
21                 usage(update_server_info_usage);
22
23         git_extract_argv0_path(av[0]);
24
25         setup_git_directory();
26
27         return !!update_server_info(force);
28 }