Re: [PATCH v4 4/5] doc: git-push: clarify "what to push"
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Sep 30, 2025, 21:01 UTC
- Message-ID
- <xmqq4isj4pu1.fsf@gitster.g>
- In-Reply-To
- <c1d4ea8d27ff037fcc40c2c6dc1c4f0bd9000b1b.1759262314.git.gitgitgadget@gmail.com>
"Julia Evans via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 14 quoted lines
> +To decide which branches, tags, or other refs to push, Git uses > +(in order of precedence): > + > +1. The `<refspec>` argument(s) (for example `main` in `git push origin main`) > + or the `--all`, `--mirror`, or `--tags` options > +2. The `remote.*.push` configuration for the repository being pushed to > +3. The `push.default` configuration. The default is `push.default=simple`, > + which will push to a branch with the same name as the current branch. > + See the <<CONFIGURATION,CONFIGURATION>> section below for more on `push.default`. > + > +`git push` may fail if you haven't set an upstream for the current branch, > +depending on what `push.default` is set to. > +See the <<UPSTREAM-BRANCHES,UPSTREAM BRANCHES>> section below for more > +on how to set and use upstreams.
Reads well, does not tell any lies, and I like it.
Show 7 quoted lines
> @@ -696,7 +698,7 @@ a `git gc` command on the origin repository. > > include::transfer-data-leaks.adoc[] > > -CONFIGURATION > +CONFIGURATION[[CONFIGURATION]] > -------------
Looking at what we have in previous steps (e.g., post context of 1/5, the title of the new section in 2/5), I think you'd need to elongate the underline.