Git development
 help / color / mirror / Atom feed
* Re: Not going beyond symbolic links
From: Linus Torvalds @ 2008-08-05  2:28 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Junio C Hamano, git, Petr Baudis, Shawn O. Pearce
In-Reply-To: <alpine.DEB.1.00.0808050356480.9611@pacific.mpi-cbg.de.mpi-cbg.de>



On Tue, 5 Aug 2008, Johannes Schindelin wrote:
> 
> I vividly remember being quite pissed by Git replacing a symbolic link in 
> my working directory with a directory, and instead of updating the files 
> which were technically outside of the repository, Git populated that newly 
> created directory.

Well, that can cut both ways. For example, I vividly remember a time in 
the distant past when harddisks were tiny, and I didn't have insanely 
high-end hardware, and I was building the X server, but had to split 
things up over two partitions because each individual partition was 
too full.

IOW, sometimes you may _want_ to use symlinks that way, even within one 
project - with a symlink allowing you to move parts of it around 
"transparently".

Of course, these days under Linux we can just use bind mounts, so the use 
of symlinks to stitch together two or more different trees is fairly 
old-fashioned, but is still the only option on some systems or if you 
don't have root.

(These days harddisks are also generally so big that it never happens. But 
on my EeePC laptop, I still end up with two filesystems, 4GB  and 8GB 
each. So it's not inconceivable to be in that kind of situation even 
today).

			Linus

^ permalink raw reply

* [JGIT PATCH 0/6] Misc. documentation cleanups
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git

After the JavaGit announcement today it was pointed out to me that
our top-level documentation in egit.git is not accurate with our
current project state.

This is a first attempt at getting things current.  Its likely not
complete and we should do more before we ship the next release.

Shawn O. Pearce (6):
  Updated egit INSTALL document to mention Eclipse 3.4.0
  Rename INSTALL to EGIT_INSTALL
  Mark completed items (commit, fetch, push, graphic log) in TODO file
  Remove outdated warnings from the README
  Remove the "jgit is slow" remark from README
  Remove the "windows isn't supported" remark from README

 INSTALL => EGIT_INSTALL |    4 +-
 README                  |   53 +-------------------------------------
 TODO                    |   66 -----------------------------------------------
 3 files changed, 3 insertions(+), 120 deletions(-)
 rename INSTALL => EGIT_INSTALL (96%)

^ permalink raw reply

* [JGIT PATCH 1/6] Updated egit INSTALL document to mention Eclipse 3.4.0
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-1-git-send-email-spearce@spearce.org>

Eclipse 3.4.0 is now final.  Also we require at least 3.3.1, but
we really prefer 3.4.0.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 INSTALL |    2 +-
 README  |    3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/INSTALL b/INSTALL
index bb303c1..76be0a4 100644
--- a/INSTALL
+++ b/INSTALL
@@ -6,7 +6,7 @@ PREREQUISITES
 In order to install the Git Eclipse plugin you need to have the following
 things.
 
-- Eclipse version 3.2.1 or later (works up to 3.4 M1).
+- Eclipse version 3.3.1, or 3.4.0
 
 - Java 6. Java 1.5.0_11 and later seems to work. The reason is that
   the garbage collection does not do a good enough job when using memory
diff --git a/README b/README
index af601e8..a10b8d4 100644
--- a/README
+++ b/README
@@ -94,8 +94,7 @@ three for packaging.
 
             == COMPATIBILITY                   ==
 
-- Eclipse 3.2.1 is the minimum Eclipse version. Expect this to change
-  in future versions.
+- Eclipse 3.3.1 is the minimum Eclipse version, 3.4 is preferred.
 
 - Newer version of EGit/JGit may implement new functionality, remove
   existing functions and change others without other notice than what
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* [JGIT PATCH 2/6] Rename INSTALL to EGIT_INSTALL
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-2-git-send-email-spearce@spearce.org>

This document is entirely about how to install the EGit plugins
and has nothing to do with JGit itself.  Later if/when we split the
Git repository into two trees (one for jgit, one for egit) we can
rename this back to just plain INSTALL inside of the EGit repository.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 INSTALL => EGIT_INSTALL |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
 rename INSTALL => EGIT_INSTALL (98%)

diff --git a/INSTALL b/EGIT_INSTALL
similarity index 98%
rename from INSTALL
rename to EGIT_INSTALL
index 76be0a4..142526a 100644
--- a/INSTALL
+++ b/EGIT_INSTALL
@@ -1,5 +1,5 @@
 
-	EGit/JGit installation
+	EGit Installation
 
 PREREQUISITES
 
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* [JGIT PATCH 3/6] Mark completed items (commit, fetch, push, graphic log) in TODO file
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-3-git-send-email-spearce@spearce.org>

These are done and don't need to be mentioned anymore.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 README |    3 --
 TODO   |   66 ----------------------------------------------------------------
 2 files changed, 0 insertions(+), 69 deletions(-)

diff --git a/README b/README
index a10b8d4..db11c25 100644
--- a/README
+++ b/README
@@ -177,9 +177,6 @@ For some operations it may just be the preferred solution also. There
 are not just a command line, there is e.g. git-gui that makes committing
 partial files simple.
 
-- GIT network protocol to pull objects from a remote repository or
-  push objects to a remote repository.
-
 - Merging. 
 
 - Repacking from within the plugin.
diff --git a/TODO b/TODO
index a7ef2b9..5f35b25 100644
--- a/TODO
+++ b/TODO
@@ -3,27 +3,6 @@
 Now that we have some basic features in the Eclipse plugin, we need
 to focus on making it usable by average users doing daily tasks.
 
-== Commit ==
-
-Commit all (or selected) files to current branch.
-
-This feature is trivial if the repository is fully mounted within
-Eclipse, as Eclipse has the entire working tree available, making
-it easy to write out the blobs and tree objects needed to form the
-root tree for the new commit.
-
-Its less easy when the repository is not fully mounted within
-Eclipse.  (See for example the egit repository itself; the
-repository has 3 projects in it so Eclipse doesn't see the top
-level directory.)  In this case egit needs to preseve the files
-that are currently either in HEAD or in the index for the parts
-of the tree it cannot see, while using the files it has in memory
-for the parts of the tree that it can see.  In this latter case I'm
-thinking that preserving HEAD rather than the index is the right way
-to go here, as jgit does not play nicely with core Git's index file.
-Consequently users should be discouraged from trying to create a
-commit based on the results of both tools.
-
 == Create Branch ==
 
 Create a new branch from any revision specification.
@@ -48,29 +27,6 @@ preventing the switch or doing an implicit commit when the working
 directory is dirty) without having to worry about merging. ''--
 Steven Grimm''
 
-== Fetch ==
-
-Fetching changes from a remote repository into a tracking branch.
-Aka "git fetch".
-
-I'd like to keep egit/jgit 100% pure Java, to make it easier to
-install the plugin on a wide varity of systems.  This means we
-need to implement a good amount of code for the network protocol
-and the --objects-edge feature of rev-list.  Although a lot to code
-its probably only slightly more effort than forking out to run git
-fetch and deal with its error conditions.
-
-Fetching over SSH should be possible through the jsch library
-included in Eclipse; this is what CVS uses for its SSH2 connections.
-Fetching from a local directory should just be a matter of creating a
-Repository object on that directory path (no need to fork a process
-like core Git does).
-
-Initially I'd like to stay away from the commit walkers (e.g. HTTP).
-Actually supporting them is likely a really good argument for at
-least making it possible for the user to configure jgit to invoke
-"git fetch" in an external process.
-
 == Merge ==
 
 Merging changes from one local branch to another.
@@ -82,28 +38,6 @@ available, or do what core Git just did and implement a 3 way in
 memory merge algorithm.  git-merge-recursive is only 1336 lines of C
 so it should not be too difficult to port the algorithm to pure Java.
 
-== Push ==
-
-Pushing changes to a remote repository.
-
-A lot like fetch, we should be able to support the native Git
-protocol for SSH based push, and for local directory access we just
-need to mount the other repository as a new Repository object and
-copy the object data from one to the other.  Probably easier than
-it is for core Git.
-
-As far as packing data over the network goes I don't want to
-implement the binary delta algorithm in pure Java right now.  So this
-means we would send packs containing only whole objects (no deltas).
-This shouldn't really be an issue for the receiving end, except
-that we will have a slightly higher network transfer cost coming
-from egit than if core Git was used to push the same set of objects.
-
-== Graphical History Viewer ==
-
-A graphical history viewer similar to gitk or qgit, but in SWT/JFace
-so it can run within the Eclipse workbench.
-
 == SVN Integration ==
 
 It would be swell -- but put it at the bottom of your priority list
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* [JGIT PATCH 6/6] Remove the "windows isn't supported" remark from README
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-6-git-send-email-spearce@spearce.org>

The Windows support has come a long way since this was written
into the README.  We actually (mostly) support repositories that
were created on Cygwin, even if they used --shared to setup object
alternates with Cygwin paths, and we honor the user's Cygwin home
directory for configuration and SSH keys.  Windows is about as well
supported as one can get on Java.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 README |    4 ----
 1 files changed, 0 insertions(+), 4 deletions(-)

diff --git a/README b/README
index 334f3d5..dd4a910 100644
--- a/README
+++ b/README
@@ -174,10 +174,6 @@ partial files simple.
 
 - Documentation. :-)
 
-- Windows support is new and very ligthly tested. Do not blame us if
-  it blows, but tell us about it and what you did. Double check
-  everything.
-
 - gitattributes support
   In particular CRLF conversion is not implemented. Files are treated
   as byte sequences.
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* [JGIT PATCH 5/6] Remove the "jgit is slow" remark from README
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-5-git-send-email-spearce@spearce.org>

Historically this may have been true, back when we built things
on the lib.Commit and lib.Tree API.  Those APIs are quickly being
rebuilt around RevWalk and TreeWalk, which are much more powerful
and significantly faster.

Most testing indicates that once the JIT has had a chance to do
its optimization magic on the jgit library we get performance that
really does rival C git running on the same system.  Since C git
is so ridiculously fast we're probably still beating many of the
other VCS tools available.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 README |   30 ------------------------------
 1 files changed, 0 insertions(+), 30 deletions(-)

diff --git a/README b/README
index e18a9eb..334f3d5 100644
--- a/README
+++ b/README
@@ -188,36 +188,6 @@ partial files simple.
 - The Eclipse plugin cannot handle files outside any Eclipse project. You
   need commit changes to such files outside of Eclipse.
 
-- Speed in some areas
-
-  Java is "slooow", they say. Not true as a general statement. A lot of Java
-  code is slow because it it not optimized (to some extent due to this
-  belief). Java has quite good performance although it cannot compete with
-  C code written by good hackers simply because C can be optimized more than
-  Java when you actually do it and have the skills to do it. Some areas of
-  the plugin have been optimized but not all and not conclusively. In general
-  however Java almost always needs more memory than an application written in 
-  e.g. C. In particular there is an overhead from the rather large standard
-  libraries that a normal Java installation comes with. See the ACM report:
-
-	Prechelt, L. 1999. Technical opinion: comparing Java vs. C/C++
-        efficiency differences to interpersonal differences. Commun. ACM 42, 
-        10 (Oct. 1999), 109-112. DOI= http://doi.acm.org/10.1145/317665.317683
-
-  for an interesting comparison of C, C++ and Java. It is somewhat dated so 
-  the comparison involved Java 1.2, i.e. without hotspot that appeared in Java 
-  1.3 and the shared runtime in 1.4. Those features made common Java
-  applications many times faster than with Java 1.2
-
-  The conclusion from having about 30 programmers write a program to the same
-  specification using their own choice of language (from C,C++ and Java) is
-  that the skills of the programmer is what determines the performance of the
-  code rather than choice of programming language.
-
-  JGit is much slower (measured up to eight times for some random cases), but
-  then the real Git is ridicilously fast.
-
-
             == Support                         ==
 
   Post question, comments or patches to the git@vger.kernel.org mailing list.
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* [JGIT PATCH 4/6] Remove outdated warnings from the README
From: Shawn O. Pearce @ 2008-08-05  2:47 UTC (permalink / raw)
  To: Robin Rosenberg, Marek Zawirski; +Cc: git
In-Reply-To: <1217904436-1989-4-git-send-email-spearce@spearce.org>

We no longer fear the jgit library eating a repository, or causing
other sorts of corruption.  Nor do we fear the Eclipse plugin
locking up your workbench, as it just has never happened.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
---
 README |   13 -------------
 1 files changed, 0 insertions(+), 13 deletions(-)

diff --git a/README b/README
index db11c25..e18a9eb 100644
--- a/README
+++ b/README
@@ -66,15 +66,6 @@ three for packaging.
 
             == WARNINGS / CAVEATS              ==
 
-- The plugin could lockup your Eclipse workbench.  I've tried to
-  make it stable and function in such a way that it can't crash
-  the workbench, but that doesn't mean it won't.  :-)
-
-- This package might eat your files.  Everything I've added to a
-  repository with it has unpacked properly both with itself and
-  with the canonical C based implementation, but that doesn't mean
-  it won't generate a corrupt object.
-
 - Symbolic links are not supported because java does not support it.
   Such links could be damaged.
 
@@ -88,10 +79,6 @@ three for packaging.
   have no information about other vendors. Please report your findings
   if you try.
 
-- Do not trust this plugin to always do the right thing (yet). Please
-  check with the real Git and report any problems.
-
-
             == COMPATIBILITY                   ==
 
 - Eclipse 3.3.1 is the minimum Eclipse version, 3.4 is preferred.
-- 
1.6.0.rc1.250.g9b5e2

^ permalink raw reply related

* Re: Not going beyond symbolic links
From: Junio C Hamano @ 2008-08-05  3:01 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: git, Petr Baudis, Shawn O. Pearce, Johannes Schindelin
In-Reply-To: <alpine.LFD.1.10.0808041839130.3299@nehalem.linux-foundation.org>

Linus Torvalds <torvalds@linux-foundation.org> writes:

> ... Because this is definitely not a black-and-white "one behavior is 
> wrong and one behavior is right".

I wish I could agree with you that this is a feature, but 16a4c61
(read-tree -m -u: avoid getting confused by intermediate symlinks.,
2007-05-10) and 64cab59 (apply: do not get confused by symlinks in the
middle, 2007-05-11) came from real world breakage cases and the root cause
was that we were too lenient to allow such a "feature" that pretends the
symlink not to be there.

Right now, we are being careful only while branch switching and patch
application, but the codepaths that add directly to the index (add and
update-index) are not fixed (or "still has the feature").

I do not see a clean way to keep such a "feature" without hurting users
who suffered the bugs these two commits from May 2007 fixed.

^ permalink raw reply

* Re: Not going beyond symbolic links
From: david @ 2008-08-05  3:04 UTC (permalink / raw)
  To: Junio C Hamano
  Cc: Linus Torvalds, git, Petr Baudis, Shawn O. Pearce,
	Johannes Schindelin
In-Reply-To: <7v3alk17yh.fsf@gitster.siamese.dyndns.org>

On Mon, 4 Aug 2008, Junio C Hamano wrote:

> Linus Torvalds <torvalds@linux-foundation.org> writes:
>
>> ... Because this is definitely not a black-and-white "one behavior is
>> wrong and one behavior is right".
>
> I wish I could agree with you that this is a feature, but 16a4c61
> (read-tree -m -u: avoid getting confused by intermediate symlinks.,
> 2007-05-10) and 64cab59 (apply: do not get confused by symlinks in the
> middle, 2007-05-11) came from real world breakage cases and the root cause
> was that we were too lenient to allow such a "feature" that pretends the
> symlink not to be there.
>
> Right now, we are being careful only while branch switching and patch
> application, but the codepaths that add directly to the index (add and
> update-index) are not fixed (or "still has the feature").
>
> I do not see a clean way to keep such a "feature" without hurting users
> who suffered the bugs these two commits from May 2007 fixed.

config option?

I think a command line is too much work for too little value, but if the 
check could be ignored based on a config option without costing too much 
it may be reasonable.

David Lang

^ permalink raw reply

* Re: [PATCH] correct access right for git-svn-dcommit test
From: Eric Wong @ 2008-08-05  3:18 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: Dmitry Potapov, Brad King, git
In-Reply-To: <20080804153024.GV7008@dpotapov.dyndns.org>

Dmitry Potapov <dpotapov@gmail.com> wrote:
> The tests requires anonymous write access. Therefore, "anon-access =
> write" is added to conf/svnserve.conf. But because it was added to
> the end of the file, it is impossible to guarantee in what section
> it will be located. It turned out that on SVN 1.5, it was placed in
> the wrong section and as result the test failed.
> 
> Signed-off-by: Dmitry Potapov <dpotapov@gmail.com>

Brad and Dmitry: Thank you both very much.

Acked-by: Eric Wong <normalperson@yhbt.net>

> ---
>  t/t9113-git-svn-dcommit-new-file.sh |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/t/t9113-git-svn-dcommit-new-file.sh b/t/t9113-git-svn-dcommit-new-file.sh
> index 8da8ce5..ae78e33 100755
> --- a/t/t9113-git-svn-dcommit-new-file.sh
> +++ b/t/t9113-git-svn-dcommit-new-file.sh
> @@ -28,6 +28,7 @@ start_svnserve () {
>  
>  test_expect_success 'start tracking an empty repo' '
>  	svn mkdir -m "empty dir" "$svnrepo"/empty-dir &&
> +	echo "[general]" > "$rawsvnrepo"/conf/svnserve.conf &&
>  	echo anon-access = write >> "$rawsvnrepo"/conf/svnserve.conf &&
>  	start_svnserve &&
>  	git svn init svn://127.0.0.1:$SVNSERVE_PORT &&
> -- 
> 1.6.0.rc1.74.g1e94

^ permalink raw reply

* Re: Not going beyond symbolic links
From: Junio C Hamano @ 2008-08-05  4:44 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Linus Torvalds, git, Petr Baudis, Shawn O. Pearce
In-Reply-To: <alpine.DEB.1.00.0808050356480.9611@pacific.mpi-cbg.de.mpi-cbg.de>

Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

> However, please note that Junio's patch affects git-add, AFAIR, not 
> git-update-index.

Really?  I thought I added a test case to cover the plumbing as well...

^ permalink raw reply

* [PATCH 0/8] bash completion: more porcelain completions
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow

This adds basic long option completion for some common commands that I
use, as well as stash name completion.

Lee Marlow (8):
  bash completion: Add completion for 'git clone'
  bash completion: Add completion for 'git clean'
  bash completion: Add completion for 'git init'
  bash completion: Add completion for 'git revert'
  bash completion: More completions for 'git stash'
  bash completion: Add completion for 'git archive'
  bash completion: Add completion for 'git ls-files'
  bash completion: Add completion for 'git mv'

 contrib/completion/git-completion.bash |  143 +++++++++++++++++++++++++++++++-
 git-stash.sh                           |    2 +-
 2 files changed, 143 insertions(+), 2 deletions(-)

^ permalink raw reply

* [PATCH 1/8] bash completion: Add completion for 'git clone'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-1-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
	--local --no-hardlinks --shared --reference
	--quiet --no-checkout --bare --mirror --origin
	--upload-pack --template= --depth

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   26 ++++++++++++++++++++++++++
 1 files changed, 26 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 678a155..6ffe259 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -667,6 +667,31 @@ _git_cherry_pick ()
 	esac
 }
 
+_git_clone ()
+{
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--*)
+		__gitcomp "
+			--local
+			--no-hardlinks
+			--shared
+			--reference
+			--quiet
+			--no-checkout
+			--bare
+			--mirror
+			--origin
+			--upload-pack
+			--template=
+			--depth
+			"
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_commit ()
 {
 	__git_has_doubledash && return
@@ -1475,6 +1500,7 @@ _git ()
 	checkout)    _git_checkout ;;
 	cherry)      _git_cherry ;;
 	cherry-pick) _git_cherry_pick ;;
+	clone)       _git_clone ;;
 	commit)      _git_commit ;;
 	config)      _git_config ;;
 	describe)    _git_describe ;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 2/8] bash completion: Add completion for 'git clean'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-2-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
        --dry-run --quiet

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   15 +++++++++++++++
 1 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 6ffe259..72be4f1 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -667,6 +667,20 @@ _git_cherry_pick ()
 	esac
 }
 
+_git_clean ()
+{
+	__git_has_doubledash && return
+
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--*)
+		__gitcomp "--dry-run --quiet"
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_clone ()
 {
 	local cur="${COMP_WORDS[COMP_CWORD]}"
@@ -1500,6 +1514,7 @@ _git ()
 	checkout)    _git_checkout ;;
 	cherry)      _git_cherry ;;
 	cherry-pick) _git_cherry_pick ;;
+	clean)       _git_clean ;;
 	clone)       _git_clone ;;
 	commit)      _git_commit ;;
 	config)      _git_config ;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 3/8] bash completion: Add completion for 'git init'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-3-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
        --quiet --bare --template= --shared
        --shared={false|true|umask|group|all|world|everybody}

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 72be4f1..c7a6d92 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -842,6 +842,24 @@ _git_help ()
 	__gitcomp "$(__git_all_commands)"
 }
 
+_git_init ()
+{
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--shared=*)
+		__gitcomp "
+			false true umask group all world everybody
+			" "" "${cur##--shared=}"
+		return
+		;;
+	--*)
+		__gitcomp "--quiet --bare --template= --shared --shared="
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_ls_remote ()
 {
 	__gitcomp "$(__git_remotes)"
@@ -1524,6 +1542,7 @@ _git ()
 	format-patch) _git_format_patch ;;
 	gc)          _git_gc ;;
 	help)        _git_help ;;
+	init)        _git_init ;;
 	log)         _git_log ;;
 	ls-remote)   _git_ls_remote ;;
 	ls-tree)     _git_ls_tree ;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 5/8] bash completion: More completions for 'git stash'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-5-git-send-email-lee.marlow@gmail.com>

Add branch subcommand to completions and USAGE for git-stash.sh.
Complete stash names for show, apply, drop, pop, and branch.
Add "--index" long option for apply.

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   12 +++++++++++-
 git-stash.sh                           |    2 +-
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 6a5c4cd..a292cbd 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -1348,7 +1348,7 @@ _git_show_branch ()
 
 _git_stash ()
 {
-	local subcommands='save list show apply clear drop pop create'
+	local subcommands='save list show apply clear drop pop create branch'
 	local subcommand="$(__git_find_subcommand "$subcommands")"
 	if [ -z "$subcommand" ]; then
 		__gitcomp "$subcommands"
@@ -1358,6 +1358,16 @@ _git_stash ()
 		save,--*)
 			__gitcomp "--keep-index"
 			;;
+		apply,--*)
+			__gitcomp "--index"
+			;;
+		show,--*|apply,--*|drop,--*|pop,--*|branch,--*)
+			COMPREPLY=()
+			;;
+		show,*|apply,*|drop,*|pop,*|branch,*)
+			__gitcomp "$(git --git-dir="$(__gitdir)" stash list \
+					| sed -n -e 's/:.*//p')"
+			;;
 		*)
 			COMPREPLY=()
 			;;
diff --git a/git-stash.sh b/git-stash.sh
index d4609ed..5ad2c4b 100755
--- a/git-stash.sh
+++ b/git-stash.sh
@@ -1,7 +1,7 @@
 #!/bin/sh
 # Copyright (c) 2007, Nanako Shiraishi
 
-USAGE='[  | save | list | show | apply | clear | drop | pop | create ]'
+USAGE='[  | save | list | show | apply | clear | drop | pop | create | branch ]'
 
 SUBDIRECTORY_OK=Yes
 OPTIONS_SPEC=
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 4/8] bash completion: Add completion for 'git revert'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-4-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
        --edit --mainline --no-edit --no-commit --signoff

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index c7a6d92..6a5c4cd 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -1264,6 +1264,18 @@ _git_reset ()
 	__gitcomp "$(__git_refs)"
 }
 
+_git_revert ()
+{
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--*)
+		__gitcomp "--edit --mainline --no-edit --no-commit --signoff"
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_rm ()
 {
 	__git_has_doubledash && return
@@ -1554,6 +1566,7 @@ _git ()
 	rebase)      _git_rebase ;;
 	remote)      _git_remote ;;
 	reset)       _git_reset ;;
+	revert)      _git_revert ;;
 	rm)          _git_rm ;;
 	send-email)  _git_send_email ;;
 	shortlog)    _git_shortlog ;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 6/8] bash completion: Add completion for 'git archive'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-6-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
	--format= --list --verbose
	--prefix= --remote= --exec=
The --format= long option can be completed with available formats
and the --remote= can be completed with defined remote repositories.

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   24 ++++++++++++++++++++++++
 1 files changed, 24 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index a292cbd..61ea6d9 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -561,6 +561,29 @@ _git_add ()
 	COMPREPLY=()
 }
 
+_git_archive ()
+{
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--format=*)
+		__gitcomp "$(git archive --list)" "" "${cur##--format=}"
+		return
+		;;
+	--remote=*)
+		__gitcomp "$(__git_remotes)" "" "${cur##--remote=}"
+		return
+		;;
+	--*)
+		__gitcomp "
+			--format= --list --verbose
+			--prefix= --remote= --exec=
+			"
+		return
+		;;
+	esac
+	__git_complete_file
+}
+
 _git_bisect ()
 {
 	__git_has_doubledash && return
@@ -1548,6 +1571,7 @@ _git ()
 	am)          _git_am ;;
 	add)         _git_add ;;
 	apply)       _git_apply ;;
+	archive)     _git_archive ;;
 	bisect)      _git_bisect ;;
 	bundle)      _git_bundle ;;
 	branch)      _git_branch ;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* [PATCH 7/8] bash completion: Add completion for 'git ls-files'
From: Lee Marlow @ 2008-08-05  5:50 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git, Lee Marlow
In-Reply-To: <1217915438-6838-7-git-send-email-lee.marlow@gmail.com>

Added completions for all long options specified in the docs
	--cached --deleted --modified --others --ignored
	--stage --directory --no-empty-directory --unmerged
	--killed --exclude= --exclude-from=
	--exclude-per-directory= --exclude-standard
	--error-unmatch --with-tree= --full-name
	--abbrev --ignored --exclude-per-directory

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 61ea6d9..936cd35 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -883,6 +883,26 @@ _git_init ()
 	COMPREPLY=()
 }
 
+_git_ls_files ()
+{
+	__git_has_doubledash && return
+
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--*)
+		__gitcomp "--cached --deleted --modified --others --ignored
+			--stage --directory --no-empty-directory --unmerged
+			--killed --exclude= --exclude-from=
+			--exclude-per-directory= --exclude-standard
+			--error-unmatch --with-tree= --full-name
+			--abbrev --ignored --exclude-per-directory
+			"
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_ls_remote ()
 {
 	__gitcomp "$(__git_remotes)"
@@ -1590,6 +1610,7 @@ _git ()
 	help)        _git_help ;;
 	init)        _git_init ;;
 	log)         _git_log ;;
+	ls-files)    _git_ls_files ;;
 	ls-remote)   _git_ls_remote ;;
 	ls-tree)     _git_ls_tree ;;
 	merge)       _git_merge;;
-- 
1.6.0.rc1.48.g2b6032

^ permalink raw reply related

* Re: Not going beyond symbolic links
From: Junio C Hamano @ 2008-08-05  6:11 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: Johannes Schindelin, git, Petr Baudis, Shawn O. Pearce
In-Reply-To: <alpine.LFD.1.10.0808041921530.3299@nehalem.linux-foundation.org>

Linus Torvalds <torvalds@linux-foundation.org> writes:

> IOW, sometimes you may _want_ to use symlinks that way, even within one 
> project - with a symlink allowing you to move parts of it around 
> "transparently".

While I admit that I have managed a large directory split across
partitions grafted via symlinks in pre-git days myself, ever since you
started "tracking" symbolic links with 8ae0a8c (git and symlinks as
tracked content, 2005-05-05), you have pretty much been committed to
"track" symbolic links.

This goes even before that commit. The readdir() loop done in show-files.c
with 8695c8b (Add "show-files" command to show the list of managed (or
non-managed) files., 2005-04-11) does not dereference symbolic links
pointing at a directory elsewhere, which we still have as read_directory()
in dir.c without much change in the basic structure.

I would give some leeway to other people who made comments in this thread,
who may not be so familiar with the low-level git codebase, but I have to
say that if you claim that dereferencing symbolic links in the middle is a
feature, you are not being completely honest, you haven't thought through
the issues, and/or you simply forgot the details.  I'd suspect most likely
it is the last one ;-).

The thing is, the "feature" is not very well supported, even without the
fixes from last night.  If you have a symlink "sym" that points at "dir"
that has "file" in it, and if neither "sym" nor "dir/file" are tracked,
you can "git add sym/file" to add it (I called it a bug).

However:

 (1) starting from the same condition, "git add ." does _not_ add it (you
     get the symbolic link "sym" added to your index instead, as well as
     "dir/file");

 (2) after you add "sym/file" through the bug, if you say "git add .", it
     will be removed from the index and you will instead have "sym" and
     "dir/file" (with an ancient git before 1.5.0, you will get "unable to
     add sym" error instead).

 (3) after you add "sym/file", "git diff" will immediately notice that you
     have removed it (this is a fairly recent fix; 1.5.4.X doesn't notice
     it).

You cannot have it as a reliably usable feature without a major surgery,
and this is fundamental. You simply cannot have it both ways without
telling git which symlink is "tracked" and which are only there for
storage sizing.

If you seriously want to claim that we support such a feature, you would
at least need to:

 (0) have a way for the user to say, "the project tree may have a
     directory D, but I do not want to check it out as a directory because
     my partition is too small.  Whenever you need to create a directory
     there and hang a tree underneath, instead create a symlink that
     points at /export/large/D instead".  Most likely this information
     would go to .git/config;

 (1) whereever we run "create leading directories", we notice and honor
     the above configuration (mostly entry.c::create_directories() called
     from entry.c::checkout_entry());

 (2) whenever we need to check out a file to path D, instead of
     recursively remove everything under it, we remove the symlink and
     deposit the file there (mostly entry.c::remove_subtree() and
     unpack-trees.c::verify_absent());

 (3) whenever we traverse working tree using readdir(), notice that the
     symbolic link we are looking at is the funny "pointing elsewhere but
     this is really a directory" specified in (0) and recurse into the
     directory pointed by it (dir.c::read_directory_recursive() but there
     may be others)

 (4) and we teach has_symlink_leading_path() to special case such a path
     you configured in (0).

I personally do not think adding these to support such a "feature" is such
a high priority, and I do not think it is honest to claim we support such
a feature without doing any of the above.  The current reality is that our
symlink support is still broken in corner cases, and being able to easily
add "sym/path" via "git add" and "git update-index --add" is one of them.

^ permalink raw reply

* Re: [PATCH] Git.pm: localise $? in command_close_bidi_pipe()
From: Junio C Hamano @ 2008-08-05  6:12 UTC (permalink / raw)
  To: Abhijit Menon-Sen; +Cc: Petr Baudis, git
In-Reply-To: <20080804113827.GA1239@toroid.org>

Abhijit Menon-Sen <ams@toroid.org> writes:

> With my patch, however, Git::DESTROY calls the two _close functions
> during global destruction, which in turn call command_close_bidi_pipe,
> which calls waitpid with sensible arguments this time, which alters $?,
> thus altering the exit status of the dcommit itself to 0. Oops.

Thanks.

^ permalink raw reply

* [PATCH 2/3] Fix race condition in t9119-git-svn-info.sh
From: Eric Wong @ 2008-08-05  7:35 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git, David D. Kilzer
In-Reply-To: <1217921718-25011-1-git-send-email-normalperson@yhbt.net>

From: David D. Kilzer <ddkilzer@kilzer.net>

Changed the ptouch bash function to use the "Text Last Updated"
date reported by 'svn info' when changing the modified time
(mtime) of the file/symlink/directory in the git working
directory.  Previously it used the mtime of the item in the
svn working directory, which caused the race condition.

[ew: swapped argument order of ptouch() to minimize diff]

From: David D. Kilzer <ddkilzer@kilzer.net>

Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net>
Acked-by: Eric Wong <normalperson@yhbt.net>
---
 t/t9119-git-svn-info.sh |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/t/t9119-git-svn-info.sh b/t/t9119-git-svn-info.sh
index cc61911..964011e 100755
--- a/t/t9119-git-svn-info.sh
+++ b/t/t9119-git-svn-info.sh
@@ -11,11 +11,18 @@ test_done
 ptouch() {
 	perl -w -e '
 		use strict;
+		use POSIX qw(mktime);
 		die "ptouch requires exactly 2 arguments" if @ARGV != 2;
-		die "$ARGV[0] does not exist" if ! -e $ARGV[0];
-		my @s = stat $ARGV[0];
-		utime $s[8], $s[9], $ARGV[1];
-	' "$1" "$2"
+		my $text_last_updated = shift @ARGV;
+		my $git_file = shift @ARGV;
+		die "\"$git_file\" does not exist" if ! -e $git_file;
+		if ($text_last_updated
+		    =~ /(\d{4})-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})/) {
+			my $mtime = mktime($6, $5, $4, $3, $2 - 1, $1 - 1900);
+			my $atime = $mtime;
+			utime $atime, $mtime, $git_file;
+		}
+	' "`svn info $2 | grep '^Text Last Updated:'`" "$1"
 }
 
 test_expect_success 'setup repository and import' "
-- 
1.6.0.rc1.69.g797ea

^ permalink raw reply related

* [PATCH 1/3] git-svn: properly set path for "info" command
From: Eric Wong @ 2008-08-05  7:35 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git, Eric Wong

canonicalize_path() was previously changed to better
fit SVN 1.5, but it makes the "info" command not match
svn(1) in two places:

  1) URL ended up with a trailing slash when run without an
     argument.

  2) "Path: " was displayed instead of "Path: ." when run
     without an argument.

We will also handle odd cases where a user wants to
get information on a file or directory named "0", too.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
---
 git-svn.perl |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/git-svn.perl b/git-svn.perl
index cc35f50..df0ed90 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -796,8 +796,8 @@ sub cmd_commit_diff {
 }
 
 sub cmd_info {
-	my $path = canonicalize_path(shift or ".");
-	unless (scalar(@_) == 0) {
+	my $path = canonicalize_path(defined($_[0]) ? $_[0] : ".");
+	if (exists $_[1]) {
 		die "Too many arguments specified\n";
 	}
 
@@ -813,6 +813,10 @@ sub cmd_info {
 		die "Unable to determine upstream SVN information from ",
 		    "working tree history\n";
 	}
+
+	# canonicalize_path() will return "" to make libsvn 1.5.x happy,
+	$path = "." if $path eq "";
+
 	my $full_url = $url . ($path eq "." ? "" : "/$path");
 
 	if ($_url) {
-- 
1.6.0.rc1.69.g797ea

^ permalink raw reply related

* [PATCH 3/3] t9119: conditionally re-enable test depending on svn(1) version
From: Eric Wong @ 2008-08-05  7:35 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git, Eric Wong
In-Reply-To: <1217921718-25011-1-git-send-email-normalperson@yhbt.net>

I've tested this with svn 1.4.4

This also adds quoting to make it work odd characters
in the trash path.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
---
 t/t9119-git-svn-info.sh |   69 +++++++++++++++++++++++++++-------------------
 1 files changed, 40 insertions(+), 29 deletions(-)

diff --git a/t/t9119-git-svn-info.sh b/t/t9119-git-svn-info.sh
index 964011e..5fd36a1 100755
--- a/t/t9119-git-svn-info.sh
+++ b/t/t9119-git-svn-info.sh
@@ -5,8 +5,19 @@
 test_description='git-svn info'
 
 . ./lib-git-svn.sh
-say 'skipping svn-info test (has a race undiagnosed yet)'
-test_done
+
+set -e
+
+# Tested with: svn, version 1.4.4 (r25188)
+v=`svn --version | sed -n -e 's/^svn, version \(1\.4\.[0-9]\).*$/\1/p'`
+case $v in
+1.4.*)
+	;;
+*)
+	say "skipping svn-info test (SVN version: $v not supported)"
+	test_done
+	;;
+esac
 
 ptouch() {
 	perl -w -e '
@@ -25,7 +36,7 @@ ptouch() {
 	' "`svn info $2 | grep '^Text Last Updated:'`" "$1"
 }
 
-test_expect_success 'setup repository and import' "
+test_expect_success 'setup repository and import' '
 	mkdir info &&
 	cd info &&
 		echo FIRST > A &&
@@ -34,19 +45,19 @@ test_expect_success 'setup repository and import' "
 		mkdir directory &&
 		touch directory/.placeholder &&
 		ln -s directory symlink-directory &&
-		svn import -m 'initial' . $svnrepo &&
+		svn import -m "initial" . "$svnrepo" &&
 	cd .. &&
 	mkdir gitwc &&
 	cd gitwc &&
-		git-svn init $svnrepo &&
+		git-svn init "$svnrepo" &&
 		git-svn fetch &&
 	cd .. &&
-	svn co $svnrepo svnwc &&
+	svn co "$svnrepo" svnwc &&
 	ptouch svnwc/file gitwc/file &&
 	ptouch svnwc/directory gitwc/directory &&
 	ptouch svnwc/symlink-file gitwc/symlink-file &&
 	ptouch svnwc/symlink-directory gitwc/symlink-directory
-	"
+	'
 
 test_expect_success 'info' "
 	(cd svnwc; svn info) > expected.info &&
@@ -55,7 +66,7 @@ test_expect_success 'info' "
 	"
 
 test_expect_success 'info --url' '
-	test $(cd gitwc; git-svn info --url) = $svnrepo
+	test "$(cd gitwc; git-svn info --url)" = "$svnrepo"
 	'
 
 test_expect_success 'info .' "
@@ -65,7 +76,7 @@ test_expect_success 'info .' "
 	"
 
 test_expect_success 'info --url .' '
-	test $(cd gitwc; git-svn info --url .) = $svnrepo
+	test "$(cd gitwc; git-svn info --url .)" = "$svnrepo"
 	'
 
 test_expect_success 'info file' "
@@ -75,7 +86,7 @@ test_expect_success 'info file' "
 	"
 
 test_expect_success 'info --url file' '
-	test $(cd gitwc; git-svn info --url file) = "$svnrepo/file"
+	test "$(cd gitwc; git-svn info --url file)" = "$svnrepo/file"
 	'
 
 test_expect_success 'info directory' "
@@ -85,7 +96,7 @@ test_expect_success 'info directory' "
 	"
 
 test_expect_success 'info --url directory' '
-	test $(cd gitwc; git-svn info --url directory) = "$svnrepo/directory"
+	test "$(cd gitwc; git-svn info --url directory)" = "$svnrepo/directory"
 	'
 
 test_expect_success 'info symlink-file' "
@@ -95,7 +106,7 @@ test_expect_success 'info symlink-file' "
 	"
 
 test_expect_success 'info --url symlink-file' '
-	test $(cd gitwc; git-svn info --url symlink-file) \
+	test "$(cd gitwc; git-svn info --url symlink-file)" \
 	     = "$svnrepo/symlink-file"
 	'
 
@@ -108,7 +119,7 @@ test_expect_success 'info symlink-directory' "
 	"
 
 test_expect_success 'info --url symlink-directory' '
-	test $(cd gitwc; git-svn info --url symlink-directory) \
+	test "$(cd gitwc; git-svn info --url symlink-directory)" \
 	     = "$svnrepo/symlink-directory"
 	'
 
@@ -128,7 +139,7 @@ test_expect_success 'info added-file' "
 	"
 
 test_expect_success 'info --url added-file' '
-	test $(cd gitwc; git-svn info --url added-file) \
+	test "$(cd gitwc; git-svn info --url added-file)" \
 	     = "$svnrepo/added-file"
 	'
 
@@ -150,7 +161,7 @@ test_expect_success 'info added-directory' "
 	"
 
 test_expect_success 'info --url added-directory' '
-	test $(cd gitwc; git-svn info --url added-directory) \
+	test "$(cd gitwc; git-svn info --url added-directory)" \
 	     = "$svnrepo/added-directory"
 	'
 
@@ -173,7 +184,7 @@ test_expect_success 'info added-symlink-file' "
 	"
 
 test_expect_success 'info --url added-symlink-file' '
-	test $(cd gitwc; git-svn info --url added-symlink-file) \
+	test "$(cd gitwc; git-svn info --url added-symlink-file)" \
 	     = "$svnrepo/added-symlink-file"
 	'
 
@@ -196,7 +207,7 @@ test_expect_success 'info added-symlink-directory' "
 	"
 
 test_expect_success 'info --url added-symlink-directory' '
-	test $(cd gitwc; git-svn info --url added-symlink-directory) \
+	test "$(cd gitwc; git-svn info --url added-symlink-directory)" \
 	     = "$svnrepo/added-symlink-directory"
 	'
 
@@ -222,7 +233,7 @@ test_expect_success 'info deleted-file' "
 	"
 
 test_expect_success 'info --url file (deleted)' '
-	test $(cd gitwc; git-svn info --url file) \
+	test "$(cd gitwc; git-svn info --url file)" \
 	     = "$svnrepo/file"
 	'
 
@@ -243,7 +254,7 @@ test_expect_success 'info deleted-directory' "
 	"
 
 test_expect_success 'info --url directory (deleted)' '
-	test $(cd gitwc; git-svn info --url directory) \
+	test "$(cd gitwc; git-svn info --url directory)" \
 	     = "$svnrepo/directory"
 	'
 
@@ -265,7 +276,7 @@ test_expect_success 'info deleted-symlink-file' "
 	"
 
 test_expect_success 'info --url symlink-file (deleted)' '
-	test $(cd gitwc; git-svn info --url symlink-file) \
+	test "$(cd gitwc; git-svn info --url symlink-file)" \
 	     = "$svnrepo/symlink-file"
 	'
 
@@ -287,7 +298,7 @@ test_expect_success 'info deleted-symlink-directory' "
 	"
 
 test_expect_success 'info --url symlink-directory (deleted)' '
-	test $(cd gitwc; git-svn info --url symlink-directory) \
+	test "$(cd gitwc; git-svn info --url symlink-directory)" \
 	     = "$svnrepo/symlink-directory"
 	'
 
@@ -304,8 +315,8 @@ test_expect_success 'info unknown-file' "
 	"
 
 test_expect_success 'info --url unknown-file' '
-	test -z $(cd gitwc; git-svn info --url unknown-file \
-			2> ../actual.info--url-unknown-file) &&
+	test -z "$(cd gitwc; git-svn info --url unknown-file \
+			2> ../actual.info--url-unknown-file)" &&
 	git-diff expected.info-unknown-file actual.info--url-unknown-file
 	'
 
@@ -321,8 +332,8 @@ test_expect_success 'info unknown-directory' "
 	"
 
 test_expect_success 'info --url unknown-directory' '
-	test -z $(cd gitwc; git-svn info --url unknown-directory \
-			2> ../actual.info--url-unknown-directory) &&
+	test -z "$(cd gitwc; git-svn info --url unknown-directory \
+			2> ../actual.info--url-unknown-directory)" &&
 	git-diff expected.info-unknown-directory \
 		 actual.info--url-unknown-directory
 	'
@@ -344,8 +355,8 @@ test_expect_success 'info unknown-symlink-file' "
 	"
 
 test_expect_success 'info --url unknown-symlink-file' '
-	test -z $(cd gitwc; git-svn info --url unknown-symlink-file \
-			2> ../actual.info--url-unknown-symlink-file) &&
+	test -z "$(cd gitwc; git-svn info --url unknown-symlink-file \
+			2> ../actual.info--url-unknown-symlink-file)" &&
 	git-diff expected.info-unknown-symlink-file \
 		 actual.info--url-unknown-symlink-file
 	'
@@ -368,8 +379,8 @@ test_expect_success 'info unknown-symlink-directory' "
 	"
 
 test_expect_success 'info --url unknown-symlink-directory' '
-	test -z $(cd gitwc; git-svn info --url unknown-symlink-directory \
-			2> ../actual.info--url-unknown-symlink-directory) &&
+	test -z "$(cd gitwc; git-svn info --url unknown-symlink-directory \
+			2> ../actual.info--url-unknown-symlink-directory)" &&
 	git-diff expected.info-unknown-symlink-directory \
 		 actual.info--url-unknown-symlink-directory
 	'
-- 
1.6.0.rc1.69.g797ea

^ permalink raw reply related


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox