summaryrefslogtreecommitdiff
path: root/Documentation
AgeCommit message (Collapse)AuthorFilesLines
2018-03-06Merge branch 'ms/non-ascii-ticks'Libravatar Junio C Hamano1-7/+7
Doc markup fix. * ms/non-ascii-ticks: Documentation/gitsubmodules.txt: avoid non-ASCII apostrophes
2018-03-06Merge branch 'bw/doc-submodule-recurse-config-with-clone'Libravatar Junio C Hamano1-1/+2
Doc update. * bw/doc-submodule-recurse-config-with-clone: submodule: indicate that 'submodule.recurse' doesn't apply to clone
2018-03-06Merge branch 'jc/allow-ff-merging-kept-tags'Libravatar Junio C Hamano1-1/+2
Since Git 1.7.9, "git merge" defaulted to --no-ff (i.e. even when the side branch being merged is a descendant of the current commit, create a merge commit instead of fast-forwarding) when merging a tag object. This was appropriate default for integrators who pull signed tags from their downstream contributors, but caused an unnecessary merges when used by downstream contributors who habitually "catch up" their topic branches with tagged releases from the upstream. Update "git merge" to default to --no-ff only when merging a tag object that does *not* sit at its usual place in refs/tags/ hierarchy, and allow fast-forwarding otherwise, to mitigate the problem. * jc/allow-ff-merging-kept-tags: merge: allow fast-forward when merging a tracked tag
2018-03-06Merge branch 'nd/rebase-show-current-patch'Libravatar Junio C Hamano2-2/+11
The new "--show-current-patch" option gives an end-user facing way to get the diff being applied when "git rebase" (and "git am") stops with a conflict. * nd/rebase-show-current-patch: rebase: introduce and use pseudo-ref REBASE_HEAD rebase: add --show-current-patch am: add --show-current-patch
2018-03-06Merge branch 'ab/fetch-prune'Libravatar Junio C Hamano4-7/+131
Clarify how configured fetch refspecs interact with the "--prune" option of "git fetch", and also add a handy short-hand for getting rid of stale tags that are locally held. * ab/fetch-prune: fetch: make the --prune-tags work with <url> fetch: add a --prune-tags option and fetch.pruneTags config fetch tests: add scaffolding for the new fetch.pruneTags git-fetch & config doc: link to the new PRUNING section git remote doc: correct dangerous lies about what prune does git fetch doc: add a new section to explain the ins & outs of pruning fetch tests: fetch <url> <spec> as well as fetch [<remote>] fetch tests: expand case/esac for later change fetch tests: double quote a variable for interpolation fetch tests: test --prune and refspec interaction fetch tests: add a tag to be deleted to the pruning tests fetch tests: re-arrange arguments for future readability fetch tests: refactor in preparation for testing tag pruning remote: add a macro for "refs/tags/*:refs/tags/*" fetch: stop accessing "remote" variable indirectly fetch: trivially refactor assignment to ref_nr fetch: don't redundantly NULL something calloc() gave us
2018-03-06Merge branch 'nm/tag-edit'Libravatar Junio C Hamano1-1/+7
"git tag" learned an explicit "--edit" option that allows the message given via "-m" and "-F" to be further edited. * nm/tag-edit: tag: add --edit option
2018-02-28Sixth batch for 2.17Libravatar Junio C Hamano1-5/+25
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-28Merge branch 'tg/worktree-create-tracking'Libravatar Junio C Hamano1-2/+3
Hotfix for a recent topic. * tg/worktree-create-tracking: git-worktree.txt: fix indentation of example and text of 'add' command git-worktree.txt: fix missing ")" typo
2018-02-28Merge branch 'sb/status-doc-fix'Libravatar Junio C Hamano1-2/+2
Docfix. * sb/status-doc-fix: Documentation/git-status: clarify status table for porcelain mode
2018-02-28Merge branch 'nd/am-quit'Libravatar Junio C Hamano1-1/+5
"git am" has learned the "--quit" option, in addition to the existing "--abort" option; having the pair mirrors a few other commands like "rebase" and "cherry-pick". * nd/am-quit: am: support --quit
2018-02-27Fifth batch for 2.17Libravatar Junio C Hamano1-10/+48
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-27Merge branch 'rd/typofix'Libravatar Junio C Hamano1-1/+1
Typofix. * rd/typofix: Correct mispellings of ".gitmodule" to ".gitmodules" t/: correct obvious typo "detahced"
2018-02-27Merge branch 'bp/fsmonitor'Libravatar Junio C Hamano1-2/+2
Doc update for a recently added feature. * bp/fsmonitor: fsmonitor: update documentation to remove reference to invalid config settings
2018-02-27Merge branch 'bc/doc-interpret-trailers-grammofix'Libravatar Junio C Hamano1-1/+1
Docfix. * bc/doc-interpret-trailers-grammofix: docs/interpret-trailers: fix agreement error
2018-02-27Merge branch 'jk/doc-do-not-write-extern'Libravatar Junio C Hamano1-0/+5
Devdoc update. * jk/doc-do-not-write-extern: CodingGuidelines: mention "static" and "extern"
2018-02-27Merge branch 'ab/untracked-cache-invalidation-docs'Libravatar Junio C Hamano1-0/+26
Doc update to warn against remaining bugs in untracked cache. * ab/untracked-cache-invalidation-docs: update-index doc: note the caveat with "could not open..." update-index doc: note a fixed bug in the untracked cache
2018-02-22Documentation/gitsubmodules.txt: avoid non-ASCII apostrophesLibravatar Motoki Seki1-7/+7
In gitsubmodules.txt, a few non-ASCII apostrophes are used to spell possessive, e.g. "submodule's". These unfortunately are not rendered at https://git-scm.com/docs/gitsubmodules correctly by the renderer used there. Use ASCII apostrophes instead to work around the problem. It also is good to be consistent, as there are possessives spelled with ASCII apostrophes. Signed-off-by: Motoki Seki <marmot.motoki@gmail.com> Acked-by: Stefan Beller <sbeller@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-21Fourth batch for 2.17Libravatar Junio C Hamano1-0/+12
2018-02-21Merge branch 'gs/rebase-allow-empty-message'Libravatar Junio C Hamano1-0/+5
"git rebase" learned to take "--allow-empty-message" option. * gs/rebase-allow-empty-message: rebase: add --allow-empty-message option
2018-02-21Merge branch 'lw/daemon-log-destination'Libravatar Junio C Hamano1-3/+25
The log from "git daemon" can be redirected with a new option; one relevant use case is to send the log to standard error (instead of syslog) when running it from inetd. * lw/daemon-log-destination: daemon: add --log-destination=(stderr|syslog|none)
2018-02-21submodule: indicate that 'submodule.recurse' doesn't apply to cloneLibravatar Brandon Williams1-1/+2
Update the documentation for the 'submodule.recurse' config to identify that the clone command does not respect it. Signed-off-by: Brandon Williams <bmwill@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-16git-worktree.txt: fix indentation of example and text of 'add' commandLibravatar Eric Sunshine1-0/+1
When 4e85333197 (worktree: make add <path> <branch> dwim, 2017-11-26) added an example command in a literal code block, it neglected to insert a mandatory "+" line before the block. This omission resulted in both the literal code block and the (existing) paragraph following the block to be outdented, even though they should be indented under the 'add' sub-command along with the rest of the text pertaining to that command. Furthermore, the mandatory "+" line separating the code block from the following text got rendered as a leading character on the line ("+ If <commit-ish>...") rather than being treated as a formatting directive. Fix these problems by adding the missing "+" line before the example code block. Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-16git-worktree.txt: fix missing ")" typoLibravatar Eric Sunshine1-2/+2
Add the closing ")" to a parenthetical phrase introduced by 4e85333197 (worktree: make add <path> <branch> dwim, 2017-11-26). While at it, add a missing ":" at the end of the same sentence since it precedes an example literal command block. Reported-by: Mike Nordell <tamlin.thefirst@gmail.com> Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-16merge: allow fast-forward when merging a tracked tagLibravatar Junio C Hamano1-1/+2
Long time ago at fab47d05 ("merge: force edit and no-ff mode when merging a tag object", 2011-11-07), "git merge" was made to always create a merge commit when merging a tag, even when the side branch being merged is a descendant of the current branch. This default is good for merges made by upstream maintainers to integrate work signed by downstream contributors, but will leave pointless no-ff merges when downstream contributors pull a newer release tag to make their long-running topic branches catch up with the upstream. When there is no local work left on the topic, such a merge should simply fast-forward to the commit pointed at by the release tag. Update the default (again) for "git merge" that merges a tag object to (1) --no-ff (i.e. create a merge commit even when side branch fast forwards) if the tag being merged is not at its expected place in refs/tags/ hierarchy and (2) --ff (i.e. allow fast-forward update when able) otherwise. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-15Sync with 2.16.2Libravatar Junio C Hamano1-0/+30
* tag 'v2.16.2': Git 2.16.2
2018-02-15Git 2.16.2Libravatar Junio C Hamano1-0/+30
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-15Merge branch 'ab/doc-cat-file-e-still-shows-errors' into maintLibravatar Junio C Hamano1-3/+4
Doc update. * ab/doc-cat-file-e-still-shows-errors: cat-file doc: document that -e will return some output
2018-02-15Merge branch 'as/read-tree-prefix-doc-fix' into maintLibravatar Junio C Hamano1-3/+2
Doc update. * as/read-tree-prefix-doc-fix: doc/read-tree: remove obsolete remark
2018-02-15Third batch for 2.17Libravatar Junio C Hamano1-0/+26
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-15Merge branch 'nd/ignore-glob-doc-update'Libravatar Junio C Hamano1-6/+5
Doc update. * nd/ignore-glob-doc-update: gitignore.txt: elaborate shell glob syntax
2018-02-15Merge branch 'po/object-id'Libravatar Junio C Hamano1-1/+1
Conversion from uchar[20] to struct object_id continues. * po/object-id: sha1_file: rename hash_sha1_file_literally sha1_file: convert write_loose_object to object_id sha1_file: convert force_object_loose to object_id sha1_file: convert write_sha1_file to object_id notes: convert write_notes_tree to object_id notes: convert combine_notes_* to object_id commit: convert commit_tree* to object_id match-trees: convert splice_tree to object_id cache: clear whole hash buffer with oidclr sha1_file: convert hash_sha1_file to object_id dir: convert struct sha1_stat to use object_id sha1_file: convert pretend_sha1_file to object_id
2018-02-15Documentation/git-status: clarify status table for porcelain modeLibravatar Stefan Beller1-2/+2
It is possible to have the output ' A' from 'git status --porcelain' by adding a file using the '--intend-to-add' flag. Make this clear by adding the pattern in the table of the documentation. However the mode 'DM' (deleted in the index, modified in the working tree) is not possible in the non-merge case in which the file only shows as 'D ' (and adding it back to the worktree would show an additional line of an '??' untracked file). It is also not possible in the merge case as then the mode involves a 'U' on one side of the merge. Remove that pattern. Reported-by: Ross Light <light@google.com> Signed-off-by: Stefan Beller <sbeller@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-14Correct mispellings of ".gitmodule" to ".gitmodules"Libravatar Robert P. J. Day1-1/+1
There are a small number of misspellings, ".gitmodule", scattered throughout the code base, correct them ... no apparent functional changes. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-14am: support --quitLibravatar Nguyễn Thái Ngọc Duy1-1/+5
Among the "in progress" commands, only git-am and git-merge do not support --quit. Support --quit in git-am too. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-14fsmonitor: update documentation to remove reference to invalid config settingsLibravatar Ben Peart1-2/+2
Remove the reference to setting core.fsmonitor to `true` (or `false`) as those are not valid settings. Signed-off-by: Ben Peart <benpeart@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-13Second batch for 2.17Libravatar Junio C Hamano1-0/+77
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-13Merge branch 'tz/doc-show-defaults-to-head'Libravatar Junio C Hamano1-2/+2
Doc update. * tz/doc-show-defaults-to-head: doc: mention 'git show' defaults to HEAD
2018-02-13Merge branch 'jt/long-running-process-doc'Libravatar Junio C Hamano3-46/+59
Doc updates. * jt/long-running-process-doc: Docs: split out long-running subprocess handshake
2018-02-13Merge branch 'jt/http-redact-cookies'Libravatar Junio C Hamano1-0/+10
The http tracing code, often used to debug connection issues, learned to redact potentially sensitive information from its output so that it can be more safely sharable. * jt/http-redact-cookies: http: support omitting data from traces http: support cookie redaction when tracing
2018-02-13Merge branch 'ks/submodule-doc-updates'Libravatar Junio C Hamano2-29/+87
Doc updates. * ks/submodule-doc-updates: Doc/git-submodule: improve readability and grammar of a sentence Doc/gitsubmodules: make some changes to improve readability and syntax
2018-02-13Merge branch 'jh/partial-clone'Libravatar Junio C Hamano3-0/+20
The machinery to clone & fetch, which in turn involves packing and unpacking objects, have been told how to omit certain objects using the filtering mechanism introduced by the jh/object-filtering topic, and also mark the resulting pack as a promisor pack to tolerate missing objects, taking advantage of the mechanism introduced by the jh/fsck-promisors topic. * jh/partial-clone: t5616: test bulk prefetch after partial fetch fetch: inherit filter-spec from partial clone t5616: end-to-end tests for partial clone fetch-pack: restore save_commit_buffer after use unpack-trees: batch fetching of missing blobs clone: partial clone partial-clone: define partial clone settings in config fetch: support filters fetch: refactor calculation of remote list fetch-pack: test support excluding large blobs fetch-pack: add --no-filter fetch-pack, index-pack, transport: partial clone upload-pack: add object filtering for partial clone
2018-02-13Merge branch 'jh/fsck-promisors'Libravatar Junio C Hamano4-0/+41
In preparation for implementing narrow/partial clone, the machinery for checking object connectivity used by gc and fsck has been taught that a missing object is OK when it is referenced by a packfile specially marked as coming from trusted repository that promises to make them available on-demand and lazily. * jh/fsck-promisors: gc: do not repack promisor packfiles rev-list: support termination at promisor objects sha1_file: support lazily fetching missing objects introduce fetch-object: fetch one promisor object index-pack: refactor writing of .keep files fsck: support promisor objects as CLI argument fsck: support referenced promisor objects fsck: support refs pointing to promisor objects fsck: introduce partialclone extension extension.partialclone: introduce partial clone extension
2018-02-13docs/interpret-trailers: fix agreement errorLibravatar brian m. carlson1-1/+1
In the description of git interpret-trailers, we describe "a group…of lines" that have certain characteristics. Ensure both options describing this group use a singular verb for parallelism. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-12rebase: introduce and use pseudo-ref REBASE_HEADLibravatar Nguyễn Thái Ngọc Duy1-1/+2
The new command `git rebase --show-current-patch` is useful for seeing the commit related to the current rebase state. Some however may find the "git show" command behind it too limiting. You may want to increase context lines, do a diff that ignores whitespaces... For these advanced use cases, the user can execute any command they want with the new pseudo ref REBASE_HEAD. This also helps show where the stopped commit is from, which is hard to see from the previous patch which implements --show-current-patch. Helped-by: Tim Landscheidt <tim@tim-landscheidt.de> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-12rebase: add --show-current-patchLibravatar Nguyễn Thái Ngọc Duy1-1/+5
It is useful to see the full patch while resolving conflicts in a rebase. The only way to do it now is less .git/rebase-*/patch which could turn out to be a lot longer to type if you are in a linked worktree, or not at top-dir. On top of that, an ordinary user should not need to peek into .git directory. The new option is provided to examine the patch. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-12am: add --show-current-patchLibravatar Nguyễn Thái Ngọc Duy1-1/+5
Pointing the user to $GIT_DIR/rebase-apply may encourage them to mess around in there, which is not a good thing. With this, the user does not have to keep the path around somewhere (because after a couple of commands, the path may be out of scrollback buffer) when they need to look at the patch. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-09update-index doc: note the caveat with "could not open..."Libravatar Ævar Arnfjörð Bjarmason1-0/+10
Note the caveat where 2.17 is stricter about index validation potentially causing "could not open directory" warnings when git is upgraded. See the preceding "dir.c: stop ignoring opendir() error in open_cached_dir()" change. This caused some mayhem when I upgraded git to a version with this series at Booking.com, and other users have doubtless enabled the UC extension and are in for a surprise when they upgrade. Let's give them a headsup in the docs. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-09update-index doc: note a fixed bug in the untracked cacheLibravatar Ævar Arnfjörð Bjarmason1-0/+16
Document the bug tested for in my "status: add a failing test showing a core.untrackedCache bug" and fixed in Duy's "dir.c: fix missing dir invalidation in untracked code". Since this is very likely something others will encounter in the future on older versions, and it's not obvious how to fix it let's document both that it exists, and how to "fix" it with a one-off command. As noted in that commit, even though this bug gets the untracked cache into a bad state, we have not yet found a case where this is user visible, and thus it makes sense for these docs to focus on the symlink case only. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-09fetch: make the --prune-tags work with <url>Libravatar Ævar Arnfjörð Bjarmason1-15/+6
Make the new --prune-tags option work properly when git-fetch is invoked with a <url> parameter instead of a <remote name> parameter. This change is split off from the introduction of --prune-tags due to the relative complexity of munging the incoming argv, which is easier to review as a separate change. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-09fetch: add a --prune-tags option and fetch.pruneTags configLibravatar Ævar Arnfjörð Bjarmason3-1/+74
Add a --prune-tags option to git-fetch, along with fetch.pruneTags config option and a -P shorthand (-p is --prune). This allows for doing any of: git fetch -p -P git fetch --prune --prune-tags git fetch -p -P origin git fetch --prune --prune-tags origin Or simply: git config fetch.prune true && git config fetch.pruneTags true && git fetch Instead of the much more verbose: git fetch --prune origin 'refs/tags/*:refs/tags/*' '+refs/heads/*:refs/remotes/origin/*' Before this feature it was painful to support the use-case of pulling from a repo which is having both its branches *and* tags deleted regularly, and have our local references to reflect upstream. At work we create deployment tags in the repo for each rollout, and there's *lots* of those, so they're archived within weeks for performance reasons. Without this change it's hard to centrally configure such repos in /etc/gitconfig (on servers that are only used for working with them). You need to set fetch.prune=true globally, and then for each repo: git -C {} config --replace-all remote.origin.fetch "refs/tags/*:refs/tags/*" "^\+*refs/tags/\*:refs/tags/\*$" Now I can simply set fetch.pruneTags=true in /etc/gitconfig as well, and users running "git pull" will automatically get the pruning semantics I want. Even though "git remote" has corresponding "prune" and "update --prune" subcommands I'm intentionally not adding a corresponding prune-tags or "update --prune --prune-tags" mode to that command. It's advertised (as noted in my recent "git remote doc: correct dangerous lies about what prune does") as only modifying remote tracking references, whereas any --prune-tags option is always going to modify what from the user's perspective is a local copy of the tag, since there's no such thing as a remote tracking tag. Ideally add_prune_tags_to_fetch_refspec() would be something that would use ALLOC_GROW() to grow the 'fetch` member of the 'remote' struct. Instead I'm realloc-ing remote->fetch and adding the tag_refspec to the end. The reason is that parse_{fetch,push}_refspec which allocate the refspec (ultimately remote->fetch) struct are called many places that don't have access to a 'remote' struct. It would be hard to change all their callsites to be amenable to carry around the bookkeeping variables required for dynamic allocation. All the other callers of the API first incrementally construct the string version of the refspec in remote->fetch_refspec via add_fetch_refspec(), before finally calling parse_fetch_refspec() via some variation of remote_get(). It's less of a pain to deal with the one special case that needs to modify already constructed refspecs than to chase down and change all the other callsites. The API I'm adding is intentionally not generalized because if we add more of these we'd probably want to re-visit how this is done. See my "Re: [BUG] git remote prune removes local tags, depending on fetch config" (87po6ahx87.fsf@evledraar.gmail.com; https://public-inbox.org/git/87po6ahx87.fsf@evledraar.gmail.com/) for more background info. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>