diff options
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/RelNotes/2.22.0.txt | 21 | ||||
-rw-r--r-- | Documentation/config/trace2.txt | 18 | ||||
-rw-r--r-- | Documentation/git-pull.txt | 5 | ||||
-rw-r--r-- | Documentation/git-rebase.txt | 5 | ||||
-rw-r--r-- | Documentation/git.txt | 53 | ||||
-rw-r--r-- | Documentation/gitsubmodules.txt | 14 | ||||
-rw-r--r-- | Documentation/merge-options.txt | 2 | ||||
-rw-r--r-- | Documentation/rev-list-options.txt | 7 | ||||
-rw-r--r-- | Documentation/technical/api-trace2.txt | 46 |
9 files changed, 106 insertions, 65 deletions
diff --git a/Documentation/RelNotes/2.22.0.txt b/Documentation/RelNotes/2.22.0.txt index cdfdabe7d9..91e6ae9887 100644 --- a/Documentation/RelNotes/2.22.0.txt +++ b/Documentation/RelNotes/2.22.0.txt @@ -4,6 +4,13 @@ Git 2.22 Release Notes Updates since v2.21 ------------------- +Backward compatibility note + + * The filter specification "--filter=sparse:path=<path>" used to + create a lazy/partial clone has been removed. Using a blob that is + part of the project as sparse specification is still supported with + the "--filter=sparse:oid=<blob>" option. + UI, Workflows & Features * "git checkout --no-overlay" can be used to trigger a new mode of @@ -181,7 +188,7 @@ Performance, Internal Implementation, Development Support etc. been optimized out. * Mechanically and systematically drop "extern" from function - declarlation. + declaration. * The script to aggregate perf result unconditionally depended on libjson-perl even though it did not have to, which has been @@ -270,7 +277,7 @@ Fixes since v2.21 * On platforms where "git fetch" is killed with SIGPIPE (e.g. OSX), the upload-pack that runs on the other end that hangs up after detecting an error could cause "git fetch" to die with a signal, - which led to a flakey test. "git fetch" now ignores SIGPIPE during + which led to a flaky test. "git fetch" now ignores SIGPIPE during the network portion of its operation (this is not a problem as we check the return status from our write(2)s). (merge 143588949c jk/no-sigpipe-during-network-transport later to maint). @@ -358,7 +365,7 @@ Fixes since v2.21 (merge b5a0bd694c nd/read-tree-reset-doc later to maint). * Code clean-up around a much-less-important-than-it-used-to-be - update_server_info() funtion. + update_server_info() function. (merge b3223761c8 jk/server-info-rabbit-hole later to maint). * The message given when "git commit -a <paths>" errors out has been @@ -450,7 +457,7 @@ Fixes since v2.21 * When given a tag that points at a commit-ish, "git replace --graft" failed to peel the tag before writing a replace ref, which did not make sense because the old graft mechanism the feature wants to - mimick only allowed to replace one commit object with another. + mimic only allowed to replace one commit object with another. This has been fixed. (merge ee521ec4cb cc/replace-graft-peel-tags later to maint). @@ -500,7 +507,7 @@ Fixes since v2.21 conflicts are resolved in working tree *.h files but before the resolved results are added to the index. This has been corrected. - * "git chery-pick" (and "revert" that shares the same runtime engine) + * "git cherry-pick" (and "revert" that shares the same runtime engine) that deals with multiple commits got confused when the final step gets stopped with a conflict and the user concluded the sequence with "git commit". Attempt to fix it by cleaning up the state @@ -535,7 +542,7 @@ Fixes since v2.21 todo-list "rebase -i -r" uses should not be shown as a hex object name. - * A prerequiste check in the test suite to see if a working jgit is + * A prerequisite check in the test suite to see if a working jgit is available was made more robust. (merge abd0f28983 tz/test-lib-check-working-jgit later to maint). @@ -586,3 +593,5 @@ Fixes since v2.21 (merge 397a46db78 js/t5580-unc-alternate-test later to maint). (merge d4907720a2 cm/notes-comment-fix later to maint). (merge 9dde06de13 cb/http-push-null-in-message-fix later to maint). + (merge 4c785c0edc js/rebase-config-bitfix later to maint). + (merge 8e9fe16c87 es/doc-gitsubmodules-markup later to maint). diff --git a/Documentation/config/trace2.txt b/Documentation/config/trace2.txt index a5f409c1c1..2edbfb02fe 100644 --- a/Documentation/config/trace2.txt +++ b/Documentation/config/trace2.txt @@ -4,17 +4,17 @@ command line arguments are not respected. trace2.normalTarget:: This variable controls the normal target destination. - It may be overridden by the `GIT_TR2` environment variable. + It may be overridden by the `GIT_TRACE2` environment variable. The following table shows possible values. trace2.perfTarget:: This variable controls the performance target destination. - It may be overridden by the `GIT_TR2_PERF` environment variable. + It may be overridden by the `GIT_TRACE2_PERF` environment variable. The following table shows possible values. trace2.eventTarget:: This variable controls the event target destination. - It may be overridden by the `GIT_TR2_EVENT` environment variable. + It may be overridden by the `GIT_TRACE2_EVENT` environment variable. The following table shows possible values. + include::../trace2-target-values.txt[] @@ -22,22 +22,22 @@ include::../trace2-target-values.txt[] trace2.normalBrief:: Boolean. When true `time`, `filename`, and `line` fields are omitted from normal output. May be overridden by the - `GIT_TR2_BRIEF` environment variable. Defaults to false. + `GIT_TRACE2_BRIEF` environment variable. Defaults to false. trace2.perfBrief:: Boolean. When true `time`, `filename`, and `line` fields are omitted from PERF output. May be overridden by the - `GIT_TR2_PERF_BRIEF` environment variable. Defaults to false. + `GIT_TRACE2_PERF_BRIEF` environment variable. Defaults to false. trace2.eventBrief:: Boolean. When true `time`, `filename`, and `line` fields are omitted from event output. May be overridden by the - `GIT_TR2_EVENT_BRIEF` environment variable. Defaults to false. + `GIT_TRACE2_EVENT_BRIEF` environment variable. Defaults to false. trace2.eventNesting:: Integer. Specifies desired depth of nested regions in the event output. Regions deeper than this value will be - omitted. May be overridden by the `GIT_TR2_EVENT_NESTING` + omitted. May be overridden by the `GIT_TRACE2_EVENT_NESTING` environment variable. Defaults to 2. trace2.configParams:: @@ -45,7 +45,7 @@ trace2.configParams:: settings that should be recorded in the trace2 output. For example, `core.*,remote.*.url` would cause the trace2 output to contain events listing each configured remote. - May be overridden by the `GIT_TR2_CONFIG_PARAMS` environment + May be overridden by the `GIT_TRACE2_CONFIG_PARAMS` environment variable. Unset by default. trace2.destinationDebug:: @@ -53,4 +53,4 @@ trace2.destinationDebug:: trace target destination cannot be opened for writing. By default, these errors are suppressed and tracing is silently disabled. May be overridden by the - `GIT_TR2_DST_DEBUG` environment variable. + `GIT_TRACE2_DST_DEBUG` environment variable. diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt index 118d9d86f7..a5e9501a0a 100644 --- a/Documentation/git-pull.txt +++ b/Documentation/git-pull.txt @@ -112,8 +112,9 @@ When set to `merges`, rebase using `git rebase --rebase-merges` so that the local merge commits are included in the rebase (see linkgit:git-rebase[1] for details). + -When set to preserve, rebase with the `--preserve-merges` option passed -to `git rebase` so that locally created merge commits will not be flattened. +When set to `preserve` (deprecated in favor of `merges`), rebase with the +`--preserve-merges` option passed to `git rebase` so that locally created +merge commits will not be flattened. + When false, merge the current branch into the upstream branch. + diff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt index f5e6ae3907..5e4e927647 100644 --- a/Documentation/git-rebase.txt +++ b/Documentation/git-rebase.txt @@ -675,7 +675,8 @@ $ git rebase -i HEAD~5 And move the first patch to the end of the list. -You might want to preserve merges, if you have a history like this: +You might want to recreate merge commits, e.g. if you have a history +like this: ------------------ X @@ -689,7 +690,7 @@ Suppose you want to rebase the side branch starting at "A" to "Q". Make sure that the current HEAD is "B", and call ----------------------------- -$ git rebase -i -p --onto Q O +$ git rebase -i -r --onto Q O ----------------------------- Reordering and editing commits usually creates untested intermediate diff --git a/Documentation/git.txt b/Documentation/git.txt index 72adfcc5e2..6ddc1e2ca6 100644 --- a/Documentation/git.txt +++ b/Documentation/git.txt @@ -660,26 +660,53 @@ of clones and fetches. When a curl trace is enabled (see `GIT_TRACE_CURL` above), do not dump data (that is, only dump info lines and headers). -`GIT_TR2`:: +`GIT_TRACE2`:: Enables more detailed trace messages from the "trace2" library. - Output from `GIT_TR2` is a simple text-based format for human + Output from `GIT_TRACE2` is a simple text-based format for human readability. + -The `GIT_TR2` variables can take many values. Any value available to -the `GIT_TRACE` variables is also available to `GIT_TR2`. The `GIT_TR2` -variables can also specify a Unix Domain Socket. See -link:technical/api-trace2.html[Trace2 documentation] for full details. +If this variable is set to "1", "2" or "true" (comparison +is case insensitive), trace messages will be printed to +stderr. ++ +If the variable is set to an integer value greater than 2 +and lower than 10 (strictly) then Git will interpret this +value as an open file descriptor and will try to write the +trace messages into this file descriptor. ++ +Alternatively, if the variable is set to an absolute path +(starting with a '/' character), Git will interpret this +as a file path and will try to append the trace messages +to it. If the path already exists and is a directory, the +trace messages will be written to files (one per process) +in that directory, named according to the last component +of the SID and an optional counter (to avoid filename +collisions). ++ +In addition, if the variable is set to +`af_unix:[<socket_type>:]<absolute-pathname>`, Git will try +to open the path as a Unix Domain Socket. The socket type +can be either `stream` or `dgram`. ++ +Unsetting the variable, or setting it to empty, "0" or +"false" (case insensitive) disables trace messages. ++ +See link:technical/api-trace2.html[Trace2 documentation] +for full details. + -`GIT_TR2_EVENT`:: +`GIT_TRACE2_EVENT`:: This setting writes a JSON-based format that is suited for machine - interpretation. See link:technical/api-trace2.html[Trace2 documentation] - for full details. + interpretation. + See `GIT_TRACE2` for available trace output options and + link:technical/api-trace2.html[Trace2 documentation] for full details. -`GIT_TR2_PERF`:: - In addition to the text-based messages available in `GIT_TR2`, this +`GIT_TRACE2_PERF`:: + In addition to the text-based messages available in `GIT_TRACE2`, this setting writes a column-based format for understanding nesting - regions. See link:technical/api-trace2.html[Trace2 documentation] - for full details. + regions. + See `GIT_TRACE2` for available trace output options and + link:technical/api-trace2.html[Trace2 documentation] for full details. `GIT_REDACT_COOKIES`:: This can be set to a comma-separated list of strings. When a curl trace diff --git a/Documentation/gitsubmodules.txt b/Documentation/gitsubmodules.txt index 57999e9f36..0a890205b8 100644 --- a/Documentation/gitsubmodules.txt +++ b/Documentation/gitsubmodules.txt @@ -169,15 +169,15 @@ ACTIVE SUBMODULES A submodule is considered active, - a. if `submodule.<name>.active` is set to `true` + 1. if `submodule.<name>.active` is set to `true` + or - b. if the submodule's path matches the pathspec in `submodule.active` + 2. if the submodule's path matches the pathspec in `submodule.active` + or - c. if `submodule.<name>.url` is set. + 3. if `submodule.<name>.url` is set. and these are evaluated in this order. @@ -193,11 +193,11 @@ For example: url = https://example.org/baz In the above config only the submodule 'bar' and 'baz' are active, -'bar' due to (a) and 'baz' due to (c). 'foo' is inactive because -(a) takes precedence over (c) +'bar' due to (1) and 'baz' due to (3). 'foo' is inactive because +(1) takes precedence over (3) -Note that (c) is a historical artefact and will be ignored if the -(a) and (b) specify that the submodule is not active. In other words, +Note that (3) is a historical artefact and will be ignored if the +(1) and (2) specify that the submodule is not active. In other words, if we have a `submodule.<name>.active` set to `false` or if the submodule's path is excluded in the pathspec in `submodule.active`, the url doesn't matter whether it is present or not. This is illustrated in diff --git a/Documentation/merge-options.txt b/Documentation/merge-options.txt index 61876dbc33..79a00d2a4a 100644 --- a/Documentation/merge-options.txt +++ b/Documentation/merge-options.txt @@ -102,6 +102,8 @@ merge. + With --no-squash perform the merge and commit the result. This option can be used to override --squash. ++ +With --squash, --commit is not allowed, and will fail. -s <strategy>:: --strategy=<strategy>:: diff --git a/Documentation/rev-list-options.txt b/Documentation/rev-list-options.txt index ddbc1de43f..71a1fcc093 100644 --- a/Documentation/rev-list-options.txt +++ b/Documentation/rev-list-options.txt @@ -725,9 +725,6 @@ specification contained in the blob (or blob-expression) '<blob-ish>' to omit blobs that would not be not required for a sparse checkout on the requested refs. + -The form '--filter=sparse:path=<path>' similarly uses a sparse-checkout -specification contained in <path>. -+ The form '--filter=tree:<depth>' omits all blobs and trees whose depth from the root tree is >= <depth> (minimum depth if an object is located at multiple depths in the commits traversed). <depth>=0 will not include @@ -737,6 +734,10 @@ tree and blobs which are referenced directly by a commit reachable from <commit> or an explicitly-given object. <depth>=2 is like <depth>=1 while also including trees and blobs one more level removed from an explicitly-given commit or tree. ++ +Note that the form '--filter=sparse:path=<path>' that wants to read +from an arbitrary path on the filesystem has been dropped for security +reasons. --no-filter:: Turn off any previous `--filter=` argument. diff --git a/Documentation/technical/api-trace2.txt b/Documentation/technical/api-trace2.txt index 9e585b8e79..23c3cc7a37 100644 --- a/Documentation/technical/api-trace2.txt +++ b/Documentation/technical/api-trace2.txt @@ -23,7 +23,7 @@ formats in the future. This might be used to define a binary format, for example. Trace2 is controlled using `trace2.*` config values in the system and -global config files and `GIT_TR2*` environment variables. Trace2 does +global config files and `GIT_TRACE2*` environment variables. Trace2 does not read from repo local or worktree config files or respect `-c` command line config settings. @@ -42,7 +42,7 @@ config setting. For example ------------ -$ export GIT_TR2=~/log.normal +$ export GIT_TRACE2=~/log.normal $ git version git version 2.20.1.155.g426c96fcdb ------------ @@ -71,13 +71,13 @@ $ cat ~/log.normal The performance format target (PERF) is a column-based format to replace GIT_TRACE_PERFORMANCE and is suitable for development and testing, possibly to complement tools like gprof. This format is -enabled with the `GIT_TR2_PERF` environment variable or the +enabled with the `GIT_TRACE2_PERF` environment variable or the `trace2.perfTarget` system or global config setting. For example ------------ -$ export GIT_TR2_PERF=~/log.perf +$ export GIT_TRACE2_PERF=~/log.perf $ git version git version 2.20.1.155.g426c96fcdb ------------ @@ -104,14 +104,14 @@ $ cat ~/log.perf === The Event Format Target The event format target is a JSON-based format of event data suitable -for telemetry analysis. This format is enabled with the `GIT_TR2_EVENT` +for telemetry analysis. This format is enabled with the `GIT_TRACE2_EVENT` environment variable or the `trace2.eventTarget` system or global config setting. For example ------------ -$ export GIT_TR2_EVENT=~/log.event +$ export GIT_TRACE2_EVENT=~/log.event $ git version git version 2.20.1.155.g426c96fcdb ------------ @@ -273,7 +273,7 @@ significantly affects program performance or behavior, such as Emits a "def_param" messages for "important" configuration settings. + -The environment variable `GIT_TR2_CONFIG_PARAMS` or the `trace2.configParams` +The environment variable `GIT_TRACE2_CONFIG_PARAMS` or the `trace2.configParams` config value can be set to a list of patterns of important configuration settings, for example: `core.*,remote.*.url`. This function will iterate over all config @@ -465,7 +465,7 @@ Events are written as lines of the form: Note that this may contain embedded LF or CRLF characters that are not escaped, so the event may spill across multiple lines. -If `GIT_TR2_BRIEF` or `trace2.normalBrief` is true, the `time`, `filename`, +If `GIT_TRACE2_BRIEF` or `trace2.normalBrief` is true, the `time`, `filename`, and `line` fields are omitted. This target is intended to be more of a summary (like GIT_TRACE) and @@ -533,7 +533,7 @@ This field is in anticipation of in-proc submodules in the future. 15:33:33.532712 wt-status.c:2331 | d0 | main | region_leave | r1 | 0.127568 | 0.001504 | status | label:print ------------ -If `GIT_TR2_PERF_BRIEF` or `trace2.perfBrief` is true, the `time`, `file`, +If `GIT_TRACE2_PERF_BRIEF` or `trace2.perfBrief` is true, the `time`, `file`, and `line` fields are omitted. ------------ @@ -598,7 +598,7 @@ The following key/value pairs are common to all events: `"repo":<repo-id>`:: when present, is the integer repo-id as described previously. -If `GIT_TR2_EVENT_BRIEF` or `trace2.eventBrief` is true, the `file` +If `GIT_TRACE2_EVENT_BRIEF` or `trace2.eventBrief` is true, the `file` and `line` fields are omitted from all events and the `time` field is only present on the "start" and "atexit" events. @@ -911,7 +911,7 @@ visited. The `category` field may be used in a future enhancement to do category-based filtering. + -`GIT_TR2_EVENT_NESTING` or `trace2.eventNesting` can be used to +`GIT_TRACE2_EVENT_NESTING` or `trace2.eventNesting` can be used to filter deeply nested regions and data events. It defaults to "2". `"region_leave"`:: @@ -1039,8 +1039,8 @@ rev-list, and gc. This example also shows that fetch took 5.199 seconds and of that 4.932 was in ssh. + ---------------- -$ export GIT_TR2_BRIEF=1 -$ export GIT_TR2=~/log.normal +$ export GIT_TRACE2_BRIEF=1 +$ export GIT_TRACE2=~/log.normal $ git fetch origin ... ---------------- @@ -1075,8 +1075,8 @@ its name as "gc", it also reports the hierarchy as "fetch/gc". indented for clarity.) + ---------------- -$ export GIT_TR2_BRIEF=1 -$ export GIT_TR2=~/log.normal +$ export GIT_TRACE2_BRIEF=1 +$ export GIT_TRACE2=~/log.normal $ git fetch origin ... ---------------- @@ -1134,8 +1134,8 @@ In this example, scanning for untracked files ran from +0.012568 to +0.027149 (since the process started) and took 0.014581 seconds. + ---------------- -$ export GIT_TR2_PERF_BRIEF=1 -$ export GIT_TR2_PERF=~/log.perf +$ export GIT_TRACE2_PERF_BRIEF=1 +$ export GIT_TRACE2_PERF=~/log.perf $ git status ... @@ -1180,8 +1180,8 @@ static enum path_treatment read_directory_recursive(struct dir_struct *dir, We can further investigate the time spent scanning for untracked files. + ---------------- -$ export GIT_TR2_PERF_BRIEF=1 -$ export GIT_TR2_PERF=~/log.perf +$ export GIT_TRACE2_PERF_BRIEF=1 +$ export GIT_TRACE2_PERF=~/log.perf $ git status ... $ cat ~/log.perf @@ -1236,8 +1236,8 @@ int read_index_from(struct index_state *istate, const char *path, This example shows that the index contained 3552 entries. + ---------------- -$ export GIT_TR2_PERF_BRIEF=1 -$ export GIT_TR2_PERF=~/log.perf +$ export GIT_TRACE2_PERF_BRIEF=1 +$ export GIT_TRACE2_PERF=~/log.perf $ git status ... $ cat ~/log.perf @@ -1310,8 +1310,8 @@ Data events are tagged with the active thread name. They are used to report the per-thread parameters. + ---------------- -$ export GIT_TR2_PERF_BRIEF=1 -$ export GIT_TR2_PERF=~/log.perf +$ export GIT_TRACE2_PERF_BRIEF=1 +$ export GIT_TRACE2_PERF=~/log.perf $ git status ... $ cat ~/log.perf |