]>
Commit | Line | Data |
---|---|---|
85f08378 JH |
1 | Git v2.2 Release Notes |
2 | ====================== | |
3 | ||
4 | Updates since v2.1 | |
5 | ------------------ | |
6 | ||
0c72b98f JH |
7 | Ports |
8 | ||
9 | * Building on older MacOS X systems automatically sets | |
10 | the necessary NO_APPLE_COMMON_CRYPTO build-time option. | |
11 | ||
a2b450d6 | 12 | * Building with NO_PTHREADS has been resurrected. |
fbecd998 | 13 | |
a2b450d6 MB |
14 | * Compilation options have been updated a bit to better support the |
15 | z/OS port. | |
5b509df0 | 16 | |
0c72b98f | 17 | |
85f08378 JH |
18 | UI, Workflows & Features |
19 | ||
a2b450d6 | 20 | * "git archive" learned to filter what gets archived with a pathspec. |
63a45136 | 21 | |
85f08378 JH |
22 | * "git config --edit --global" starts from a skeletal per-user |
23 | configuration file contents, instead of a total blank, when the | |
a2b450d6 MB |
24 | user does not already have any global config. This immediately |
25 | reduces the need to later ask "Have you forgotten to set | |
26 | core.user?", and we can add more to the template as we gain | |
27 | more experience. | |
85f08378 | 28 | |
0c72b98f JH |
29 | * "git stash list -p" used to be almost always a no-op because each |
30 | stash entry is represented as a merge commit. It learned to show | |
31 | the difference between the base commit version and the working tree | |
652e7593 | 32 | version, which is in line with what "git stash show" gives. |
85f08378 | 33 | |
97b8860c JH |
34 | * Sometimes users want to report a bug they experience on their |
35 | repository, but they are not at liberty to share the contents of | |
36 | the repository. "fast-export" was taught an "--anonymize" option | |
a2b450d6 | 37 | to replace blob contents, names of people, paths and log |
97b8860c JH |
38 | messages with bland and simple strings to help them. |
39 | ||
5b509df0 JH |
40 | * "git difftool" learned an option to stop feeding paths to the |
41 | diff backend when it exits with a non-zero status. | |
42 | ||
a2b450d6 | 43 | * "git grep" learned to paint (or not paint) partial matches on |
dd835216 | 44 | context lines when showing "grep -C<num>" output in color. |
4ace7ff4 | 45 | |
a2b450d6 MB |
46 | * "log --date=iso" uses a slight variant of the ISO 8601 format that is |
47 | more human readable. A new "--date=iso-strict" option gives | |
48 | datetime output that conforms more strictly. | |
97b8860c | 49 | |
5b509df0 JH |
50 | * The logic "git prune" uses is more resilient against various corner |
51 | cases. | |
52 | ||
97b8860c | 53 | * A broken reimplementation of Git could write an invalid index that |
a2b450d6 | 54 | records both stage #0 and higher-stage entries for the same path. |
97b8860c JH |
55 | We now notice and reject such an index, as there is no sensible |
56 | fallback (we do not know if the broken tool wanted to resolve and | |
a2b450d6 MB |
57 | forgot to remove the higher-stage entries, or if it wanted to unresolve |
58 | and forgot to remove the stage #0 entry). | |
97b8860c | 59 | |
a2b450d6 | 60 | * The temporary files "git mergetool" uses are renamed to avoid too |
19b5d50c JH |
61 | many dots in them (e.g. a temporary file for "hello.c" used to be |
62 | named e.g. "hello.BASE.4321.c" but now uses underscore instead, | |
652e7593 | 63 | e.g. "hello_BASE_4321.c", to allow us to have multiple variants). |
19b5d50c | 64 | |
652e7593 | 65 | * The temporary files "git mergetool" uses can be placed in a newly |
dd835216 | 66 | created temporary directory, instead of the current directory, by |
19b5d50c JH |
67 | setting the mergetool.writeToTemp configuration variable. |
68 | ||
5b509df0 JH |
69 | * "git mergetool" understands "--tool bc" now, as version 4 of |
70 | BeyondCompare can be driven the same way as its version 3 and it | |
652e7593 | 71 | feels awkward to say "--tool bc3" to run version 4. |
5b509df0 | 72 | |
d29e9c89 JH |
73 | * The "pre-receive" and "post-receive" hooks are no longer required |
74 | to consume their input fully (not following this requirement used | |
75 | to result in intermittent errors in "git push"). | |
76 | ||
a2b450d6 | 77 | * The pretty-format specifier "%d", which expands to " (tagname)" |
0bf7dd65 JH |
78 | for a tagged commit, gained a cousin "%D" that just gives the |
79 | "tagname" without frills. | |
97b8860c | 80 | |
63a45136 JH |
81 | * "git push" learned "--signed" push, that allows a push (i.e. |
82 | request to update the refs on the other side to point at a new | |
83 | history, together with the transmission of necessary objects) to be | |
84 | signed, so that it can be verified and audited, using the GPG | |
85 | signature of the person who pushed, that the tips of branches at a | |
86 | public repository really point the commits the pusher wanted to, | |
87 | without having to "trust" the server. | |
88 | ||
f745acb0 | 89 | * "git interpret-trailers" is a new filter to programmatically edit |
a2b450d6 | 90 | the tail end of the commit log messages, e.g. "Signed-off-by:". |
13da0fc0 JH |
91 | |
92 | * "git help everyday" shows the "Everyday Git in 20 commands or so" | |
652e7593 JH |
93 | document, whose contents have been updated to match more modern |
94 | Git practice. | |
13da0fc0 | 95 | |
a2b450d6 MB |
96 | * On the "git svn" front, work progresses to reduce memory consumption and |
97 | to improve handling of mergeinfo. | |
4ace7ff4 | 98 | |
13da0fc0 | 99 | |
652e7593 | 100 | Performance, Internal Implementation, Development Support etc. |
85f08378 | 101 | |
19b5d50c JH |
102 | * The API to manipulate the "refs" has been restructured to make it |
103 | more transactional, with the eventual goal to allow all-or-none | |
104 | atomic updates and migrating the storage to something other than | |
105 | the traditional filesystem based one (e.g. databases). | |
ce1d3a93 | 106 | |
670a3c1d JH |
107 | * The lockfile API and its users have been cleaned up. |
108 | ||
ce1d3a93 | 109 | * We no longer attempt to keep track of individual dependencies to |
a2b450d6 | 110 | the header files in the build procedure, relying instead on automated |
ce1d3a93 JH |
111 | dependency generation support from modern compilers. |
112 | ||
0c72b98f JH |
113 | * In tests, we have been using NOT_{MINGW,CYGWIN} test prerequisites |
114 | long before negated prerequisites e.g. !MINGW were invented. | |
115 | The former has been converted to the latter to avoid confusion. | |
116 | ||
a2b450d6 MB |
117 | * Optimized looking up a remote's configuration in a repository with very many |
118 | remotes defined. | |
85f08378 JH |
119 | |
120 | * There are cases where you lock and open to write a file, close it | |
a2b450d6 | 121 | to show the updated contents to an external processes, and then have |
652e7593 JH |
122 | to update the file again while still holding the lock; now the |
123 | lockfile API has support for such an access pattern. | |
85f08378 | 124 | |
ce1d3a93 JH |
125 | * The API to allocate the structure to keep track of commit |
126 | decoration has been updated to make it less cumbersome to use. | |
127 | ||
85f08378 | 128 | * An in-core caching layer to let us avoid reading the same |
a2b450d6 | 129 | configuration files several times has been added. A few commands |
ce1d3a93 | 130 | have been converted to use this subsystem. |
85f08378 JH |
131 | |
132 | * Various code paths have been cleaned up and simplified by using | |
a2b450d6 | 133 | the "strbuf", "starts_with()", and "skip_prefix()" APIs more. |
85f08378 | 134 | |
ce1d3a93 JH |
135 | * A few codepaths that died when large blobs that would not fit in |
136 | core are involved in their operation have been taught to punt | |
a2b450d6 | 137 | instead, by e.g. marking a too-large blob as not to be diffed. |
ce1d3a93 JH |
138 | |
139 | * A few more code paths in "commit" and "checkout" have been taught | |
140 | to repopulate the cache-tree in the index, to help speed up later | |
141 | "write-tree" (used in "commit") and "diff-index --cached" (used in | |
142 | "status"). | |
143 | ||
97b8860c | 144 | * A common programming mistake to assign the same short option name |
a2b450d6 | 145 | to two separate options is detected by the parse_options() API to help |
97b8860c JH |
146 | developers. |
147 | ||
d29e9c89 JH |
148 | * The code path to write out the packed-refs file has been optimized, |
149 | which especially matters in a repository with a large number of | |
150 | refs. | |
151 | ||
152 | * The check to see if a ref $F can be created by making sure no | |
153 | existing ref has $F/ as its prefix has been optimized, which | |
154 | especially matters in a repository with a large number of existing | |
155 | refs. | |
156 | ||
a2b450d6 | 157 | * "git fsck" was taught to check the contents of tag objects a bit more. |
d29e9c89 JH |
158 | |
159 | * "git hash-object" was taught a "--literally" option to help | |
160 | debugging. | |
161 | ||
63a45136 JH |
162 | * When running a required clean filter, we do not have to mmap the |
163 | original before feeding the filter. Instead, stream the file | |
164 | contents directly to the filter and process its output. | |
85f08378 | 165 | |
a2b450d6 MB |
166 | * The scripts in the test suite can be run with the "-x" option to show |
167 | a shell-trace of each command they run. | |
13da0fc0 | 168 | |
fbecd998 | 169 | * The "run-command" API learned to manage the argv and environment |
652e7593 | 170 | arrays for child process, alleviating the need for the callers to |
fbecd998 JH |
171 | allocate and deallocate them. |
172 | ||
5b509df0 | 173 | * Some people use AsciiDoctor, instead of AsciiDoc, to format our |
652e7593 | 174 | documentation set; the documentation has been adjusted to be usable |
a2b450d6 | 175 | by both, as AsciiDoctor is pickier than AsciiDoc about its input |
652e7593 | 176 | mark-up. |
5b509df0 | 177 | |
13da0fc0 | 178 | |
85f08378 JH |
179 | Also contains various documentation updates and code clean-ups. |
180 | ||
181 | ||
182 | Fixes since v2.1 | |
183 | ---------------- | |
184 | ||
0c72b98f JH |
185 | Unless otherwise noted, all the fixes since v2.1 in the maintenance |
186 | track are contained in this release (see the maintenance releases' | |
187 | notes for details). | |
188 | ||
85f08378 JH |
189 | * "git log --pretty/format=" with an empty format string did not |
190 | mean the more obvious "No output whatsoever" but "Use default | |
191 | format", which was counterintuitive. | |
85f08378 | 192 | |
0c72b98f | 193 | * "git -c section.var command" and "git -c section.var= command" |
a2b450d6 | 194 | should pass the configuration value differently (the former should be a |
0c72b98f | 195 | boolean true, the latter should be an empty string). |
85f08378 | 196 | |
0c72b98f | 197 | * Applying a patch not generated by Git in a subdirectory used to |
a2b450d6 | 198 | check for whitespace breakage using the attributes of incorrect |
0c72b98f | 199 | paths. Also whitespace checks were performed even for paths |
a2b450d6 | 200 | excluded via the "git apply --exclude=<path>" mechanism. |
0c72b98f | 201 | |
a2b450d6 | 202 | * "git bundle create" with a date-range specification was meant to |
0c72b98f | 203 | exclude tags outside the range, but it didn't. |
0c72b98f | 204 | |
a2b450d6 | 205 | * "git add x" where x used to be a directory and is now a |
0c72b98f | 206 | symbolic link to a directory misbehaved. |
0c72b98f | 207 | |
a2b450d6 | 208 | * The prompt script checked the $GIT_DIR/ref/stash file to see if there |
0c72b98f | 209 | is a stash, which was a no-no. |
0c72b98f JH |
210 | |
211 | * Pack-protocol documentation had a minor typo. | |
ce1d3a93 JH |
212 | |
213 | * "git checkout -m" did not switch to another branch while carrying | |
214 | the local changes forward when a path was deleted from the index. | |
ce1d3a93 | 215 | |
670a3c1d JH |
216 | * "git daemon" (with NO_IPV6 build configuration) used to incorrectly |
217 | use the hostname even when gethostbyname() reported that the given | |
218 | hostname is not found. | |
219 | (merge 107efbe rs/daemon-fixes later to maint). | |
220 | ||
ce1d3a93 | 221 | * With sufficiently long refnames, "git fast-import" could have |
a2b450d6 | 222 | overflowed an on-stack buffer. |
ce1d3a93 JH |
223 | |
224 | * After "pack-refs --prune" packed refs at the top-level, it failed | |
225 | to prune them. | |
ce1d3a93 JH |
226 | |
227 | * Progress output from "git gc --auto" was visible in "git fetch -q". | |
ce1d3a93 JH |
228 | |
229 | * We used to pass -1000 to poll(2), expecting it to also mean "no | |
230 | timeout", which should be spelled as -1. | |
97b8860c JH |
231 | |
232 | * "git rebase" documentation was unclear that it is required to | |
233 | specify on what <upstream> the rebase is to be done when telling it | |
234 | to first check out <branch>. | |
235 | (merge 95c6826 so/rebase-doc later to maint). | |
236 | ||
a2b450d6 MB |
237 | * "git push" over HTTP transport had an artificial limit on the number of |
238 | refs that can be pushed, imposed by the command line length. | |
97b8860c JH |
239 | (merge 26be19b jk/send-pack-many-refspecs later to maint). |
240 | ||
241 | * When receiving an invalid pack stream that records the same object | |
242 | twice, multiple threads got confused due to a race. | |
243 | (merge ab791dd jk/index-pack-threading-races later to maint). | |
244 | ||
245 | * An attempt to remove the entire tree in the "git fast-import" input | |
246 | stream caused it to misbehave. | |
247 | (merge 2668d69 mb/fast-import-delete-root later to maint). | |
248 | ||
249 | * Reachability check (used in "git prune" and friends) did not add a | |
250 | detached HEAD as a starting point to traverse objects still in use. | |
251 | (merge c40fdd0 mk/reachable-protect-detached-head later to maint). | |
252 | ||
a2b450d6 MB |
253 | * "git config --add section.var val" when section.var already has an |
254 | empty-string value used to lose the empty-string value. | |
97b8860c JH |
255 | (merge c1063be ta/config-add-to-empty-or-true-fix later to maint). |
256 | ||
257 | * "git fsck" failed to report that it found corrupt objects via its | |
258 | exit status in some cases. | |
259 | (merge 30d1038 jk/fsck-exit-code-fix later to maint). | |
d29e9c89 | 260 | |
a2b450d6 | 261 | * Use of the "--verbose" option used to break "git branch --merged". |
d29e9c89 | 262 | (merge 12994dd jk/maint-branch-verbose-merged later to maint). |
0bf7dd65 | 263 | |
a2b450d6 MB |
264 | * Some MUAs mangle a line in a message that begins with "From " to |
265 | ">From " when writing to a mailbox file, and feeding such an input | |
0bf7dd65 JH |
266 | to "git am" used to lose such a line. |
267 | (merge 85de86a jk/mbox-from-line later to maint). | |
268 | ||
269 | * "rev-parse --verify --quiet $name" is meant to quietly exit with a | |
270 | non-zero status when $name is not a valid object name, but still | |
271 | gave error messages in some cases. | |
670a3c1d JH |
272 | |
273 | * A handful of C source files have been updated to include | |
274 | "git-compat-util.h" as the first thing, to conform better to our | |
275 | coding guidelines. | |
276 | (merge 1c4b660 da/include-compat-util-first-in-c later to maint). | |
277 | ||
a2b450d6 MB |
278 | * The t7004 test, which tried to run Git with small stack space, has been |
279 | updated to use a bit larger stack to avoid false breakage on some | |
670a3c1d JH |
280 | platforms. |
281 | (merge b9a1907 sk/tag-contains-wo-recursion later to maint). | |
282 | ||
283 | * A few documentation pages had example sections marked up not quite | |
284 | correctly, which passed AsciiDoc but failed with AsciiDoctor. | |
285 | (merge c30c43c bc/asciidoc-pretty-formats-fix later to maint). | |
13da0fc0 JH |
286 | (merge f8a48af bc/asciidoc later to maint). |
287 | ||
288 | * "gitweb" used deprecated CGI::startfrom, which was removed from | |
289 | CGI.pm as of 4.04; use CGI::start_from instead. | |
290 | (merge 4750f4b rm/gitweb-start-form later to maint). | |
19b5d50c | 291 | |
a2b450d6 | 292 | * Newer versions of 'meld' break the auto-detection we use to see if |
19b5d50c JH |
293 | they are new enough to support the `--output` option. |
294 | (merge b12d045 da/mergetool-meld later to maint). | |
fbecd998 | 295 | |
a2b450d6 | 296 | * "git pack-objects" forgot to disable the codepath to generate the |
dd835216 | 297 | object reachability bitmap when it needs to split the resulting |
fbecd998 JH |
298 | pack. |
299 | (merge 2113471 jk/pack-objects-no-bitmap-when-splitting later to maint). | |
f5709437 JH |
300 | |
301 | * The code to use cache-tree trusted the on-disk data too much and | |
302 | fell into an infinite loop upon seeing an incorrectly recorded | |
303 | index file. | |
304 | (merge 729dbbd jk/cache-tree-protect-from-broken-libgit2 later to maint). | |
305 | ||
a2b450d6 | 306 | * "git fetch" into a repository where branch B was deleted earlier, |
f5709437 JH |
307 | back when it had reflog enabled, and then branch B/C is fetched |
308 | into it without reflog enabled, which is arguably an unlikely | |
309 | corner case, unnecessarily failed. | |
310 | (merge aae828b jk/fetch-reflog-df-conflict later to maint). | |
311 | ||
312 | * "git log --first-parent -L..." used to crash. | |
313 | (merge a8787c5 tm/line-log-first-parent later to maint). |