Re: [PATCH v2 1/3] git-fetch.txt: document fetch output
On Fri, Jun 03, 2016 at 06:08:41PM +0700, Nguyễn Thái Ngọc Duy wrote: > This patch is a copy from git-push.txt, modified a bit because the > flag '-' means different things in push (delete) and fetch (tag > update). We probably should unify the documents at some point in > future. This is stderr output from a porcelain. I don't think we make any promises about the format, and since we're changing other bits, perhaps now is a good time to unify the "-" handling. > +The status of the push is output in tabular form, with each line > +representing the status of a single ref. Each line is of the form: Like Marc, I wondered what this means. :) I know that there have been different status outputs from transport.c and fetch.c in the past, but I thought we had unified a lot of that. If we haven't, it seems like a good time to do so (and I'd prefer fixing to documenting quirks, when it's something that isn't plumbing). -Peff -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 1/3] git-fetch.txt: document fetch output
On 2016-06-03 07:08 AM, Nguyễn Thái Ngọc Duy wrote: This documents the ref update status of fetch. The structure of this output is defined in [1]. The ouput content is refined a bit in [2] s/The ouput/The output/ [3] [4]. This patch is a copy from git-push.txt, modified a bit because the flag '-' means different things in push (delete) and fetch (tag update). We probably should unify the documents at some point in future. PS. For code archaeologists, the discussion mentioned in [1] is probably [5]. [1] 165f390 (git-fetch: more terse fetch output - 2007-11-03) [2] 6315472 (fetch: report local storage errors ... - 2008-06-26) [3] f360d84 (builtin-fetch: add --prune option - 2009-11-10) [4] 0997ada (fetch: describe new refs based on where... - 2012-04-16) [5] http://thread.gmane.org/gmane.comp.version-control.git/61657 --- Documentation/git-fetch.txt | 46 + 1 file changed, 46 insertions(+) diff --git a/Documentation/git-fetch.txt b/Documentation/git-fetch.txt index efe56e0..18e733c 100644 --- a/Documentation/git-fetch.txt +++ b/Documentation/git-fetch.txt @@ -99,6 +99,52 @@ The latter use of the `remote..fetch` values can be overridden by giving the `--refmap=` parameter(s) on the command line. +OUTPUT +-- + +The output of "git fetch" depends on the transport method used; this What a mysterious statement! Does this tabular format actually change when fetching over HTTP? Maybe it's worth documenting the differences? +section describes the output when pushing over the Git protocol s/pushing/fetching/ +(either locally or via ssh). + +The status of the push is output in tabular form, with each line s/push/fetch/ +representing the status of a single ref. Each line is of the form: + +--- +-> () +--- + +The status of up-to-date refs is shown only if --verbose option is +used. + +flag:: + A single character indicating the status of the ref: +(space);; for a successfully fetched fast-forward; +`+`;; for a successful forced update; +`x`;; for a successfully deleted ref; I did a double-take here, until I remembered --prune. Maybe add "(when using the --prune option)"? M. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH v2 1/3] git-fetch.txt: document fetch output
This documents the ref update status of fetch. The structure of this output is defined in [1]. The ouput content is refined a bit in [2] [3] [4]. This patch is a copy from git-push.txt, modified a bit because the flag '-' means different things in push (delete) and fetch (tag update). We probably should unify the documents at some point in future. PS. For code archaeologists, the discussion mentioned in [1] is probably [5]. [1] 165f390 (git-fetch: more terse fetch output - 2007-11-03) [2] 6315472 (fetch: report local storage errors ... - 2008-06-26) [3] f360d84 (builtin-fetch: add --prune option - 2009-11-10) [4] 0997ada (fetch: describe new refs based on where... - 2012-04-16) [5] http://thread.gmane.org/gmane.comp.version-control.git/61657 --- Documentation/git-fetch.txt | 46 + 1 file changed, 46 insertions(+) diff --git a/Documentation/git-fetch.txt b/Documentation/git-fetch.txt index efe56e0..18e733c 100644 --- a/Documentation/git-fetch.txt +++ b/Documentation/git-fetch.txt @@ -99,6 +99,52 @@ The latter use of the `remote..fetch` values can be overridden by giving the `--refmap=` parameter(s) on the command line. +OUTPUT +-- + +The output of "git fetch" depends on the transport method used; this +section describes the output when pushing over the Git protocol +(either locally or via ssh). + +The status of the push is output in tabular form, with each line +representing the status of a single ref. Each line is of the form: + +--- +-> () +--- + +The status of up-to-date refs is shown only if --verbose option is +used. + +flag:: + A single character indicating the status of the ref: +(space);; for a successfully fetched fast-forward; +`+`;; for a successful forced update; +`x`;; for a successfully deleted ref; +`-`;; for a successful tag update; +`*`;; for a successfully fetched new ref; +`!`;; for a ref that was rejected or failed to update; and +`=`;; for a ref that was up to date and did not need fetching. + +summary:: + For a successfully fetched ref, the summary shows the old and new + values of the ref in a form suitable for using as an argument to + `git log` (this is `..` in most cases, and + `...` for forced non-fast-forward updates). + +from:: + The name of the remote ref being fetched from, minus its + `refs//` prefix. In the case of deletion, the name of + the remote ref is "(none)". + +to:: + The name of the local ref being updated, minus its + `refs//` prefix. + +reason:: + A human-readable explanation. In the case of successfully fetched + refs, no explanation is needed. For a failed ref, the reason for + failure is described. EXAMPLES -- 2.8.2.524.g6ff3d78 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html