* [PATCH 1/2] send-email: refactor and ensure prompting doesn't loop forever
From: Jay Soffian @ 2009-03-29 1:39 UTC (permalink / raw)
To: git; +Cc: Jay Soffian, Matthieu Moy, Junio C Hamano
Several places in send-email prompt for input, and will do so forever
when the input is EOF. This is poor behavior when send-email is run
unattended (say from cron).
This patch refactors the prompting to an ask() function which takes a
prompt, an optional default, and an optional regex to validate the
input. The function returns on EOF, or if a default is provided and the
user simply types return, or if the input passes the validating regex
(which accepts all input by default). The ask() function gives up after
10 tries in case of invalid input.
There are three callers of the function:
1) "Who should the emails appear to be from?" which provides a default
sender. Previously the user would have to type ctrl-d to accept the
default. Now the user can just hit return, or type ctrl-d.
2) "Who should the emails be sent to?". Previously this prompt passed a
second argument ("") to $term->readline() which was ignored. I believe
the intent was to allow the user to just hit return. Now the user
can do so, or type ctrl-d.
3) "Send this email?". Previously this prompt would loop forever until
it got a valid reply. Now it stops prompting on EOF or a valid reply. In
the case where confirm = "inform", it now defaults to "y" on EOF or the
user hitting return, otherwise an invalid reply causes send-email to
terminate.
A followup patch adds tests for the new functionality.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
---
git-send-email.perl | 66 ++++++++++++++++++++++++++------------------------
1 files changed, 34 insertions(+), 32 deletions(-)
This and the next patch address the bug reported by Matthieu in
http://article.gmane.org/gmane.comp.version-control.git/114577
Of course, I've been wanting to refactor the prompting for a while, so I used
the bug fix as an excuse to do so.
j.
diff --git a/git-send-email.perl b/git-send-email.perl
index 546d2eb..f0405c8 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -606,32 +606,40 @@ EOT
do_edit(@files);
}
+sub ask {
+ my ($prompt, %arg) = @_;
+ my $valid_re =$arg{valid_re} || ""; # "" matches anything
+ my $default = $arg{default};
+ my $resp;
+ my $i = 0;
+ while ($i++ < 10) {
+ $resp = $term->readline($prompt);
+ if (!defined $resp) { # EOF
+ print "\n";
+ return defined $default ? $default : undef;
+ }
+ if ($resp eq '' and defined $default) {
+ return $default;
+ }
+ if ($resp =~ /$valid_re/) {
+ return $resp;
+ }
+ }
+ return undef;
+}
+
my $prompting = 0;
if (!defined $sender) {
$sender = $repoauthor || $repocommitter || '';
-
- while (1) {
- $_ = $term->readline("Who should the emails appear to be from? [$sender] ");
- last if defined $_;
- print "\n";
- }
-
- $sender = $_ if ($_);
+ $sender = ask("Who should the emails appear to be from? [$sender] ",
+ default => $sender);
print "Emails will be sent from: ", $sender, "\n";
$prompting++;
}
if (!@to) {
-
-
- while (1) {
- $_ = $term->readline("Who should the emails be sent to? ", "");
- last if defined $_;
- print "\n";
- }
-
- my $to = $_;
- push @to, parse_address_line($to);
+ my $to = ask("Who should the emails be sent to? ");
+ push @to, parse_address_line($to) if defined $to; # sanitized/validated later
$prompting++;
}
@@ -651,13 +659,8 @@ sub expand_aliases {
@bcclist = expand_aliases(@bcclist);
if ($thread && !defined $initial_reply_to && $prompting) {
- while (1) {
- $_= $term->readline("Message-ID to be used as In-Reply-To for the first email? ", $initial_reply_to);
- last if defined $_;
- print "\n";
- }
-
- $initial_reply_to = $_;
+ $initial_reply_to = ask(
+ "Message-ID to be used as In-Reply-To for the first email? ");
}
if (defined $initial_reply_to) {
$initial_reply_to =~ s/^\s*<?//;
@@ -839,8 +842,10 @@ X-Mailer: git-send-email $gitversion
if ($needs_confirm && !$dry_run) {
print "\n$header\n";
+ my $ask_default;
if ($needs_confirm eq "inform") {
$confirm_unconfigured = 0; # squelch this message for the rest of this run
+ $ask_default = "y"; # assume yes on EOF since user hasn't explicitly asked for confirmation
print " The Cc list above has been expanded by additional\n";
print " addresses found in the patch commit message. By default\n";
print " send-email prompts before sending whenever this occurs.\n";
@@ -851,13 +856,10 @@ X-Mailer: git-send-email $gitversion
print " To retain the current behavior, but squelch this message,\n";
print " run 'git config --global sendemail.confirm auto'.\n\n";
}
- while (1) {
- chomp ($_ = $term->readline(
- "Send this email? ([y]es|[n]o|[q]uit|[a]ll): "
- ));
- last if /^(?:yes|y|no|n|quit|q|all|a)/i;
- print "\n";
- }
+ $_ = ask("Send this email? ([y]es|[n]o|[q]uit|[a]ll): ",
+ valid_re => qr/^(?:yes|y|no|n|quit|q|all|a)/i,
+ default => $ask_default);
+ die "Send this email reply required" unless defined $_;
if (/^n/i) {
return;
} elsif (/^q/i) {
--
1.6.2.313.g33352
^ permalink raw reply related
* Re: [PATCH 1/2] send-email: refactor and ensure prompting doesn't loop forever
From: Jay Soffian @ 2009-03-29 1:48 UTC (permalink / raw)
To: git; +Cc: Jay Soffian, Matthieu Moy, Junio C Hamano
In-Reply-To: <1238290751-57461-1-git-send-email-jaysoffian@gmail.com>
On Sat, Mar 28, 2009 at 9:39 PM, Jay Soffian <jaysoffian@gmail.com> wrote:
> There are three callers of the function:
Where by "three" I mean "four". Please use this commit message instead:
---snip---
Several places in send-email prompt for input, and will do so forever
when the input is EOF. This is poor behavior when send-email is run
unattended (say from cron).
This patch refactors the prompting to an ask() function which takes a
prompt, an optional default, and an optional regex to validate the
input. The function returns on EOF, or if a default is provided and the
user simply types return, or if the input passes the validating regex
(which accepts all input by default). The ask() function gives up after
10 tries in case of invalid input.
There are four callers of the function:
1) "Who should the emails appear to be from?" which provides a default
sender. Previously the user would have to type ctrl-d to accept the
default. Now the user can just hit return, or type ctrl-d.
2) "Who should the emails be sent to?". Previously this prompt passed a
second argument ("") to $term->readline() which was ignored. I believe
the intent was to allow the user to just hit return. Now the user
can do so, or type ctrl-d.
3) "Message-ID to be used as In-Reply-To for the first email?".
Previously this prompt passed a second argument (effectively undef) to
$term->readline() which was ignored. I believe the intent was the same
as for (2), to allow the user to just hit return. Now the user can do
so, or type ctrl-d.
4) "Send this email?". Previously this prompt would loop forever until
it got a valid reply. Now it stops prompting on EOF or a valid reply. In
the case where confirm = "inform", it now defaults to "y" on EOF or the
user hitting return, otherwise an invalid reply causes send-email to
terminate.
A followup patch adds tests for the new functionality.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
---snip---
Thanks,
j.
^ permalink raw reply
* Re: git svn fails to work
From: Dmitry Potapov @ 2009-03-29 4:38 UTC (permalink / raw)
To: Aaron Gray; +Cc: Git Mailing List
In-Reply-To: <7D416C4D4B0B43FB9E0A04FA641CCEE5@HPLAPTOP>
On Sun, Mar 29, 2009 at 12:42 AM, Aaron Gray
<aaronngray.lists@googlemail.com> wrote:
>
> The commands
>
> git svn clone http://llvm.org/svn/llvm-project/llvm/trunk
>
> when connection fails I do a :-
>
> git svn fetch
>
> gitweb is not updating at all to show any change in the repository.
"git svn fetch" only updates the remote branch. In the same way as
"git fetch" only fetches changes from the remote repo and updates
the remote branch. You can see only local branches with gitweb.
So, you may want to run "git svn rebase" instead. (Note: the command
is "git svn rebase" and not "git clone rebase" as you wrote earlier).
"git svn rebase" fetches all changes as "git svn fetch" does but then it
rebases your local commits on the current branch on top of the svn
remote branch. If you do not have any local commits then it just
updates the top of the current branch to be the same.
Note: Running "git svn rebase" requires that your working tree is
clean (no uncommitted changes).
You can always see all branches and what changes they have by
running:
gitk --all &
Dmitry
^ permalink raw reply
* Re: On git 1.6 (novice's opinion)
From: Bryan Donlan @ 2009-03-29 5:41 UTC (permalink / raw)
To: Ulrich Windl; +Cc: git
In-Reply-To: <49CC8C90.12268.242CEFCE@Ulrich.Windl.rkdvmks1.ngate.uni-regensburg.de>
On Fri, Mar 27, 2009 at 3:21 AM, Ulrich Windl
<ulrich.windl@rz.uni-regensburg.de> wrote:
> 3) "git undo": If possible undo the effects of the last command.
You can roll back the state of most local references by using the git
reflog (see git reflog --help for more information). This covers most
situations - but note that it only works to roll back to a committed
state, and won't save any uncommitted data at all.
^ permalink raw reply
* Re: svn clone Checksum mismatch question
From: Eric Wong @ 2009-03-29 6:08 UTC (permalink / raw)
To: Anton Gyllenberg; +Cc: git
In-Reply-To: <83dfc36c0903270418q59a81290xcb8043b8c037be18@mail.gmail.com>
Anton Gyllenberg <anton@iki.fi> wrote:
> I hope I didn't hijack the thread with an unrelated issue.
No worries if you did. You helped me find a stupid bug in git-svn
that's been there for 3 years. I couldn't help the original poster at
all since he was working on a private repo and I can't support git-svn
under Windows.
> 2009/3/26 Anton Gyllenberg <anton@iki.fi>:
> > I don't know if this is the same issue, but the I get a similar error
> > on the public twisted-python repository on both windows and linux,
> > with several different versions and plenty of free disk space. As this
> > is a publicly accessible repository it should be easy to reproduce:
> >
> > git svn init -s svn://svn.twistedmatrix.com/svn/Twisted twisted
> > cd twisted
> > git svn fetch -r 13611:HEAD
> >
> > This ultimately dies with the following error:
> > W: +empty_dir: trunk/doc/core/howto/listings/finger/finger
> > r13612 = f6d995ac255e3dfa08a517a6e72fbcfe63feaaa0 (trunk)
> > Checksum mismatch:
> > branches/foom/--omg-optimized/twisted/internet/cdefer/cdefer.pyx
> > 264b0c5f7b3a00d401d1a5dcce67a3734f0eede3
> > expected: c7ccddd195f132926e20bab573da7ef3
> > got: f006323ff4714ca52c0228ce6390d415
>
> is branches/foom/--omg-optimized (like with the branch name being
> foom/--omg-optimized), not just branches/foom. Is think git-svn relies
> on the standard layout being branches directly under the branches/
> directory, but I don't see how this would get the paths mixed up like
> this.
Root problem: I misused "git ls-tree" for 3 years and nobody noticed.
At least I'm glad the checksum verification every step of the way caught
this bug and prevented propagating it into repository corruption.
> Looking at what was done around this commit one finds odd stuff, like
> deleting directories in trunk and then copying from a previous
> revision of trunk to under the branch:
> http://twistedmatrix.com/trac/changeset/13611
>
> I created a local test svn repository and tried to do something
> similar but git-svn had no problem with my test.
I was fooled by the weird copy sequences, too.
> This is issue is not critical for me in any way but if somebody wants
> to look into it I am happy to help out.
I guess few folks in the UNIX world are crazy enough to make pathnames
prefixed with dashes :) But I do wonder how/if many repositories out
there failed and nobody bothered to report it...
Patch in reply
--
Eric Wong
^ permalink raw reply
* [PATCH] git-svn: fix ls-tree usage with dash-prefixed paths
From: Eric Wong @ 2009-03-29 6:10 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Anton Gyllenberg
In-Reply-To: <20090329060858.GB15773@dcvr.yhbt.net>
To find the blob object name given a tree and pathname, we were
incorrectly calling "git ls-tree" with a "--" argument followed
by the pathname of the file we wanted to get.
git ls-tree <TREE> -- --dashed/path/name.c
Unlike many command-line interfaces, the "--" alone does not
symbolize the end of non-option arguments on the command-line.
ls-tree interprets the "--" as a prefix to match against, thus
the entire contents of the --dashed/* hierarchy would be
returned because the "--" matches "--dashed" and every path
under it.
Thanks to Anton Gyllenberg for pointing me toward the
Twisted repository as a real-world example of this case.
Signed-off-by: Eric Wong <normalperson@yhbt.net>
---
Junio: This can go to maint. Thanks
git-svn.perl | 15 +++++++++------
1 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index 8be6be0..f21cfb4 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -3387,15 +3387,18 @@ sub delete_entry {
return undef if ($gpath eq '');
# remove entire directories.
- if (command('ls-tree', $self->{c}, '--', $gpath) =~ /^040000 tree/) {
+ my ($tree) = (command('ls-tree', '-z', $self->{c}, "./$gpath")
+ =~ /\A040000 tree ([a-f\d]{40})\t\Q$gpath\E\0/);
+ if ($tree) {
my ($ls, $ctx) = command_output_pipe(qw/ls-tree
-r --name-only -z/,
- $self->{c}, '--', $gpath);
+ $tree);
local $/ = "\0";
while (<$ls>) {
chomp;
- $self->{gii}->remove($_);
- print "\tD\t$_\n" unless $::_q;
+ my $rmpath = "$gpath/$_";
+ $self->{gii}->remove($rmpath);
+ print "\tD\t$rmpath\n" unless $::_q;
}
print "\tD\t$gpath/\n" unless $::_q;
command_close_pipe($ls, $ctx);
@@ -3414,8 +3417,8 @@ sub open_file {
goto out if is_path_ignored($path);
my $gpath = $self->git_path($path);
- ($mode, $blob) = (command('ls-tree', $self->{c}, '--', $gpath)
- =~ /^(\d{6}) blob ([a-f\d]{40})\t/);
+ ($mode, $blob) = (command('ls-tree', '-z', $self->{c}, "./$gpath")
+ =~ /\A(\d{6}) blob ([a-f\d]{40})\t\Q$gpath\E\0/);
unless (defined $mode && defined $blob) {
die "$path was not found in commit $self->{c} (r$rev)\n";
}
--
^ permalink raw reply related
* Re: [PATCH] git-gui: French translation improvements
From: Christian Couder @ 2009-03-29 8:16 UTC (permalink / raw)
To: Nicolas Sebrecht; +Cc: git, Shawn O. Pearce, Sam Hocevar
In-Reply-To: <ae74fa8c7846e3f4e6d6d75cc4177b6e6afe6824.1238180731.git.nicolas.s-dev@laposte.net>
Le vendredi 27 mars 2009, Nicolas Sebrecht a écrit :
[...]
> #: git-gui.sh:2286 lib/choose_rev.tcl:548
> msgid "Commit@@noun"
> -msgstr "Commit"
> +msgstr "Commit@@noun"
I am not sure that this change is needed.
The "@@noun" part does not appear and it's only useful for the original
language, right?
> #: lib/branch_create.tcl:58
> msgid "Match Tracking Branch Name"
> -msgstr "Trouver nom de branche de suivi"
> +msgstr "Correspond au nom de la branche de suivi"
I am not sure about this one too.
Are you sure that it's ok in the context where it appears?
> #: lib/branch_create.tcl:66
> msgid "Starting Revision"
> @@ -780,6 +780,16 @@ msgstr "Toujours (Ne pas faire de test de fusion.)"
> msgid "The following branches are not completely merged into %s:"
> msgstr "Les branches suivantes ne sont pas complÚtement fusionnées
> dans %s :"
>
> +#: lib/branch_delete.tcl:115
> +msgid ""
> +"Recovering deleted branches is difficult. \n"
> +"\n"
> +" Delete the selected branches?"
> +msgstr ""
> +"Il est difficile de récupérer des branches supprimées.\n"
> +"\n"
> +"Supprimer les branches sélectionnées ?"
Why do you need to add this? Wasn't it delete by Sam for a good reason?
Or am I missing something?
> #: lib/branch_delete.tcl:141
> #, tcl-format
> msgid ""
> @@ -1099,7 +1109,7 @@ msgstr "Standard (rapide, semi-redondant, liens
> durs)"
>
> #: lib/choose_repository.tcl:508
> msgid "Full Copy (Slower, Redundant Backup)"
> -msgstr "Copy complÚte (plus lent, sauvegarde redondante)"
> +msgstr "Copie complÚte (plus lent, sauvegarde redondante)"
>
> #: lib/choose_repository.tcl:514
> msgid "Shared (Fastest, Not Recommended, No Backup)"
> @@ -1524,12 +1534,10 @@ msgid ""
> "\n"
> "Compress the database now?"
> msgstr ""
> -"Ce dépÎt comprend actuellement environ %i objets ayant leur fichier "
> -"particulier.\n"
> +"Ce dépÎt comprend actuellement environ %i objets inutilisés.\n"
I don't think the files are unused, it looks like "loose" in english here
means that the objects are alone in their own file.
> "\n"
> "Pour conserver une performance optimale, il est fortement recommandé
> de " -"comprimer la base quand plus de %i objets ayant leur fichier
> particulier " -"existent.\n"
> +"comprimer la base quand plus de %i objets inutilisés existent.\n"
> "\n"
> "Comprimer la base maintenant ?"
[...]
> #: lib/index.tcl:427
> msgid "Reverting selected files"
> -msgstr "Annuler modifications dans fichiers selectionnés"
> +msgstr "Révocation en cours des fichiers sélectionnés"
After what Alexandre Bourget said about "revert" in git-gui, I think we
should keep "Annuler".
Thanks,
Christian.
^ permalink raw reply
* Re: [EGIT] [PATCH RFC v1 0/5] Add (static) ignore functionality to EGit
From: Robin Rosenberg @ 2009-03-29 9:23 UTC (permalink / raw)
To: Ferry Huberts; +Cc: git, Shawn O. Pearce
In-Reply-To: <cover.1238102327.git.ferry.huberts@pelagic.nl>
A quick reply (I might come up with more later): Ignore support should be mostly
in jgit, with only extensions into egit.
-- robin
^ permalink raw reply
* Re: [EGIT] How to deal with important modifications
From: Robin Rosenberg @ 2009-03-29 9:45 UTC (permalink / raw)
To: Ferry Huberts (Pelagic); +Cc: Shawn O. Pearce, git
In-Reply-To: <49CEA861.4070700@pelagic.nl>
lördag 28 mars 2009 23:44:49 skrev "Ferry Huberts (Pelagic)" <ferry.huberts@pelagic.nl>:
> Yann Simon wrote:
> > Hi,
> >
> > I am working on the synchronization view. It is not 100% functional yet.
> > The view is not updated when a local file is modified for example.
> > As the modifications are getting important, I was wondering how to deal
> > with it. Should I continue my work an send all the patches when
> > finished?
> >
> > To have an overview of the modifications:
> > http://github.com/yanns/egit/commit/18c4a928d53345802a8c9641dcb2d457ebbe2cbc
> > http://github.com/yanns/egit/commit/9fab398fa1b7b6efa9532b3c09e5bcfcc8bb9419
> >
> > Or should I begin to send patches, but by not activating the function
> > yet?
> > (It could be a way to have other people to help contributing.)
> >
> > Yann
> Yann,
>
> I was asking myself the same questions about my work on ignores and
> chose to send it out early, being half completed. Don't know if that was
> right, did not receive feedback yet, but it's only been 2 days with
> Eclipsecon wrapping up on friday.
That's not the reason you haven't received a response. Basically, the larger
a set of patches is, more time is needed.
> If you keep a seperate changeset in which you activate your work and
> split up the changesets in manageable pieces it's easier for others to
> review your work and comment on it.
Indeed. Small patches can be reviewed more quickly if they introduce well
defined changes and especially good is if they make sense of their own.
Think about how you would like the changes presented if you were to review
them without knowing anything in advance.
-- robin
^ permalink raw reply
* [PATCH 0/4] bisect--helper: fix reading many paths
From: Christian Couder @ 2009-03-29 9:44 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
These patches fix reading more than one path in "git bisect--helper":
quote: implement "sq_dequote_many" to unwrap many args in one string
quote: add "sq_dequote_to_argv" to put unwrapped args in an argv
array
bisect: fix reading more than one path in "$GIT_DIR/BISECT_NAMES"
bisect: test bisecting with paths
bisect.c | 14 +++++-----
quote.c | 35 +++++++++++++++++++++++-
quote.h | 10 +++++++
t/t6030-bisect-porcelain.sh | 60 +++++++++++++++++++++++++++++++++++++++++++
4 files changed, 110 insertions(+), 9 deletions(-)
^ permalink raw reply
* [PATCH 1/4] quote: implement "sq_dequote_many" to unwrap many args in one string
From: Christian Couder @ 2009-03-29 9:44 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
The new "sq_dequote_many" function is implemented by changing the
code of "sq_dequote" and "sq_dequote" is now a thin wrapper around
"sq_dequote_many".
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
quote.c | 18 ++++++++++++++++--
quote.h | 8 ++++++++
2 files changed, 24 insertions(+), 2 deletions(-)
diff --git a/quote.c b/quote.c
index 6a52085..8cf0ef4 100644
--- a/quote.c
+++ b/quote.c
@@ -72,7 +72,7 @@ void sq_quote_argv(struct strbuf *dst, const char** argv, size_t maxlen)
}
}
-char *sq_dequote(char *arg)
+char *sq_dequote_many(char *arg, char **next)
{
char *dst = arg;
char *src = arg;
@@ -92,6 +92,8 @@ char *sq_dequote(char *arg)
switch (*++src) {
case '\0':
*dst = 0;
+ if (next)
+ *next = 0;
return arg;
case '\\':
c = *++src;
@@ -101,11 +103,23 @@ char *sq_dequote(char *arg)
}
/* Fallthrough */
default:
- return NULL;
+ if (!next || !isspace(*src))
+ return NULL;
+ do {
+ c = *++src;
+ } while (isspace(c));
+ *dst = 0;
+ *next = src;
+ return arg;
}
}
}
+char *sq_dequote(char *arg)
+{
+ return sq_dequote_many(arg, NULL);
+}
+
/* 1 means: quote as octal
* 0 means: quote as octal if (quote_path_fully)
* -1 means: never quote
diff --git a/quote.h b/quote.h
index c5eea6f..c2f98e7 100644
--- a/quote.h
+++ b/quote.h
@@ -39,6 +39,14 @@ extern void sq_quote_argv(struct strbuf *, const char **argv, size_t maxlen);
*/
extern char *sq_dequote(char *);
+/*
+ * Same as the above, but can unwraps many arguments in the same string
+ * separated by space. "next" is changed to point to the next argument
+ * that should be passed as first parameter. When there are no more
+ * arguments to be dequoted, then "next" is changed to point to NULL.
+ */
+extern char *sq_dequote_many(char *arg, char **next);
+
extern int unquote_c_style(struct strbuf *, const char *quoted, const char **endp);
extern size_t quote_c_style(const char *name, struct strbuf *, FILE *, int no_dq);
extern void quote_two_c_style(struct strbuf *, const char *, const char *, int);
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* [PATCH 2/4] quote: add "sq_dequote_to_argv" to put unwrapped args in an argv array
From: Christian Couder @ 2009-03-29 9:44 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
This new function unwraps the space separated shell quoted elements in
its first argument and put a copy of them in the argv array passed as
its second argument.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
quote.c | 17 +++++++++++++++++
quote.h | 2 ++
2 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/quote.c b/quote.c
index 8cf0ef4..5b12a4a 100644
--- a/quote.c
+++ b/quote.c
@@ -120,6 +120,23 @@ char *sq_dequote(char *arg)
return sq_dequote_many(arg, NULL);
}
+int sq_dequote_to_argv(char *arg, const char ***argv, int *nr, int *alloc)
+{
+ char *next = arg;
+
+ if (!*arg)
+ return 0;
+ do {
+ char *dequoted = sq_dequote_many(next, &next);
+ if (!dequoted)
+ return 1;
+ ALLOC_GROW(*argv, *nr + 1, *alloc);
+ (*argv)[(*nr)++] = xstrdup(dequoted);
+ } while (next);
+
+ return 0;
+}
+
/* 1 means: quote as octal
* 0 means: quote as octal if (quote_path_fully)
* -1 means: never quote
diff --git a/quote.h b/quote.h
index c2f98e7..bbd0f09 100644
--- a/quote.h
+++ b/quote.h
@@ -47,6 +47,8 @@ extern char *sq_dequote(char *);
*/
extern char *sq_dequote_many(char *arg, char **next);
+extern int sq_dequote_to_argv(char *arg, const char ***argv, int *nr, int *alloc);
+
extern int unquote_c_style(struct strbuf *, const char *quoted, const char **endp);
extern size_t quote_c_style(const char *name, struct strbuf *, FILE *, int no_dq);
extern void quote_two_c_style(struct strbuf *, const char *, const char *, int);
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* [PATCH 3/4] bisect: fix reading more than one path in "$GIT_DIR/BISECT_NAMES"
From: Christian Couder @ 2009-03-29 9:44 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
The implementation of "read_bisect_paths" worked with only one
path in each line of "$GIT_DIR/BISECT_NAMES", but the paths are all
stored on one line by "git-bisect.sh".
So we have to process all the paths that may be on each line.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
bisect.c | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/bisect.c b/bisect.c
index 9e779c1..66df05f 100644
--- a/bisect.c
+++ b/bisect.c
@@ -435,17 +435,17 @@ void read_bisect_paths(void)
die("Could not open file '%s': %s", filename, strerror(errno));
while (strbuf_getline(&str, fp, '\n') != EOF) {
- char *quoted, *dequoted;
+ char *quoted;
+ int res;
+
strbuf_trim(&str);
quoted = strbuf_detach(&str, NULL);
- if (!*quoted)
- continue;
- dequoted = sq_dequote(quoted);
- if (!dequoted)
+ res = sq_dequote_to_argv(quoted, &rev_argv,
+ &rev_argv_nr, &rev_argv_alloc);
+ if (res)
die("Badly quoted content in file '%s': %s",
filename, quoted);
- ALLOC_GROW(rev_argv, rev_argv_nr + 1, rev_argv_alloc);
- rev_argv[rev_argv_nr++] = dequoted;
+ free(quoted);
}
strbuf_release(&str);
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* [PATCH 4/4] t6030: test bisecting with paths
From: Christian Couder @ 2009-03-29 9:45 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
This patch adds some tests to check that "git bisect" works fine when
passing paths to "git bisect start" to reduce the number of
bisection steps.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
t/t6030-bisect-porcelain.sh | 60 +++++++++++++++++++++++++++++++++++++++++++
1 files changed, 60 insertions(+), 0 deletions(-)
diff --git a/t/t6030-bisect-porcelain.sh b/t/t6030-bisect-porcelain.sh
index 052a6c9..54b7ea6 100755
--- a/t/t6030-bisect-porcelain.sh
+++ b/t/t6030-bisect-porcelain.sh
@@ -506,6 +506,66 @@ test_expect_success 'optimized merge base checks' '
unset GIT_TRACE
'
+# This creates another side branch called "parallel" with some files
+# in some directories, to test bisecting with paths.
+#
+# We should have the following:
+#
+# P1-P2-P3-P4-P5-P6-P7
+# / / /
+# H1-H2-H3-H4-H5-H6-H7
+# \ \ \
+# S5-A \
+# \ \
+# S6-S7----B
+#
+test_expect_success '"parallel" side branch creation' '
+ git bisect reset &&
+ git checkout -b parallel $HASH1 &&
+ mkdir dir1 dir2 &&
+ add_line_into_file "1(para): line 1 on parallel branch" dir1/file1 &&
+ PARA_HASH1=$(git rev-parse --verify HEAD) &&
+ add_line_into_file "2(para): line 2 on parallel branch" dir2/file2 &&
+ PARA_HASH2=$(git rev-parse --verify HEAD) &&
+ add_line_into_file "3(para): line 3 on parallel branch" dir2/file3 &&
+ PARA_HASH3=$(git rev-parse --verify HEAD)
+ git merge -m "merge HASH4 and PARA_HASH3" "$HASH4" &&
+ PARA_HASH4=$(git rev-parse --verify HEAD)
+ add_line_into_file "5(para): add line on parallel branch" dir1/file1 &&
+ PARA_HASH5=$(git rev-parse --verify HEAD)
+ add_line_into_file "6(para): add line on parallel branch" dir2/file2 &&
+ PARA_HASH6=$(git rev-parse --verify HEAD)
+ git merge -m "merge HASH7 and PARA_HASH6" "$HASH7" &&
+ PARA_HASH7=$(git rev-parse --verify HEAD)
+'
+
+test_expect_success 'restricting bisection on one dir' '
+ git bisect reset &&
+ git bisect start HEAD $HASH1 -- dir1 &&
+ para1=$(git rev-parse --verify HEAD) &&
+ test "$para1" = "$PARA_HASH1" &&
+ git bisect bad > my_bisect_log.txt &&
+ grep "$PARA_HASH1 is first bad commit" my_bisect_log.txt
+'
+
+test_expect_success 'restricting bisection on one dir and a file' '
+ git bisect reset &&
+ git bisect start HEAD $HASH1 -- dir1 hello &&
+ para4=$(git rev-parse --verify HEAD) &&
+ test "$para4" = "$PARA_HASH4" &&
+ git bisect bad &&
+ hash3=$(git rev-parse --verify HEAD) &&
+ test "$hash3" = "$HASH3" &&
+ git bisect good &&
+ hash4=$(git rev-parse --verify HEAD) &&
+ test "$hash4" = "$HASH4" &&
+ git bisect good &&
+ para1=$(git rev-parse --verify HEAD) &&
+ test "$para1" = "$PARA_HASH1" &&
+ git bisect good > my_bisect_log.txt &&
+ grep "$PARA_HASH4 is first bad commit" my_bisect_log.txt
+'
+
#
#
test_done
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* Re: On git 1.6 (novice's opinion)
From: Johannes Schindelin @ 2009-03-29 9:50 UTC (permalink / raw)
To: Bryan Donlan; +Cc: Ulrich Windl, git
In-Reply-To: <3e8340490903282241u355ce5b3u1a6ff23b27f4ec12@mail.gmail.com>
Hi,
On Sun, 29 Mar 2009, Bryan Donlan wrote:
> On Fri, Mar 27, 2009 at 3:21 AM, Ulrich Windl
> <ulrich.windl@rz.uni-regensburg.de> wrote:
>
> > 3) "git undo": If possible undo the effects of the last command.
>
> You can roll back the state of most local references by using the git
> reflog (see git reflog --help for more information). This covers most
> situations - but note that it only works to roll back to a committed
> state, and won't save any uncommitted data at all.
Which is why you should commit early and often, and certainly before doing
something bigger.
Ciao,
Dscho
^ permalink raw reply
* [PATCH 0/2] bisect--helper: string output variables together with "&&"
From: Christian Couder @ 2009-03-29 9:55 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
The goal of this 2 patches is to get rid of the need to pipe the
output of "eval 'git bisect--helper --next-vars'" into a "while read"
loop.
This applies on top of my previous "bisect--helper" series on pu.
rev-list: pass a flag as last argument of "show_bisect_vars"
bisect--helper: string output variables together with "&&"
bisect.c | 3 ++-
bisect.h | 9 +++++++--
builtin-rev-list.c | 44 +++++++++++++++++++++++++++-----------------
git-bisect.sh | 15 +--------------
4 files changed, 37 insertions(+), 34 deletions(-)
^ permalink raw reply
* [PATCH 1/2] rev-list: pass "int flags" as last argument of "show_bisect_vars"
From: Christian Couder @ 2009-03-29 9:55 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
Instead of "int show_all, int show_tried" we now only pass "int flags",
because we will add one more flag in a later patch.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
bisect.c | 2 +-
bisect.h | 8 ++++++--
builtin-rev-list.c | 13 ++++++-------
3 files changed, 13 insertions(+), 10 deletions(-)
diff --git a/bisect.c b/bisect.c
index 66df05f..64a5ad5 100644
--- a/bisect.c
+++ b/bisect.c
@@ -554,5 +554,5 @@ int bisect_next_vars(const char *prefix)
revs.commits = find_bisection(revs.commits, &reaches, &all,
!!skipped_sha1_nr);
- return show_bisect_vars(&revs, reaches, all, 0, 1);
+ return show_bisect_vars(&revs, reaches, all, SHOW_TRIED);
}
diff --git a/bisect.h b/bisect.h
index 05eea17..4cff2ba 100644
--- a/bisect.h
+++ b/bisect.h
@@ -9,13 +9,17 @@ extern struct commit_list *filter_skipped(struct commit_list *list,
struct commit_list **tried,
int show_all);
+/* show_bisect_vars flags */
+#define SHOW_ALL 1
+#define SHOW_TRIED 2
+
/*
- * The "show_all" parameter should be 0 if this function is called
+ * The flag SHOW_ALL should not be set if this function is called
* from outside "builtin-rev-list.c" as otherwise it would use
* static "revs" from this file.
*/
extern int show_bisect_vars(struct rev_info *revs, int reaches, int all,
- int show_all, int show_tried);
+ int flags);
extern int bisect_next_vars(const char *prefix);
diff --git a/builtin-rev-list.c b/builtin-rev-list.c
index 925d643..c1c4a18 100644
--- a/builtin-rev-list.c
+++ b/builtin-rev-list.c
@@ -236,17 +236,16 @@ static void show_tried_revs(struct commit_list *tried)
printf("'\n");
}
-int show_bisect_vars(struct rev_info *revs, int reaches, int all,
- int show_all, int show_tried)
+int show_bisect_vars(struct rev_info *revs, int reaches, int all, int flags)
{
int cnt;
char hex[41] = "";
struct commit_list *tried;
- if (!revs->commits && !show_tried)
+ if (!revs->commits && !(flags & SHOW_TRIED))
return 1;
- revs->commits = filter_skipped(revs->commits, &tried, show_all);
+ revs->commits = filter_skipped(revs->commits, &tried, flags & SHOW_ALL);
/*
* revs->commits can reach "reaches" commits among
@@ -264,12 +263,12 @@ int show_bisect_vars(struct rev_info *revs, int reaches, int all,
if (revs->commits)
strcpy(hex, sha1_to_hex(revs->commits->item->object.sha1));
- if (show_all) {
+ if (flags & SHOW_ALL) {
traverse_commit_list(revs, show_commit, show_object);
printf("------\n");
}
- if (show_tried)
+ if (flags & SHOW_TRIED)
show_tried_revs(tried);
printf("bisect_rev=%s\n"
"bisect_nr=%d\n"
@@ -379,7 +378,7 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
if (bisect_show_vars)
return show_bisect_vars(&revs, reaches, all,
- bisect_show_all, 0);
+ bisect_show_all ? SHOW_ALL : 0);
}
traverse_commit_list(&revs,
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* [PATCH 2/2] bisect--helper: string output variables together with "&&"
From: Christian Couder @ 2009-03-29 9:55 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
When doing:
eval "git bisect--helper --next-vars" | {
while read line
do
echo "$line &&"
done
echo ':'
}
the result code comes from the last "echo ':'", not from running
"git bisect--helper --next-vars".
This patch get rid of the need to string the line from the output
of "git bisect--helper" by making "git bisect--helper --next-vars"
return output variables stringed together with "&&".
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
bisect.c | 3 ++-
bisect.h | 1 +
builtin-rev-list.c | 31 +++++++++++++++++++++----------
git-bisect.sh | 15 +--------------
4 files changed, 25 insertions(+), 25 deletions(-)
diff --git a/bisect.c b/bisect.c
index 64a5ad5..df0ab4d 100644
--- a/bisect.c
+++ b/bisect.c
@@ -554,5 +554,6 @@ int bisect_next_vars(const char *prefix)
revs.commits = find_bisection(revs.commits, &reaches, &all,
!!skipped_sha1_nr);
- return show_bisect_vars(&revs, reaches, all, SHOW_TRIED);
+ return show_bisect_vars(&revs, reaches, all,
+ SHOW_TRIED | SHOW_STRINGED);
}
diff --git a/bisect.h b/bisect.h
index 4cff2ba..2e4b2af 100644
--- a/bisect.h
+++ b/bisect.h
@@ -12,6 +12,7 @@ extern struct commit_list *filter_skipped(struct commit_list *list,
/* show_bisect_vars flags */
#define SHOW_ALL 1
#define SHOW_TRIED 2
+#define SHOW_STRINGED 4
/*
* The flag SHOW_ALL should not be set if this function is called
diff --git a/builtin-rev-list.c b/builtin-rev-list.c
index c1c4a18..83b2214 100644
--- a/builtin-rev-list.c
+++ b/builtin-rev-list.c
@@ -226,11 +226,13 @@ static int estimate_bisect_steps(int all)
return (e < 3 * x) ? n : n - 1;
}
-static void show_tried_revs(struct commit_list *tried)
+static void show_tried_revs(struct commit_list *tried, int stringed)
{
+ char *last_format = stringed ? "%s &&" : "%s";
+
printf("bisect_tried='");
for (;tried; tried = tried->next) {
- char *format = tried->next ? "%s|" : "%s";
+ char *format = tried->next ? "%s|" : last_format;
printf(format, sha1_to_hex(tried->item->object.sha1));
}
printf("'\n");
@@ -239,7 +241,7 @@ static void show_tried_revs(struct commit_list *tried)
int show_bisect_vars(struct rev_info *revs, int reaches, int all, int flags)
{
int cnt;
- char hex[41] = "";
+ char hex[41] = "", *format;
struct commit_list *tried;
if (!revs->commits && !(flags & SHOW_TRIED))
@@ -269,13 +271,22 @@ int show_bisect_vars(struct rev_info *revs, int reaches, int all, int flags)
}
if (flags & SHOW_TRIED)
- show_tried_revs(tried);
- printf("bisect_rev=%s\n"
- "bisect_nr=%d\n"
- "bisect_good=%d\n"
- "bisect_bad=%d\n"
- "bisect_all=%d\n"
- "bisect_steps=%d\n",
+ show_tried_revs(tried, flags & SHOW_STRINGED);
+ format = (flags & SHOW_STRINGED) ?
+ "bisect_rev=%s &&\n"
+ "bisect_nr=%d &&\n"
+ "bisect_good=%d &&\n"
+ "bisect_bad=%d &&\n"
+ "bisect_all=%d &&\n"
+ "bisect_steps=%d\n"
+ :
+ "bisect_rev=%s\n"
+ "bisect_nr=%d\n"
+ "bisect_good=%d\n"
+ "bisect_bad=%d\n"
+ "bisect_all=%d\n"
+ "bisect_steps=%d\n";
+ printf(format,
hex,
cnt - 1,
all - reaches - 1,
diff --git a/git-bisect.sh b/git-bisect.sh
index 0f7590d..5074dda 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -279,18 +279,6 @@ bisect_auto_next() {
bisect_next_check && bisect_next || :
}
-eval_and_string_together() {
- _eval="$1"
-
- eval "$_eval" | {
- while read line
- do
- echo "$line &&"
- done
- echo ':'
- }
-}
-
exit_if_skipped_commits () {
_tried=$1
_bad=$2
@@ -429,8 +417,7 @@ bisect_next() {
test "$?" -eq "1" && return
# Get bisection information
- eval="git bisect--helper --next-vars" &&
- eval=$(eval_and_string_together "$eval") &&
+ eval=$(eval "git bisect--helper --next-vars") &&
eval "$eval" || exit
if [ -z "$bisect_rev" ]; then
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* [PATCH] bisect: avoid pipes to better catch "git rev-list" errors
From: Christian Couder @ 2009-03-29 9:58 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, John Tapsell, Johannes Schindelin
When doing:
eval "git rev-list --bisect-vars ..." | {
while read line
do
echo "$line &&"
done
echo ':'
}
the result code comes from the last "echo ':'", not from running
"git rev-list --bisect-vars ...".
This means that we may miss errors from "git rev-list".
To fix that, this patch gets rid of the pipes by redirecting the
output of "git rev-list" into a file, and then reading from this
file.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
git-bisect.sh | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
This applies to master.
diff --git a/git-bisect.sh b/git-bisect.sh
index e313bde..45214ca 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -284,19 +284,22 @@ filter_skipped() {
_skip="$2"
if [ -z "$_skip" ]; then
- eval "$_eval" | {
+ eval "$_eval" > "$GIT_DIR/BISECT_EVAL_TMP" &&
+ {
while read line
do
echo "$line &&"
- done
+ done < "$GIT_DIR/BISECT_EVAL_TMP" &&
echo ':'
- }
+ } &&
+ rm -f "$GIT_DIR/BISECT_EVAL_TMP"
return
fi
# Let's parse the output of:
# "git rev-list --bisect-vars --bisect-all ..."
- eval "$_eval" | {
+ eval "$_eval" > "$GIT_DIR/BISECT_EVAL_TMP" &&
+ {
VARS= FOUND= TRIED=
while read hash line
do
@@ -349,9 +352,10 @@ filter_skipped() {
"line: '$line'"
;;
esac
- done
+ done < "$GIT_DIR/BISECT_EVAL_TMP" &&
echo ':'
- }
+ } &&
+ rm -f "$GIT_DIR/BISECT_EVAL_TMP"
}
exit_if_skipped_commits () {
--
1.6.2.1.404.gb0085.dirty
^ permalink raw reply related
* Re: [EGIT] [PATCH RFC v1 0/5] Add (static) ignore functionality to EGit
From: Ferry Huberts (Pelagic) @ 2009-03-29 10:43 UTC (permalink / raw)
To: Robin Rosenberg; +Cc: git, Shawn O. Pearce
In-Reply-To: <200903291123.24433.robin.rosenberg@dewire.com>
Robin Rosenberg wrote:
> A quick reply (I might come up with more later): Ignore support should be mostly
> in jgit, with only extensions into egit.
>
> -- robin
I discussed this with shawn and proposed to first implement it in egit
and when we have it right then move it into jgit. I think shawn agreed
with that.
Ferry
^ permalink raw reply
* Re: Fork of abandoned SVN mirror - how to keep up to date with the SVN
From: jamespetts @ 2009-03-29 10:51 UTC (permalink / raw)
To: git
In-Reply-To: <fabb9a1e0903281521y2e6785f1w5dde3c73be404327@mail.gmail.com>
Thank you for your reply :-) I updated, and was able to get the git svn command to work, using the syntax described in a previous post.
However, after several hours of downloading (I left it overnight), it gave the error, "The connection was aborted: Can't read from connection: The connection was aborted at C:\Program Files\Git/libexec/git-core/git-svn/ line 2490".
When I look at my repository on Github, it is still empty, apart from the empty README file that I created just to initialise it. Why would it be going wrong? How do I deal with that?
Heya,
On Sat, Mar 28, 2009 at 23:18, jamespetts <jamespetts@yahoo.com> wrote:
> git: 'svn' is not a git-command. See 'git --help'.
Try updating to the latest snapshot, git shipped without svn on
windows for a few releases.
--
Cheers,
Sverre Rabbelier
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
--
View this message in context: http://n2.nabble.com/Fork-of-abandoned-SVN-mirror---how-to-keep-up-to-date-with-the-SVN-tp2548952p2552153.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply
* Re: [PATCH 1/4] Documentation: enhance branch.<name>.{remote,merge}
From: Santi Béjar @ 2009-03-29 10:54 UTC (permalink / raw)
To: Jay Soffian; +Cc: git
In-Reply-To: <76718490903281838s1bc7e908l4702cf9ab020189@mail.gmail.com>
2009/3/29 Jay Soffian <jaysoffian@gmail.com>:
> On Sat, Mar 28, 2009 at 7:10 PM, Santi Béjar <santi@agolina.net> wrote:
>> branch.<name>.merge::
>> + It defines, together with branch.<name>.remote, the tracking branch
>> + for the current branch. It tells 'git-fetch'/'git-pull' which
>> + branch to merge.
>
> I think it would be clearer to say "the upstream branch for the
> current branch", since
> it could very well be a local branch, not necessarily a remote tracking branch.
It makes sense, thanks.
Santi
^ permalink raw reply
* Re: Fork of abandoned SVN mirror - how to keep up to date with the SVN
From: Sverre Rabbelier @ 2009-03-29 11:03 UTC (permalink / raw)
To: jamespetts; +Cc: git
In-Reply-To: <1238323876827-2552153.post@n2.nabble.com>
Heya,
On Sun, Mar 29, 2009 at 12:51, jamespetts <jamespetts@yahoo.com> wrote:
> However, after several hours of downloading (I left it overnight), it gave the error, "The connection was aborted: Can't read from connection: The connection was aborted at C:\Program Files\Git/libexec/git-core/git-svn/ line 2490".
You can continue downloading, just issue' git svn rebase' again, and
it will continue where it left of.
> When I look at my repository on Github, it is still empty, apart
> from the empty README file that I created just to initialise it.
> Why would it be going wrong? How do I deal with that?
You would have to push the repository to github regardless of whether
'git svn rebase' finished in one go. Keep in mind that' git svn
rebase' is the way to get changes _into_ your _local_ repository.
You'll need to use 'git push' to get your changes up to github.
--
Cheers,
Sverre Rabbelier
^ permalink raw reply
* Re: [PATCH v2 0/8] Documentation: XSLT/asciidoc.conf cleanup; tty literals
From: Jeff King @ 2009-03-29 11:50 UTC (permalink / raw)
To: Chris Johnsen; +Cc: Junio C Hamano, git
In-Reply-To: <1238136245-22853-1-git-send-email-chris_johnsen@pobox.com>
On Fri, Mar 27, 2009 at 01:43:57AM -0500, Chris Johnsen wrote:
> "v1" of this series can be found here: <http://thread.gmane.org/gmane.comp.version-control.git/114417>.
>
> Change since "v1":
>
> 1/8: No content change from "v1". This time -C -M was used to
> show copy/rename of callouts.xsl (thanks to Peff for
> pointing to diff.renames config option).
>
> 2/8: Use <xsl:import> instead of xmlto command line to reuse
> manpage-base.xsl. In commit message, move discussion of
> --stringparm to 8/8.
>
> 8/8: No content change from "v1" (though context is changed due
> to content change in 2/8). In commit message, add some of
> --stringparm discussion from "v1" 2/8.
Thanks. This version (and its output) look sane to me (I am now building
with ASCIIDOC_NO_ROFF).
-Peff
^ permalink raw reply
* Re: Fork of abandoned SVN mirror - how to keep up to date with the SVN
From: jamespetts @ 2009-03-29 11:52 UTC (permalink / raw)
To: git
In-Reply-To: <fabb9a1e0903290403s2b0bbe1al57ac448a16d05070@mail.gmail.com>
Thank you again for your reply :-) Ahh, yes, that makes sense about the local repository. However, on checking, the local repository that I set up has no files except in .git directories - is that to be expected at this stage?
Also, when I tried "git svn rebase", I got the following error:
"Migrating from a git-svn v1 layout...
"Data from a previous version exists, but .git/svn (required for this version (1.6.2 msysgit.0.186.gf7512) of git-svn) does not exist. Done migrating from a git-svn v1 layout
"Unable to determine upstream SVN information from working tree history"
And the local directories for the repositories are still empty. Am I doing something wrong...?
Heya,
On Sun, Mar 29, 2009 at 12:51, jamespetts <jamespetts@yahoo.com> wrote:
> However, after several hours of downloading (I left it overnight), it gave the error, "The connection was aborted: Can't read from connection: The connection was aborted at C:\Program Files\Git/libexec/git-core/git-svn/ line 2490".
You can continue downloading, just issue' git svn rebase' again, and
it will continue where it left of.
> When I look at my repository on Github, it is still empty, apart
> from the empty README file that I created just to initialise it.
> Why would it be going wrong? How do I deal with that?
You would have to push the repository to github regardless of whether
'git svn rebase' finished in one go. Keep in mind that' git svn
rebase' is the way to get changes _into_ your _local_ repository.
You'll need to use 'git push' to get your changes up to github.
--
Cheers,
Sverre Rabbelier
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
--
View this message in context: http://n2.nabble.com/Fork-of-abandoned-SVN-mirror---how-to-keep-up-to-date-with-the-SVN-tp2548952p2552334.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply
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