summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2006-12-19 09:38:18 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-12-19 09:38:18 (GMT)
commit5fed4668153c9ca6e44ec84a0976089f515705aa (patch)
tree82f3ce0d2ea76ca31cebd3a5b40d0993e019859a /Documentation
parent63085fabbdeaad9eb8b29d39d0998c704e6cd232 (diff)
parent8683a45d66967b0969516a2b72cdbf136c2064a2 (diff)
downloadgit-5fed4668153c9ca6e44ec84a0976089f515705aa.zip
git-5fed4668153c9ca6e44ec84a0976089f515705aa.tar.gz
git-5fed4668153c9ca6e44ec84a0976089f515705aa.tar.bz2
Merge branch 'jc/test-clone' into jc/clone
* jc/test-clone: (35 commits) Introduce GIT_TEMPLATE_DIR Revert "fix testsuite: make sure they use templates freshly built from the source" fix testsuite: make sure they use templates freshly built from the source rerere: fix breakage of resolving. Add config example with respect to branch Add documentation for show-branch --topics make git a bit less cryptic on fetch errors make patch_delta() error cases a bit more verbose racy-git: documentation updates. show-ref: fix --exclude-existing parse-remote::expand_refs_wildcard() vim syntax: follow recent changes to commit template show-ref: fix --verify --hash=length show-ref: fix --quiet --verify avoid accessing _all_ loose refs in git-show-ref --verify git-fetch: Avoid reading packed refs over and over again Teach show-branch how to show ref-log data. markup fix in svnimport documentation. Documentation: new option -P for git-svnimport Fix mis-mark-up in git-merge-file.txt documentation ...
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/config.txt5
-rw-r--r--Documentation/git-merge-file.txt4
-rw-r--r--Documentation/git-show-branch.txt10
-rw-r--r--Documentation/git-svnimport.txt13
-rw-r--r--Documentation/technical/racy-git.txt38
5 files changed, 47 insertions, 23 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt
index ceac54b..22482d6 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -31,6 +31,11 @@ Example
external = "/usr/local/bin/gnu-diff -u"
renames = true
+ [branch "devel"]
+ remote = origin
+ merge = refs/heads/devel
+
+
Variables
~~~~~~~~~
diff --git a/Documentation/git-merge-file.txt b/Documentation/git-merge-file.txt
index 0b41d66..29d3faa 100644
--- a/Documentation/git-merge-file.txt
+++ b/Documentation/git-merge-file.txt
@@ -1,9 +1,9 @@
git-merge-file(1)
-============
+=================
NAME
----
-git-merge-file - threeway file merge
+git-merge-file - three-way file merge
SYNOPSIS
diff --git a/Documentation/git-show-branch.txt b/Documentation/git-show-branch.txt
index a2445a4..948ff10 100644
--- a/Documentation/git-show-branch.txt
+++ b/Documentation/git-show-branch.txt
@@ -10,7 +10,7 @@ SYNOPSIS
[verse]
'git-show-branch' [--all] [--heads] [--tags] [--topo-order] [--current]
[--more=<n> | --list | --independent | --merge-base]
- [--no-name | --sha1-name] [<rev> | <glob>]...
+ [--no-name | --sha1-name] [--topics] [<rev> | <glob>]...
DESCRIPTION
-----------
@@ -86,6 +86,14 @@ OPTIONS
of "master"), name them with the unique prefix of their
object names.
+--topics::
+ Shows only commits that are NOT on the first branch given.
+ This helps track topic branches by hiding any commit that
+ is already in the main line of development. When given
+ "git show-branch --topics master topic1 topic2", this
+ will show the revisions given by "git rev-list {caret}master
+ topic1 topic2"
+
Note that --more, --list, --independent and --merge-base options
are mutually exclusive.
diff --git a/Documentation/git-svnimport.txt b/Documentation/git-svnimport.txt
index b1b87c2..2c7c7da 100644
--- a/Documentation/git-svnimport.txt
+++ b/Documentation/git-svnimport.txt
@@ -15,6 +15,7 @@ SYNOPSIS
[ -b branch_subdir ] [ -T trunk_subdir ] [ -t tag_subdir ]
[ -s start_chg ] [ -m ] [ -r ] [ -M regex ]
[ -I <ignorefile_name> ] [ -A <author_file> ]
+ [ -P <path_from_trunk> ]
<SVN_repository_URL> [ <path> ]
@@ -103,9 +104,17 @@ repository without -A.
-l <max_rev>::
Specify a maximum revision number to pull.
++
+Formerly, this option controlled how many revisions to pull,
+due to SVN memory leaks. (These have been worked around.)
- Formerly, this option controlled how many revisions to pull,
- due to SVN memory leaks. (These have been worked around.)
+-P <path_from_trunk>::
+ Partial import of the SVN tree.
++
+By default, the whole tree on the SVN trunk (/trunk) is imported.
+'-P my/proj' will import starting only from '/trunk/my/proj'.
+This option is useful when you want to import one project from a
+svn repo which hosts multiple projects under the same trunk.
-v::
Verbosity: let 'svnimport' report what it is doing.
diff --git a/Documentation/technical/racy-git.txt b/Documentation/technical/racy-git.txt
index 7597d04..5030d9f 100644
--- a/Documentation/technical/racy-git.txt
+++ b/Documentation/technical/racy-git.txt
@@ -4,7 +4,7 @@ Use of index and Racy git problem
Background
----------
-The index is one of the most important data structure in git.
+The index is one of the most important data structures in git.
It represents a virtual working tree state by recording list of
paths and their object names and serves as a staging area to
write out the next tree object to be committed. The state is
@@ -16,7 +16,7 @@ virtual working tree state in the index and the files in the
working tree. The most obvious case is when the user asks `git
diff` (or its low level implementation, `git diff-files`) or
`git-ls-files --modified`. In addition, git internally checks
-if the files in the working tree is different from what are
+if the files in the working tree are different from what are
recorded in the index to avoid stomping on local changes in them
during patch application, switching branches, and merging.
@@ -24,9 +24,9 @@ In order to speed up this comparison between the files in the
working tree and the index entries, the index entries record the
information obtained from the filesystem via `lstat(2)` system
call when they were last updated. When checking if they differ,
-git first runs `lstat(2)` on the files and compare the result
+git first runs `lstat(2)` on the files and compares the result
with this information (this is what was originally done by the
-`ce_match_stat()` function, which the current code does in
+`ce_match_stat()` function, but the current code does it in
`ce_match_stat_basic()` function). If some of these "cached
stat information" fields do not match, git can tell that the
files are modified without even looking at their contents.
@@ -53,8 +53,9 @@ Racy git
There is one slight problem with the optimization based on the
cached stat information. Consider this sequence:
+ : modify 'foo'
$ git update-index 'foo'
- : modify 'foo' in-place without changing its size
+ : modify 'foo' again, in-place, without changing its size
The first `update-index` computes the object name of the
contents of file `foo` and updates the index entry for `foo`
@@ -62,7 +63,8 @@ along with the `struct stat` information. If the modification
that follows it happens very fast so that the file's `st_mtime`
timestamp does not change, after this sequence, the cached stat
information the index entry records still exactly match what you
-can obtain from the filesystem, but the file `foo` is modified.
+would see in the filesystem, even though the file `foo` is now
+different.
This way, git can incorrectly think files in the working tree
are unmodified even though they actually are. This is called
the "racy git" problem (discovered by Pasky), and the entries
@@ -87,7 +89,7 @@ the stat information from updated paths, `st_mtime` timestamp of
it is usually the same as or newer than any of the paths the
index contains. And no matter how quick the modification that
follows `git update-index foo` finishes, the resulting
-`st_mtime` timestamp on `foo` cannot get the timestamp earlier
+`st_mtime` timestamp on `foo` cannot get a value earlier
than the index file. Therefore, index entries that can be
racily clean are limited to the ones that have the same
timestamp as the index file itself.
@@ -111,7 +113,7 @@ value, and falsely clean entry `foo` would not be caught by the
timestamp comparison check done with the former logic anymore.
The latter makes sure that the cached stat information for `foo`
would never match with the file in the working tree, so later
-checks by `ce_match_stat_basic()` would report the index entry
+checks by `ce_match_stat_basic()` would report that the index entry
does not match the file and git does not have to fall back on more
expensive `ce_modified_check_fs()`.
@@ -155,17 +157,16 @@ of the cached stat information.
Avoiding runtime penalty
------------------------
-In order to avoid the above runtime penalty, the recent "master"
-branch (post 1.4.2) has a code that makes sure the index file
-gets timestamp newer than the youngest files in the index when
+In order to avoid the above runtime penalty, post 1.4.2 git used
+to have a code that made sure the index file
+got timestamp newer than the youngest files in the index when
there are many young files with the same timestamp as the
resulting index file would otherwise would have by waiting
before finishing writing the index file out.
-I suspect that in practice the situation where many paths in the
-index are all racily clean is quite rare. The only code paths
-that can record recent timestamp for large number of paths I
-know of are:
+I suspected that in practice the situation where many paths in the
+index are all racily clean was quite rare. The only code paths
+that can record recent timestamp for large number of paths are:
. Initial `git add .` of a large project.
@@ -188,6 +189,7 @@ youngest file in the working tree. This means that in these
cases there actually will not be any racily clean entry in
the resulting index.
-So in summary I think we should not worry about avoiding the
-runtime penalty and get rid of the "wait before finishing
-writing" code out.
+Based on this discussion, the current code does not use the
+"workaround" to avoid the runtime penalty that does not exist in
+practice anymore. This was done with commit 0fc82cff on Aug 15,
+2006.