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