15 int fetch(unsigned char *sha1
)
17 if (has_sha1_file(sha1
))
19 write(fd_out
, sha1
, 20);
20 return write_sha1_from_fd(sha1
, fd_in
);
23 int main(int argc
, char **argv
)
29 while (arg
< argc
&& argv
[arg
][0] == '-') {
30 if (argv
[arg
][1] == 't') {
32 } else if (argv
[arg
][1] == 'c') {
34 } else if (argv
[arg
][1] == 'a') {
42 usage("rpull [-c] [-t] [-a] commit-id url");
45 commit_id
= argv
[arg
];
48 if (setup_connection(&fd_in
, &fd_out
, "rpush", url
, arg
, argv
+ 1))