diff options
author | Torsten Bögershausen <tboegi@web.de> | 2013-11-28 20:49:17 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-12-09 14:54:47 -0800 |
commit | 5610b7c0c6957cf0b236b6fac087c1f4dc209376 (patch) | |
tree | 1557e893eea7c730ff382ff1777af192c403ca67 /connect.h | |
parent | cabc3c12e40f5556bb4de934ab783d53e908e401 (diff) | |
download | git-5610b7c0c6957cf0b236b6fac087c1f4dc209376.tar.gz git-5610b7c0c6957cf0b236b6fac087c1f4dc209376.tar.xz |
git fetch-pack: add --diag-url
The main purpose is to trace the URL parser called by git_connect() in
connect.c
The main features of the parser can be listed as this:
- parse out host and path for URLs with a scheme (git:// file:// ssh://)
- parse host names embedded by [] correctly
- extract the port number, if present
- separate URLs like "file" (which are local)
from URLs like "host:repo" which should use ssh
Add the new parameter "--diag-url" to "git fetch-pack", which prints
the value for protocol, host and path to stderr and exits.
Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'connect.h')
-rw-r--r-- | connect.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -2,6 +2,7 @@ #define CONNECT_H #define CONNECT_VERBOSE (1u << 0) +#define CONNECT_DIAG_URL (1u << 1) extern struct child_process *git_connect(int fd[2], const char *url, const char *prog, int flags); extern int finish_connect(struct child_process *conn); extern int git_connection_is_socket(struct child_process *conn); |