From: Ben Walton Date: Wed, 24 Aug 2011 00:29:51 +0000 (-0400) Subject: Mark http-fetch without -a as deprecated X-Git-Tag: v1.7.7-rc1~45^2 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=a6c786fce8da4143ea8bb3ab41ce8531192c5126;p=git.git Mark http-fetch without -a as deprecated As the use of http-fetch without -a can create an object store that is invalid to the point where it cannot even be fsck'd, mark it as deprecated. A future release should change the default and then remove the option entirely. Signed-off-by: Ben Walton Signed-off-by: Junio C Hamano --- diff --git a/Documentation/git-http-fetch.txt b/Documentation/git-http-fetch.txt index 4d4207386..070cd1e6e 100644 --- a/Documentation/git-http-fetch.txt +++ b/Documentation/git-http-fetch.txt @@ -15,6 +15,9 @@ DESCRIPTION ----------- Downloads a remote git repository via HTTP. +*NOTE*: use of this command without -a is deprecated. The -a +behaviour will become the default in a future release. + OPTIONS ------- commit-id:: diff --git a/http-fetch.c b/http-fetch.c index 3af4c71bd..8c4c5d222 100644 --- a/http-fetch.c +++ b/http-fetch.c @@ -56,6 +56,10 @@ int main(int argc, const char **argv) commits = 1; } + if (get_all == 0) + warning("http-fetch: use without -a is deprecated.\n" + "In a future release, -a will become the default."); + if (argv[arg]) str_end_url_with_slash(argv[arg], &url);