* Re: Getting correct tree layout when importing svn repo into git
From: Andreas Ericsson @ 2008-09-17 6:56 UTC (permalink / raw)
To: Michael Kerrisk; +Cc: Dmitry Potapov, mtk.manpages, git, michael.kerrisk
In-Reply-To: <c49095e30809162216m5c7885dbibbb022e65f43231c@mail.gmail.com>
Michael Kerrisk wrote:
> Hi Dimitry,
>
> On Tue, Sep 16, 2008 at 6:18 PM, Dmitry Potapov <dpotapov@gmail.com> wrote:
>> On Wed, Sep 17, 2008 at 01:40:36AM +0200, Michael Kerrisk wrote:
>>> $ git svn init file:///home/mtk/man-pages-rep/ -t tags -T trunk -b branches
>>>
>>> takes about half an hour to run, the other command (which I already
>>> started yesterday) seems to be taking (far) more than a day!
>> What version of Git do you use?
>
> 1.5.4.5, on Linux.
>
An upgrade would do you good.
>> If you use a version earlier than 1.5.6
>> than you can notice *considerable* speed up by upgrading to the latest
>
> How much is "considerable"? My import is *still* running.
>
The greatest factor will usually be network round trip time, so if
this is a one-shot conversion, rsync the repository to somewhere
close and run the import over a local network. I've had some "fun"
trying to import sourceforge svn repositories that were large-ish
but not huge (same seat you're in, basically), but since I get up
to 800ms round trip time from sweden, conversion took forever.
>>
>>> Therefore, so far, I have not had a chance to run the command to
>>> completion to see if it gives the desired result. The greatly
>>> increased tun time also made me suspicious about whether the command
>>> was going to do the right thing. And, I end up with a lot of strange
>>> looking tags in the (as yet incompletely) imported tree:
>>>
>>> $ git branch -a
>>> tags/man-pages-2.00
>>> tags/man-pages-2.00@117
>>> tags/man-pages-2.01
>>> tags/man-pages-2.01@145
>>> tags/man-pages-2.02
>>> tags/man-pages-2.02@184
>>> tags/man-pages-2.03
>>> tags/man-pages-2.03@232
>>> tags/man-pages-2.04
>>> tags/man-pages-2.04@283
>>>
>>> What are the @nnn tags about?
>> I have never encounted them. Are you sure that you import into a clean
>> Git repo?
>
> Yes. It's a clean repo in a new directory.
>
I've seen such tags before. They were added by an automatic build bot
as a marker to say "hey, I just built this".
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
^ permalink raw reply
* Re: [IRC/patches] Failed octopus merge does not clean up
From: Andreas Ericsson @ 2008-09-17 6:45 UTC (permalink / raw)
To: Jakub Narebski; +Cc: Junio C Hamano, Thomas Rast, git, Miklos Vajna
In-Reply-To: <200809170053.15341.jnareb@gmail.com>
Jakub Narebski wrote:
> Dnia wtorek 16. września 2008 02:20, Junio C Hamano napisał:
>> Junio C Hamano <gitster@pobox.com> writes:
>>> Thomas Rast <trast@student.ethz.ch> writes:
>>>
>>>> The merge says
>>>>
>>>> Trying simple merge with 5b3e4bb1c2d88d6967fb575729fbfc86df5eaec9
>>>> Simple merge did not work, trying automatic merge.
>>>> Auto-merging foo
>>>> ERROR: Merge conflict in foo
>>>> fatal: merge program failed
>>>> Automated merge did not work.
>>>> Should not be doing an Octopus.
>>>> Merge with strategy octopus failed.
>>> ...
>>> Read the second from the last line of what you were told by git. Run "git
>>> reset --hard" after that, perhaps.
>
> The problem, as far as I understand it, is not that octopus merge fails.
> The problem is that it fails halfway, and it leaves working are in
> inconsistent state: git-status output with its "unmerged" suggests that
> we are in the middle of the merge, but we are not.
>
>> By the way, there are three failure modes in Octopus.
>>
>> (0) your index (not work tree) is dirty; this is not limited to octopus
>> merge but any merge will be refused;
>
> IIRC the idea of stashing away changes, doing merge, and then unstashing
> was shot down as encouraging bad workflows, and more often than not
> leading only to mess in workdir and index.
>
>> (1) while it merges other heads one-by-one, it gets conflicts on an
>> earlier one, before it even attempts to merge all of them. Recording
>> the heads that it so far attempted to merge in MERGE_HEAD is wrong
>> (the result won't be an Octopus the end user wanted to carete), and
>> recording all the heads the user gave in MERGE_HEAD is even more
>> wrong (it hasn't even looked at the later heads yet, so there is no
>> way for the index or work tree to contain anything from them).
>>
>> The above is hitting this case.
>
> IMVHO the correct solution would be to rollback changes to the state
> before attempting a merge. I'd rather 'octopus' did its thing as
> transaction; contrary to ordinary merges if merge fails it doesn't
> mean necessary that it is in the state of resolvable conflict, state
> we can stop at. Perhaps (if it is still a shell script, doing git-stash
> at beginning, and either dropping or popping the stash at the end;
> or just saving old index if it is built-in).
>
>
> BTW. does it mean that "git merge a b" might be not the same as
> "git merge b a"?
>
No. Git merges all the sub-things together and then merges the result
of that jumble into the branch you're on.
Someone might have to correct me on that, but that's as far as I've
understood it.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
^ permalink raw reply
* Teach git status to do "git diff --name-status HEAD"
From: Martin Langhoff @ 2008-09-17 6:40 UTC (permalink / raw)
To: Git Mailing List
I just did
$ git checkout -b mdl19-offlinetony
A README.offline
M lib/javascript.php
(...)
A lib/offline/offlinemoodle.user.js
I *like* this "brief status" style - takes me back to my cvs days :-).
Perusing the source I found show_local_changes() which in turn led me
to trying `git diff --name-status HEAD`. Now, including 'HEAD' in an
alias defined in git config is going to lead to trouble... :-/
I might still make an alias to `git diff --name-status`. This would be
a great thing to have as git status "--brief" IMHO... :-)
cheers,
m
--
martin@laptop.org -- School Server Architect
- ask interesting questions
- don't get distracted with shiny stuff - working code first
- http://wiki.laptop.org/go/User:Martinlanghoff
^ permalink raw reply
* [PATCH] Clarified gitattributes documentation regarding custom hunk header.
From: Garry Dolley @ 2008-09-17 6:20 UTC (permalink / raw)
To: git; +Cc: Garry Dolley, Garry Dolley
From: Garry Dolley <gdolley@arpnetworks.com>
The only part of the hunk header that we can change is the "TEXT"
portion. Additionally, a few grammatical errors have been corrected.
Signed-off-by: Garry Dolley <gdolley@ucla.edu>
---
Documentation/gitattributes.txt | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/Documentation/gitattributes.txt b/Documentation/gitattributes.txt
index 6f3551d..e848c94 100644
--- a/Documentation/gitattributes.txt
+++ b/Documentation/gitattributes.txt
@@ -270,27 +270,27 @@ See linkgit:git[1] for details.
Defining a custom hunk-header
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-Each group of changes (called "hunk") in the textual diff output
+Each group of changes (called a "hunk") in the textual diff output
is prefixed with a line of the form:
@@ -k,l +n,m @@ TEXT
-The text is called 'hunk header', and by default a line that
-begins with an alphabet, an underscore or a dollar sign is used,
-which matches what GNU 'diff -p' output uses. This default
-selection however is not suited for some contents, and you can
-use customized pattern to make a selection.
+This is called a 'hunk header'. The "TEXT" portion is by default a line
+that begins with an alphabet, an underscore or a dollar sign; this
+matches what GNU 'diff -p' output uses. This default selection however
+is not suited for some contents, and you can use a customized pattern
+to make a selection.
-First in .gitattributes, you would assign the `diff` attribute
+First, in .gitattributes, you would assign the `diff` attribute
for paths.
------------------------
*.tex diff=tex
------------------------
-Then, you would define "diff.tex.funcname" configuration to
+Then, you would define a "diff.tex.funcname" configuration to
specify a regular expression that matches a line that you would
-want to appear as the hunk header, like this:
+want to appear as the hunk header "TEXT", like this:
------------------------
[diff "tex"]
--
1.6.0.1
^ permalink raw reply related
* Re: Getting correct tree layout when importing svn repo into git
From: Michael Kerrisk @ 2008-09-17 5:16 UTC (permalink / raw)
To: Dmitry Potapov; +Cc: mtk.manpages, git, michael.kerrisk
In-Reply-To: <20080917011816.GL28210@dpotapov.dyndns.org>
Hi Dimitry,
On Tue, Sep 16, 2008 at 6:18 PM, Dmitry Potapov <dpotapov@gmail.com> wrote:
> On Wed, Sep 17, 2008 at 01:40:36AM +0200, Michael Kerrisk wrote:
>>
>> $ git svn init file:///home/mtk/man-pages-rep/ -t tags -T trunk -b branches
>>
>> takes about half an hour to run, the other command (which I already
>> started yesterday) seems to be taking (far) more than a day!
>
> What version of Git do you use?
1.5.4.5, on Linux.
> If you use a version earlier than 1.5.6
> than you can notice *considerable* speed up by upgrading to the latest
How much is "considerable"? My import is *still* running.
> version of Git. Also, git-svn does not work well on Windows. Cygwin
> version is slow due to fork(), and MSYS Git has some other issues with
> Perl. So, if you want to convert a huge SVN repo,
My svn repo is not huge. 5000 commits, 176MB.
> it is better to do on
> Linux and using the latest version of Git. Perhaps, running on tmpfs may
> speed up the process even more.
>
>> Therefore, so far, I have not had a chance to run the command to
>> completion to see if it gives the desired result. The greatly
>> increased tun time also made me suspicious about whether the command
>> was going to do the right thing. And, I end up with a lot of strange
>> looking tags in the (as yet incompletely) imported tree:
>>
>> $ git branch -a
>> tags/man-pages-2.00
>> tags/man-pages-2.00@117
>> tags/man-pages-2.01
>> tags/man-pages-2.01@145
>> tags/man-pages-2.02
>> tags/man-pages-2.02@184
>> tags/man-pages-2.03
>> tags/man-pages-2.03@232
>> tags/man-pages-2.04
>> tags/man-pages-2.04@283
>>
>> What are the @nnn tags about?
>
> I have never encounted them. Are you sure that you import into a clean
> Git repo?
Yes. It's a clean repo in a new directory.
Cheers,
Michael
^ permalink raw reply
* [PATCH] git-svn: do a partial rebuild if rev_map is out-of-date
From: Deskin Miller @ 2008-09-17 3:13 UTC (permalink / raw)
To: git; +Cc: normalperson
Suppose you're using git-svn to work with a certain SVN repository.
Since you don't like 'git-svn fetch' to take forever, and you don't want
to accidentally interrupt it and end up corrupting your repository, you
set up a remote Git repository to mirror the SVN repository, which does
its own 'git-svn fetch' on a cronjob; now you can 'git-fetch' from the
Git mirror into your local repository, and still dcommit to SVN when you
have changes to push.
After you do this, though, git-svn will get very confused if you ever
try to do 'git-svn fetch' in your local repository again, since its
rev_map will differ from the branch's head, and it will be unable to
fetch new commits from SVN because of the metadata conflict. But all
the necessary metadata are there in the Git commit message; git-svn
already knows how to rebuild rev_map files that get blown away, by
using the metadata.
This commit will have git-svn do a partial rebuild of the rev_map to
match the true state of the branch, if it ever is used to fetch again.
This will only work for projects not using either noMetadata or
useSvmProps configuration options; if you are using these options,
git-svn will fall back to the previous behaviour.
Signed-off-by: Deskin Miller <deskinm@umich.edu>
---
It's possible that this can be extended to work with useSvmProps, but I don't
know how to do so.
git-svn.perl | 23 ++++++++++++++++++-----
1 files changed, 18 insertions(+), 5 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index 88066c9..2e7a8ce 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -2626,9 +2626,9 @@ sub rebuild_from_rev_db {
sub rebuild {
my ($self) = @_;
my $map_path = $self->map_path;
- return if (-e $map_path && ! -z $map_path);
+ my $partial = (-e $map_path && ! -z $map_path);
return unless ::verify_ref($self->refname.'^0');
- if ($self->use_svm_props || $self->no_metadata) {
+ if (!$partial && ($self->use_svm_props || $self->no_metadata)) {
my $rev_db = $self->rev_db_path;
$self->rebuild_from_rev_db($rev_db);
if ($self->use_svm_props) {
@@ -2638,10 +2638,12 @@ sub rebuild {
$self->unlink_rev_db_symlink;
return;
}
- print "Rebuilding $map_path ...\n";
+ print "Rebuilding $map_path ...\n" if (!$partial);
+ my ($base_rev, $head) = ($partial ? $self->rev_map_max_norebuild(1) :
+ (undef, undef));
my ($log, $ctx) =
command_output_pipe(qw/rev-list --pretty=raw --no-color --reverse/,
- $self->refname, '--');
+ ($head ? "^$head" : ""), $self->refname, '--');
my $metadata_url = $self->metadata_url;
remove_username($metadata_url);
my $svn_uuid = $self->ra_uuid;
@@ -2664,12 +2666,17 @@ sub rebuild {
($metadata_url && $url && ($url ne $metadata_url))) {
next;
}
+ if ($partial && $head) {
+ print "Partial-rebuilding $map_path ...\n";
+ print "Currently at $base_rev = $head\n";
+ $head = undef;
+ }
$self->rev_map_set($rev, $c);
print "r$rev = $c\n";
}
command_close_pipe($log, $ctx);
- print "Done rebuilding $map_path\n";
+ print "Done rebuilding $map_path\n" if (!$partial || !$head);
my $rev_db_path = $self->rev_db_path;
if (-f $self->rev_db_path) {
unlink $self->rev_db_path or croak "unlink: $!";
@@ -2809,6 +2816,12 @@ sub rev_map_set {
sub rev_map_max {
my ($self, $want_commit) = @_;
$self->rebuild;
+ my ($r, $c) = $self->rev_map_max_norebuild($want_commit);
+ $want_commit ? ($r, $c) : $r;
+}
+
+sub rev_map_max_norebuild {
+ my ($self, $want_commit) = @_;
my $map_path = $self->map_path;
stat $map_path or return $want_commit ? (0, undef) : 0;
sysopen(my $fh, $map_path, O_RDONLY) or croak "open: $!";
--
1.5.4.3
^ permalink raw reply related
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Brandon Casey @ 2008-09-17 1:25 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Jeff King, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161900340.17105@suse104.zenez.com>
Boyd Lynn Gerber wrote:
> So with path set so my /usr/gnu/bin/ is before any others this is what I
> get as the next failure. After a long run...
>
> * FAIL 5: alternation in pattern
>
> git config diff.java.funcname "^[
> ]*\(\(public\|static\).*\)$"
> git diff --no-index Beer.java Beer-correct.java |
> grep "^@@.*@@ public static void main("
>
>
> * failed 1 among 5 test(s)
> gmake[1]: *** [t4018-diff-funcname.sh] Error 1
> gmake[1]: Leaving directory `/home/zenez/build/osr6/git-1.6.0.2/t'
> gmake: *** [test] Error 2
That's the one, thanks.
And just so you know, this isn't a regression. It's just a new test that
was designed to reveal a shortcoming that no one knew existed before Arjen
discovered it.
-brandon
^ permalink raw reply
* Re: Getting correct tree layout when importing svn repo into git
From: Dmitry Potapov @ 2008-09-17 1:18 UTC (permalink / raw)
To: Michael Kerrisk; +Cc: mtk.manpages, git, michael.kerrisk
In-Reply-To: <c49095e30809161640o21cb89b7x17a9ac1b5b18054f@mail.gmail.com>
On Wed, Sep 17, 2008 at 01:40:36AM +0200, Michael Kerrisk wrote:
>
> $ git svn init file:///home/mtk/man-pages-rep/ -t tags -T trunk -b branches
>
> takes about half an hour to run, the other command (which I already
> started yesterday) seems to be taking (far) more than a day!
What version of Git do you use? If you use a version earlier than 1.5.6
than you can notice *considerable* speed up by upgrading to the latest
version of Git. Also, git-svn does not work well on Windows. Cygwin
version is slow due to fork(), and MSYS Git has some other issues with
Perl. So, if you want to convert a huge SVN repo, it is better to do on
Linux and using the latest version of Git. Perhaps, running on tmpfs may
speed up the process even more.
> Therefore, so far, I have not had a chance to run the command to
> completion to see if it gives the desired result. The greatly
> increased tun time also made me suspicious about whether the command
> was going to do the right thing. And, I end up with a lot of strange
> looking tags in the (as yet incompletely) imported tree:
>
> $ git branch -a
> tags/man-pages-2.00
> tags/man-pages-2.00@117
> tags/man-pages-2.01
> tags/man-pages-2.01@145
> tags/man-pages-2.02
> tags/man-pages-2.02@184
> tags/man-pages-2.03
> tags/man-pages-2.03@232
> tags/man-pages-2.04
> tags/man-pages-2.04@283
>
> What are the @nnn tags about?
I have never encounted them. Are you sure that you import into a clean
Git repo?
Dmitry
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Boyd Lynn Gerber @ 2008-09-17 1:02 UTC (permalink / raw)
To: Jeff King
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <20080916234624.GA14405@coredump.intra.peff.net>
On Tue, 16 Sep 2008, Jeff King wrote:
> On Tue, Sep 16, 2008 at 05:42:11PM -0600, Boyd Lynn Gerber wrote:
>> When I do a gmake test these 4 platforms all fail only these 2 tests.
>>
>> * FAIL 10: reinit
>> [...]
>> * FAIL 11: init with --template
>> [...]
>> gmake[1]: *** [t0001-init.sh] Error 1
>>
>> I have not had time to look into the failures. How many tests should I
>> see and pass. The first 40 all pass. Then 2 of 12 fail as above.
>
> These failures are unrelated to the described problem, and prevent the
> system from continuing on to run other tests.
>
> So if you get a chance, please:
>
> gmake test GIT_TEST_OPTS=--verbose
So with path set so my /usr/gnu/bin/ is before any others this is what I
get as the next failure. After a long run...
* FAIL 5: alternation in pattern
git config diff.java.funcname "^[
]*\(\(public\|static\).*\)$"
git diff --no-index Beer.java Beer-correct.java |
grep "^@@.*@@ public static void main("
* failed 1 among 5 test(s)
gmake[1]: *** [t4018-diff-funcname.sh] Error 1
gmake[1]: Leaving directory `/home/zenez/build/osr6/git-1.6.0.2/t'
gmake: *** [test] Error 2
--
Boyd Gerber <gerberb@zenez.com>
ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Brandon Casey @ 2008-09-17 0:58 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Jeff King, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161824470.17105@suse104.zenez.com>
Boyd Lynn Gerber wrote:
> On Tue, 16 Sep 2008, Brandon Casey wrote:
>> Boyd Lynn Gerber wrote:
>>> If I use gdiff or make gnu diff and put it in /usr/local/bin/ and change
>>> the path to have /usr/local/bin first it does not fail/.
>>>
>>> I have a /usr/gnu/bin/... where I have gdiff linked to diff.
>>
>> You must have done something like this in the past when you were
>> testing previous versions since the test_cmp variable has not changed.
>>
>> So, for future reference either have a diff that understands '-u' in
>> your path, or set the test_cmp environment variable.
>
> I had customized things so that any GNU util used gutil_name. This is
> the easiest way for me to distinguish between Native utils and GNU utils.
>
> Is there an easy way to have git use gcommand_name instead of
> command_name?
Not that I know of.
> I changed the path to run the git test, but not all my
> clients will allow be to have the gnu named command instead of the
> native command. There programs require the non GNU functionality. That
> is why I create a /usr/gnu/ with all the GNU stuff available for my
> use, but having to change paths back and forth just to run git is a pain
> when build/trouble shooting customer aplications.
I usually create a little compile script which sets the environment
variables the way I want, and calls make or gmake appropriately.
For the test suite you can set (if necessary):
test_cmp
TAR
'git grep' sometimes calls native grep. You can disallow this by setting
the Makefile variable NO_EXTERNAL_GREP.
And of course SHELL_PATH can be used to set the path to the shell that
all shell code should be executed with.
-brandon
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Boyd Lynn Gerber @ 2008-09-17 0:38 UTC (permalink / raw)
To: Brandon Casey
Cc: Jeff King, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <a4X38z5PMKaSj4KeLKBBqWb9elMD_Pp1n1eMqdmujRqMrr9xtvQAfA@cipher.nrlssc.navy.mil>
On Tue, 16 Sep 2008, Brandon Casey wrote:
> Boyd Lynn Gerber wrote:
>> If I use gdiff or make gnu diff and put it in /usr/local/bin/ and change
>> the path to have /usr/local/bin first it does not fail/.
>>
>> I have a /usr/gnu/bin/... where I have gdiff linked to diff.
>
> You must have done something like this in the past when you were testing
> previous versions since the test_cmp variable has not changed.
>
> So, for future reference either have a diff that understands '-u' in
> your path, or set the test_cmp environment variable.
I had customized things so that any GNU util used gutil_name. This is
the easiest way for me to distinguish between Native utils and GNU utils.
Is there an easy way to have git use gcommand_name instead of
command_name? I changed the path to run the git test, but not all my
clients will allow be to have the gnu named command instead of the native
command. There programs require the non GNU functionality. That is why I
create a /usr/gnu/ with all the GNU stuff available for my use, but
having to change paths back and forth just to run git is a pain when
build/trouble shooting customer aplications.
Thanks,
--
Boyd Gerber <gerberb@zenez.com>
ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Brandon Casey @ 2008-09-17 0:20 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Jeff King, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161811100.17105@suse104.zenez.com>
Boyd Lynn Gerber wrote:
> If I use gdiff or make gnu diff and put it in /usr/local/bin/ and change
> the path to have /usr/local/bin first it does not fail/.
>
> I have a /usr/gnu/bin/... where I have gdiff linked to diff.
You must have done something like this in the past when you were testing
previous versions since the test_cmp variable has not changed.
So, for future reference either have a diff that understands '-u' in your
path, or set the test_cmp environment variable.
-brandon
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Brandon Casey @ 2008-09-17 0:13 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Jeff King, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161808011.17105@suse104.zenez.com>
Boyd Lynn Gerber wrote:
> * expecting success:
>
> (
> unset GIT_CONFIG GIT_WORK_TREE GIT_CONFIG
>
> mkdir again &&
> cd again &&
> git init >out1 2>err1 &&
> git init >out2 2>err2
> ) &&
> grep "Initialized empty" again/out1 &&
> grep "Reinitialized existing" again/out2 &&
> >again/empty &&
> test_cmp again/empty again/err1 &&
> test_cmp again/empty again/err2
>
> Initialized empty Git repository in
> /home/zenez/build/osr6/git-1.6.0.2/t/trash directory/again/.git/
> Reinitialized existing Git repository in
> /home/zenez/build/osr6/git-1.6.0.2/t/trash directory/again/.git/
> diff: ERROR: Illegal option -- u
> Usage: diff [ -bcefhrC<n> ] file1 file2
The tests are failing at the test_cmp line. By default, test_cmp is
set to 'diff -u'. Perhaps you usually set test_cmp to something else
like 'cmp -s' or modify your path so that a more modern diff is used?
-brandon
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Boyd Lynn Gerber @ 2008-09-17 0:13 UTC (permalink / raw)
To: Jeff King
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <20080916234624.GA14405@coredump.intra.peff.net>
On Tue, 16 Sep 2008, Jeff King wrote:
> On Tue, Sep 16, 2008 at 05:42:11PM -0600, Boyd Lynn Gerber wrote:
>> When I do a gmake test these 4 platforms all fail only these 2 tests.
>>
>> * FAIL 10: reinit
>> [...]
>> * FAIL 11: init with --template
>> [...]
>> gmake[1]: *** [t0001-init.sh] Error 1
>>
>> I have not had time to look into the failures. How many tests should I
>> see and pass. The first 40 all pass. Then 2 of 12 fail as above.
>
> These failures are unrelated to the described problem, and prevent the
> system from continuing on to run other tests.
>
> So if you get a chance, please:
>
> 1. Run t0001 in verbose mode and report the results so we can get a
> better idea of what's failing:
>
> gmake test GIT_TEST_OPTS=--verbose
If I use gdiff or make gnu diff and put it in /usr/local/bin/ and change
the path to have /usr/local/bin first it does not fail/.
I have a /usr/gnu/bin/... where I have gdiff linked to diff.
# /usr/gnu/bin/diff --version
diff (GNU diffutils) 2.8.1
Copyright (C) 2002 Free Software Foundation, Inc.
This program comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of this program
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.
Written by Paul Eggert, Mike Haertel, David Hayes,
Richard Stallman, and Len Tower.
--
Boyd Gerber <gerberb@zenez.com>
ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Boyd Lynn Gerber @ 2008-09-17 0:10 UTC (permalink / raw)
To: Jeff King
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <20080916234624.GA14405@coredump.intra.peff.net>
On Tue, 16 Sep 2008, Jeff King wrote:
> On Tue, Sep 16, 2008 at 05:42:11PM -0600, Boyd Lynn Gerber wrote:
>> When I do a gmake test these 4 platforms all fail only these 2 tests.
>> * FAIL 10: reinit
>> [...]
>> * FAIL 11: init with --template
>> [...]
>> gmake[1]: *** [t0001-init.sh] Error 1
>>
> 1. Run t0001 in verbose mode and report the results so we can get a
> better idea of what's failing:
>
> gmake test GIT_TEST_OPTS=--verbose
* expecting success:
(
unset GIT_CONFIG GIT_WORK_TREE GIT_CONFIG
mkdir again &&
cd again &&
git init >out1 2>err1 &&
git init >out2 2>err2
) &&
grep "Initialized empty" again/out1 &&
grep "Reinitialized existing" again/out2 &&
>again/empty &&
test_cmp again/empty again/err1 &&
test_cmp again/empty again/err2
Initialized empty Git repository in
/home/zenez/build/osr6/git-1.6.0.2/t/trash directory/again/.git/
Reinitialized existing Git repository in
/home/zenez/build/osr6/git-1.6.0.2/t/trash directory/again/.git/
diff: ERROR: Illegal option -- u
Usage: diff [ -bcefhrC<n> ] file1 file2
* FAIL 10: reinit
(
unset GIT_CONFIG GIT_WORK_TREE GIT_CONFIG
mkdir again &&
cd again &&
git init >out1 2>err1 &&
git init >out2 2>err2
) &&
grep "Initialized empty" again/out1 &&
grep "Reinitialized existing" again/out2 &&
>again/empty &&
test_cmp again/empty again/err1 &&
test_cmp again/empty again/err2
* expecting success:
mkdir template-source &&
echo content >template-source/file &&
(
mkdir template-custom &&
cd template-custom &&
git init --template=../template-source
) &&
test_cmp template-source/file template-custom/.git/file
Initialized empty Git repository in
/home/zenez/build/osr6/git-1.6.0.2/t/trash directory/template-custom/.git/
diff: ERROR: Illegal option -- u
Usage: diff [ -bcefhrC<n> ] file1 file2
* FAIL 11: init with --template
mkdir template-source &&
echo content >template-source/file &&
(
mkdir template-custom &&
cd template-custom &&
git init --template=../template-source
) &&
test_cmp template-source/file template-custom/.git/file
* expecting success:
(
mkdir template-plain &&
cd template-plain &&
git init
) &&
test -f template-plain/.git/info/exclude &&
(
mkdir template-blank &&
cd template-blank &&
git init --template=
) &&
! test -f template-blank/.git/info/exclude
Initialized empty Git repository in
/home/zenez/build/osr6/git-1.6.0.2/t/trash directory/template-plain/.git/
Initialized empty Git repository in
/home/zenez/build/osr6/git-1.6.0.2/t/trash directory/template-blank/.git/
> 2. Run t4018 individually and report on the results:
>
> cd t && gmake t4018-diff-funcname.sh
3 systems all give me this.
$ cd t && gmake t4018-diff-funcname.sh
*** t4018-diff-funcname.sh ***
t4018-diff-funcname.sh: syntax error at line 52: `(' unexpected
gmake: *** [t4018-diff-funcname.sh] Error 2
--
Boyd Gerber <gerberb@zenez.com>
ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
^ permalink raw reply
* [PATCH] Teach git diff about Objective-C syntax
From: Jonathan del Strother @ 2008-09-17 0:07 UTC (permalink / raw)
To: git; +Cc: Jonathan del Strother
In-Reply-To: <20080916233923.GF4829@genesis.frugalware.org>
Add support for recognition of Objective-C class & instance methods, C functions, and class implementation/interfaces.
Signed-off-by: Jonathan del Strother <jon.delStrother@bestbefore.tv>
---
Documentation/gitattributes.txt | 2 ++
diff.c | 6 ++++++
2 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/Documentation/gitattributes.txt b/Documentation/gitattributes.txt
index 6f3551d..c1f13e2 100644
--- a/Documentation/gitattributes.txt
+++ b/Documentation/gitattributes.txt
@@ -315,6 +315,8 @@ patterns are available:
- `java` suitable for source code in the Java language.
+- `objc` suitable for source code in the Objective-C language.
+
- `pascal` suitable for source code in the Pascal/Delphi language.
- `php` suitable for source code in the PHP language.
diff --git a/diff.c b/diff.c
index 998dcaa..5f4e63b 100644
--- a/diff.c
+++ b/diff.c
@@ -1403,6 +1403,12 @@ static struct builtin_funcname_pattern {
"^[ ]*\\(\\([ ]*"
"[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}"
"[ ]*([^;]*\\)$" },
+ { "objc", "^[\t ]*\\([-+][\t ]*([\t ]*[A-Za-z_][A-Za-z_0-9]*.*).*\\)$" /* Objective-C methods */
+ "\\|"
+ "^[\t ]*\\(\\([\t ]*[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}[\t ]*([^;]*\\)$" /* C functions */
+ "\\|"
+ "^@\\(implementation\\|interface\\|protocol\\).*" /* Objective-C class/protocol definitions */
+ },
{ "pascal", "^\\(\\(procedure\\|function\\|constructor\\|"
"destructor\\|interface\\|implementation\\|"
"initialization\\|finalization\\)[ \t]*.*\\)$"
--
1.6.0.2
^ permalink raw reply related
* Re: Submitting patches from unsubscribed authors?
From: Jeff King @ 2008-09-16 23:48 UTC (permalink / raw)
To: Jonathan del Strother; +Cc: Git Mailing List
In-Reply-To: <57518fd10809161644v348bd347xeed0bc7cb35805a1@mail.gmail.com>
On Wed, Sep 17, 2008 at 12:44:55AM +0100, Jonathan del Strother wrote:
> I assumed that I was confusing git-send-email with my multiple email
> addresses and that was a broken header. git-am will work fine with
> that second From: line being embedded in the commit message, then?
Yep. It's a feature. See git-am(1), section "DISCUSSION".
-Peff
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Jeff King @ 2008-09-16 23:46 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161738010.17105@suse104.zenez.com>
On Tue, Sep 16, 2008 at 05:42:11PM -0600, Boyd Lynn Gerber wrote:
> When I do a gmake test these 4 platforms all fail only these 2 tests.
>
> * FAIL 10: reinit
> [...]
> * FAIL 11: init with --template
> [...]
> gmake[1]: *** [t0001-init.sh] Error 1
>
> I have not had time to look into the failures. How many tests should I
> see and pass. The first 40 all pass. Then 2 of 12 fail as above.
These failures are unrelated to the described problem, and prevent the
system from continuing on to run other tests.
So if you get a chance, please:
1. Run t0001 in verbose mode and report the results so we can get a
better idea of what's failing:
gmake test GIT_TEST_OPTS=--verbose
2. Run t4018 individually and report on the results:
cd t && gmake t4018-diff-funcname.sh
-Peff
^ permalink raw reply
* Re: Submitting patches from unsubscribed authors?
From: Jonathan del Strother @ 2008-09-16 23:44 UTC (permalink / raw)
To: Jeff King; +Cc: Git Mailing List
In-Reply-To: <20080916233613.GA14251@coredump.intra.peff.net>
On Wed, Sep 17, 2008 at 12:36 AM, Jeff King <peff@peff.net> wrote:
> On Wed, Sep 17, 2008 at 12:24:48AM +0100, Jonathan del Strother wrote:
>
>> Is it possible to submit a patch to the mailing list, from an author
>> that isn't subscribed? Last time I submitted a patch I went via my
>
> Yes. The list accepts mail from non-subscribers.
Ah. I was getting mail rejected when I was trying to use my real
email address, but now I look more closely, they're rejected because I
was sending via a local postfix server & it didn't recognise the
hostname. Doh...
>> throwaway email address, and so that was used as the commit author.
>> It looks like "git am" is always going to just use the email address
>> used to post to the mailing list as the email address, but I'm sure in
>> the past that my patches have appeared under my real email. Was that
>> just manual intervention by the maintainer?
>
> Yes, it pulls it from the From: header. However, you can override that
> by including
>
> From: Your Real Name <yourrealaddress>
>
> as the first line of the mail. git-send-email will do this for you
> automagically if the commit author and your email sending address are
> not the same.
>
> Look at some of your previous patches to the list; they have this line.
>
I assumed that I was confusing git-send-email with my multiple email
addresses and that was a broken header. git-am will work fine with
that second From: line being embedded in the commit message, then?
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Boyd Lynn Gerber @ 2008-09-16 23:42 UTC (permalink / raw)
To: Jeff King
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <20080916233220.GA14173@coredump.intra.peff.net>
On Tue, 16 Sep 2008, Jeff King wrote:
> On Tue, Sep 16, 2008 at 05:25:46PM -0600, Boyd Lynn Gerber wrote:
>>> I wonder if this is the right fix? Right now the GNU regex library is
>>> necessary for Darwin, FreeBSD and AIX. I can add IRIX6.5 and Solaris 7
>>> to that list. Have newer Solaris's been tested yet? (Jeff?) I wonder if
>>> the new test which triggers this flaw has been tested on the other
>>> non-GNU platforms in the Makefile which have not been updated. Boyd
>>> Lynn Gerber and his 12 platforms comes to mind.
>>
>> Someone forwarded me this email and asked if I had tested it. I have not.
>> Where is the easiest place to get it to test with the various platforms?
>> I will check it out on 3-5 of them. I now have 1.6.0.2 on 5 platforms
>> running and working. I have not had the time to get it on the other's
>> yet.
>
> The problematic test is in 1.6.0.2; if you can run t4018-diff-funcname
> successfully, then I believe you are not affected.
When I do a gmake test these 4 platforms all fail only these 2 tests.
* FAIL 10: reinit
(
unset GIT_CONFIG GIT_WORK_TREE GIT_CONFIG
mkdir again &&
cd again &&
git init >out1 2>err1 &&
git init >out2 2>err2
) &&
grep "Initialized empty" again/out1 &&
grep "Reinitialized existing" again/out2 &&
>again/empty &&
test_cmp again/empty again/err1 &&
test_cmp again/empty again/err2
* FAIL 11: init with --template
mkdir template-source &&
echo content >template-source/file &&
(
mkdir template-custom &&
cd template-custom &&
git init --template=../template-source
) &&
test_cmp template-source/file template-custom/.git/file
* ok 12: init with --template (blank)
* failed 2 among 12 test(s)
gmake[1]: *** [t0001-init.sh] Error 1
gmake[1]: Leaving directory `/home/zenez/build/osr6/git-1.6.0.2/t'
gmake: *** [test] Error 2
I have not had time to look into the failures. How many tests should I
see and pass. The first 40 all pass. Then 2 of 12 fail as above.
--
Boyd Gerber <gerberb@zenez.com>
ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
^ permalink raw reply
* Re: Getting correct tree layout when importing svn repo into git
From: Michael Kerrisk @ 2008-09-16 23:40 UTC (permalink / raw)
To: Dmitry Potapov; +Cc: mtk.manpages, git, michael.kerrisk
In-Reply-To: <37fcd2780809161620v38d9ade0sc1a2715f79501c6f@mail.gmail.com>
Hello Dmitry,
On Wed, Sep 17, 2008 at 1:20 AM, Dmitry Potapov <dpotapov@gmail.com> wrote:
> On Wed, Sep 17, 2008 at 2:05 AM, Michael Kerrisk
> <mtk.manpages@googlemail.com> wrote:
>>
>> I'm currently trying to import an svn repository, along with its tags,
>> into git, and everything seems okay except that after the import I
>> expect to have the following structure to my checked out repository:
>>
>> [root-dir]
>> .git
>> <checked-out-files>
>>
>> But instead I end up with
>>
>> [root-dir]
>> .git
>> man-pages <-- name of my svn project
>> <checked-out-files>
>>
>> I've tried out a few different command-line flag settings but so far I
>> haven't managed to get the desired layout. I guess that I'm missing
>> something trivial, but I haven't worked out what it is so far.
>>
>> The commands I'm using to do the import are:
>>
>> $ git svn init file:///home/mtk/man-pages-rep/ -t tags -T trunk -b branches
>
> Probably, you want to run:
>
> $ git svn init file:///home/mtk/man-pages-rep/ -t tags -T
> trunk/man-pages -b branches
I had wondered about this. And I haven't yet had a chance to verify
the result. The reason is that whereas the command:
$ git svn init file:///home/mtk/man-pages-rep/ -t tags -T trunk -b branches
takes about half an hour to run, the other command (which I already
started yesterday) seems to be taking (far) more than a day!
Therefore, so far, I have not had a chance to run the command to
completion to see if it gives the desired result. The greatly
increased tun time also made me suspicious about whether the command
was going to do the right thing. And, I end up with a lot of strange
looking tags in the (as yet incompletely) imported tree:
$ git branch -a
tags/man-pages-2.00
tags/man-pages-2.00@117
tags/man-pages-2.01
tags/man-pages-2.01@145
tags/man-pages-2.02
tags/man-pages-2.02@184
tags/man-pages-2.03
tags/man-pages-2.03@232
tags/man-pages-2.04
tags/man-pages-2.04@283
What are the @nnn tags about?
By tomorrow, probably the command will complete and I can see whether
it produces the desired result. But why does it take so much longer
to run this version of the command?
Cheers,
Michael
^ permalink raw reply
* Re: [PATCH] Teach git diff about Objective-C syntax
From: Miklos Vajna @ 2008-09-16 23:39 UTC (permalink / raw)
To: Jonathan del Strother; +Cc: git
In-Reply-To: <1221607297-33212-1-git-send-email-jon.delStrother@bestbefore.tv>
[-- Attachment #1: Type: text/plain, Size: 481 bytes --]
On Wed, Sep 17, 2008 at 12:21:37AM +0100, Jonathan del Strother <jon.delStrother@bestbefore.tv> wrote:
> + { "objc", "^[\t ]*\\([-+][\t ]*([\t ]*[A-Za-z_][A-Za-z_0-9]*.*).*\\)$" // Objective-C methods
> + "\\|"
> + "^[\t ]*\\(\\([\t ]*[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}[\t ]*([^;]*\\)$" // C functions
> + "\\|"
> + "^@\\(implementation\\|interface\\|protocol\\).*" // Objective-C class/protocol definitions
Please avoid C++-style comments. Just use /* */.
Thanks.
[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]
^ permalink raw reply
* Re: Submitting patches from unsubscribed authors?
From: Jeff King @ 2008-09-16 23:36 UTC (permalink / raw)
To: Jonathan del Strother; +Cc: Git Mailing List
In-Reply-To: <57518fd10809161624u3b2937dmd36e0fc962ea7a7@mail.gmail.com>
On Wed, Sep 17, 2008 at 12:24:48AM +0100, Jonathan del Strother wrote:
> Is it possible to submit a patch to the mailing list, from an author
> that isn't subscribed? Last time I submitted a patch I went via my
Yes. The list accepts mail from non-subscribers.
> throwaway email address, and so that was used as the commit author.
> It looks like "git am" is always going to just use the email address
> used to post to the mailing list as the email address, but I'm sure in
> the past that my patches have appeared under my real email. Was that
> just manual intervention by the maintainer?
Yes, it pulls it from the From: header. However, you can override that
by including
From: Your Real Name <yourrealaddress>
as the first line of the mail. git-send-email will do this for you
automagically if the commit author and your email sending address are
not the same.
Look at some of your previous patches to the list; they have this line.
-Peff
^ permalink raw reply
* Re: [RFC/PATCH] Use compatibility regex library for OSX/Darwin
From: Jeff King @ 2008-09-16 23:32 UTC (permalink / raw)
To: Boyd Lynn Gerber
Cc: Brandon Casey, Arjen Laarhoven, git, Mike Ralphson, Johannes Sixt,
Junio C Hamano
In-Reply-To: <alpine.LNX.1.10.0809161722580.18110@suse104.zenez.com>
On Tue, Sep 16, 2008 at 05:25:46PM -0600, Boyd Lynn Gerber wrote:
>> I wonder if this is the right fix? Right now the GNU regex library is
>> necessary for Darwin, FreeBSD and AIX. I can add IRIX6.5 and Solaris 7
>> to that list. Have newer Solaris's been tested yet? (Jeff?) I wonder if
>> the new test which triggers this flaw has been tested on the other
>> non-GNU platforms in the Makefile which have not been updated. Boyd
>> Lynn Gerber and his 12 platforms comes to mind.
>
> Someone forwarded me this email and asked if I had tested it. I have not.
> Where is the easiest place to get it to test with the various platforms?
> I will check it out on 3-5 of them. I now have 1.6.0.2 on 5 platforms
> running and working. I have not had the time to get it on the other's
> yet.
The problematic test is in 1.6.0.2; if you can run t4018-diff-funcname
successfully, then I believe you are not affected.
-Peff
^ permalink raw reply
* [PATCH] Teach git diff about Objective-C syntax
From: Jonathan del Strother @ 2008-09-16 23:21 UTC (permalink / raw)
To: git; +Cc: Jonathan del Strother
Add support for recognition of Objective-C class & instance methods, C functions, and class implementation/interfaces.
Signed-off-by: Jonathan del Strother <jon.delStrother@bestbefore.tv>
---
Documentation/gitattributes.txt | 2 ++
diff.c | 6 ++++++
2 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/Documentation/gitattributes.txt b/Documentation/gitattributes.txt
index 6f3551d..c1f13e2 100644
--- a/Documentation/gitattributes.txt
+++ b/Documentation/gitattributes.txt
@@ -315,6 +315,8 @@ patterns are available:
- `java` suitable for source code in the Java language.
+- `objc` suitable for source code in the Objective-C language.
+
- `pascal` suitable for source code in the Pascal/Delphi language.
- `php` suitable for source code in the PHP language.
diff --git a/diff.c b/diff.c
index 998dcaa..6ed8322 100644
--- a/diff.c
+++ b/diff.c
@@ -1403,6 +1403,12 @@ static struct builtin_funcname_pattern {
"^[ ]*\\(\\([ ]*"
"[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}"
"[ ]*([^;]*\\)$" },
+ { "objc", "^[\t ]*\\([-+][\t ]*([\t ]*[A-Za-z_][A-Za-z_0-9]*.*).*\\)$" // Objective-C methods
+ "\\|"
+ "^[\t ]*\\(\\([\t ]*[A-Za-z_][A-Za-z_0-9]*\\)\\{2,\\}[\t ]*([^;]*\\)$" // C functions
+ "\\|"
+ "^@\\(implementation\\|interface\\|protocol\\).*" // Objective-C class/protocol definitions
+ },
{ "pascal", "^\\(\\(procedure\\|function\\|constructor\\|"
"destructor\\|interface\\|implementation\\|"
"initialization\\|finalization\\)[ \t]*.*\\)$"
--
1.6.0.2
^ permalink raw reply related
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox