* [StGIT PATCH] Add an --smtp-server commandline option to "stg add"
From: Karl Hasselström @ 2007-08-08 22:11 UTC (permalink / raw)
To: Catalin Marinas; +Cc: git
The configuration option stgit.smtpserver is useful if you always talk
to the same SMTP server. But I usually set up a temporary ssh tunnel,
so I'd rather have a commandline option.
Signed-off-by: Karl Hasselström <kha@treskal.com>
---
This patch is sent using the --smtp-server commandline option. Pure
magic!
stgit/commands/mail.py | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/stgit/commands/mail.py b/stgit/commands/mail.py
index cb8dc74..a7f7151 100644
--- a/stgit/commands/mail.py
+++ b/stgit/commands/mail.py
@@ -28,10 +28,11 @@ from stgit.config import config
help = 'send a patch or series of patches by e-mail'
usage = """%prog [options] [<patch1>] [<patch2>] [<patch3>..<patch4>]
-Send a patch or a range of patches by e-mail using the 'smtpserver'
-configuration option. The From address and the e-mail format are
-generated from the template file passed as argument to '--template'
-(defaulting to '.git/patchmail.tmpl' or
+Send a patch or a range of patches by e-mail using the SMTP server
+specified by the 'stgit.smtpserver' configuration option, or the
+'--smtp-server' command line option. The From address and the e-mail
+format are generated from the template file passed as argument to
+'--template' (defaulting to '.git/patchmail.tmpl' or
'~/.stgit/templates/patchmail.tmpl' or
'/usr/share/stgit/templates/patchmail.tmpl').
@@ -117,6 +118,8 @@ options = [make_option('-a', '--all',
help = 'sleep for SECONDS between e-mails sending'),
make_option('--refid',
help = 'use REFID as the reference id'),
+ make_option('--smtp-server', metavar = 'HOST[:PORT]',
+ help = 'SMTP server to use for sending mail'),
make_option('-u', '--smtp-user', metavar = 'USER',
help = 'username for SMTP authentication'),
make_option('-p', '--smtp-password', metavar = 'PASSWORD',
@@ -465,7 +468,7 @@ def func(parser, options, args):
"""Send the patches by e-mail using the patchmail.tmpl file as
a template
"""
- smtpserver = config.get('stgit.smtpserver')
+ smtpserver = options.smtp_server or config.get('stgit.smtpserver')
applied = crt_series.get_applied()
^ permalink raw reply related
* Re: git-write-tree strangeness
From: Steven Walter @ 2007-08-08 22:16 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Alex Riesen, git
In-Reply-To: <7vabt14y08.fsf@assigned-by-dhcp.cox.net>
On Wed, Aug 08, 2007 at 12:39:03PM -0700, Junio C Hamano wrote:
> "Alex Riesen" <raa.lkml@gmail.com> writes:
>
> > On 8/8/07, Steven Walter <stevenrwalter@gmail.com> wrote:
> >> I'm importing a large repository from svn into git with a custom tool,
> >> and I noticed a strange issue with one of the commits.
> >>
> >> Upon investigating further, I found that when I ran "git-write-tree"
> >> followed immediately by "git-diff-index <tree>" I had differences. Does
> >> that mean that git-write-tree incorrectly recorded the index, or do I
> >> misunderstand things?
> >
> > What kind of differences? Different sha1 of content?
> > I can't simply reproduce it.
>
> Isn't this simply just a dirty worktree and missing --cached
> option?
It doesn't happen everytime; I haven't found a set procedure to cause
the problem. Your remark, Junio, combined with my later testing, lead
me to believe that this is not a write-tree problem, but a git-add
problem.
The entire procedure I was following was:
<change working copy by svn>
git add .
git add -u
git write-tree
git diff-index <tree>
It seems to me that my expectation that diff-index show no changes was
reasonable, but I misunderstood the implication; I expected diff-index
to always compare the given tree to the index, regardless of the
presence or absence of a '--cached' option.
If I rebuilt git from v1.5.2 and repeated the above commands, diff-tree
showed no differences, as I would expect. Further, if I then re-ran
write-tree/diff-index from v1.5.3-rc4, I still received no differences.
I believe this result exculpates write-tree.
Was there not a thread recently about a missing optimization in git-add?
If this change was included in v1.5.3-rc4, could it be the cause of my
discrepency? Suggestions for testing this theory, if it is reasonable?
--
-Steven Walter <stevenrwalter@gmail.com>
"A human being should be able to change a diaper, plan an invasion,
butcher a hog, conn a ship, design a building, write a sonnet, balance
accounts, build a wall, set a bone, comfort the dying, take orders,
give orders, cooperate, act alone, solve equations, analyze a new
problem, pitch manure, program a computer, cook a tasty meal, fight
efficiently, die gallantly. Specialization is for insects."
-Robert Heinlein
^ permalink raw reply
* Re: 'pu' branch for StGIT
From: Pavel Roskin @ 2007-08-08 22:18 UTC (permalink / raw)
To: Karl Hasselström; +Cc: git, Catalin Marinas, Yann Dirson
In-Reply-To: <20070808213917.GA22521@diana.vm.bytemark.co.uk>
Hello, Karl!
On Wed, 2007-08-08 at 23:39 +0200, Karl Hasselström wrote:
> > Hmm, I hadn't noticed. That would be an unintended side-effect of
> > the DAG patches, presumably. I'll look into it tonight.
>
> I can't reproduce.
OK, it's trickier. There are some bad patch names that don't get
imported properly. In particular, patches ending with ".diff" are
committed after import.
Try changing this in the testsuite:
diff --git a/t/t1800-import.sh b/t/t1800-import.sh
index 8c8c9a0..6cd3cdb 100755
--- a/t/t1800-import.sh
+++ b/t/t1800-import.sh
@@ -15,7 +15,7 @@ test_expect_success \
test_expect_success \
'Apply a patch created with "git diff"' \
'
- stg import ../t1800-import/git-diff &&
+ stg import -n git.diff ../t1800-import/git-diff &&
[ $(git cat-file -p $(stg id) \
| grep -c "tree e96b1fba2160890ff600b675d7140d46b022b155") = 1 ] &&
stg delete ..
And now run the test
$ ./t1800-import.sh -i -v
...
Importing patch "git.diff" ... done
No patches applied
The mainline StGIT is OK.
--
Regards,
Pavel Roskin
^ permalink raw reply related
* Re: Submodules
From: Johannes Schindelin @ 2007-08-08 22:18 UTC (permalink / raw)
To: Junio C Hamano; +Cc: skimo, Dmitry Kakurin, git
In-Reply-To: <7vzm111xyw.fsf@assigned-by-dhcp.cox.net>
Hi,
On Wed, 8 Aug 2007, Junio C Hamano wrote:
> Sven Verdoolaege <skimo@kotnet.org> writes:
>
> > On Wed, Aug 08, 2007 at 12:59:30PM -0700, Junio C Hamano wrote:
> >> Sorry, but I do not use submodules yet myself.
> >
> > If you would ever start using submodules (for, say, gitgui),
> > then I'm sure we'd have much more usable submodules support
> > in no time.
>
> Heh, I do not have infinite time to spend on every little corner
> features, and have been hoping that other people who have more
> immediate need of submodule support to be the guinea pigs to
> encounter real-life issues first and come up with solutions to
> them, before I start using it.
>
> So far, I think the plan has been working out alright ;-).
Sure. I already like submodules, and I think that msysgit.git using it
can bring submodules along more painlessly for git.git users.
Ciao,
Dscho
^ permalink raw reply
* [PATCH] Further changes to it.po
From: Paolo Ciarrocchi @ 2007-08-08 22:35 UTC (permalink / raw)
To: git; +Cc: barra_cuda
Thanks to Michele Ballabio and tp@lists.linux.it
Patch already pushed to the mob branch.
Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com>
---
po/it.po | 85 ++++++++++++++++++++++++++++++++------------------------------
1 files changed, 44 insertions(+), 41 deletions(-)
diff --git a/po/it.po b/po/it.po
index e87263e..42f6829 100644
--- a/po/it.po
+++ b/po/it.po
@@ -2,26 +2,28 @@
# Copyright (C) 2007 Shawn Pearce
# This file is distributed under the same license as the git-gui package.
# Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com>, 2007
-#, fuzzy
+# Michele Ballabio <barra_cuda@katamail.com>, 2007.
+#
+#
msgid ""
msgstr ""
"Project-Id-Version: git-gui\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2007-07-31 19:24+0200\n"
-"PO-Revision-Date: 2007-08-01 19:10+0200\n"
-"Last-Translator: Michele Ballabio <barra_cuda@katamail.com>\n"
-"Language-Team: Italian\n"
+"PO-Revision-Date: 2007-08-09 00:27+0200\n"
+"Last-Translator: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com>\n"
+"Language-Team: Italian <tp@lists.linux.it>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
+"Content-Transfer-Encoding: 8bit"
#: git-gui.sh:531
msgid "Cannot find git in PATH."
-msgstr "Non posso trovare git nel PATH"
+msgstr "Impossibile trovare git nel PATH"
#: git-gui.sh:550
msgid "Cannot parse Git version string:"
-msgstr "Non posso estrarre la stringa di versione di git:"
+msgstr "Impossibile determinare la versione di Git:"
#: git-gui.sh:567
#, tcl-format
@@ -52,11 +54,11 @@ msgstr "Non trovo la directory di git: "
#: git-gui.sh:703
msgid "Cannot use funny .git directory:"
-msgstr "Non posso usare una .git directory strana:"
+msgstr "Impossibile usare una .git directory strana:"
#: git-gui.sh:708
msgid "No working directory"
-msgstr "Non working directory"
+msgstr "Nessuna directory di lavoro"
#: git-gui.sh:854
msgid "Refreshing file status..."
@@ -80,7 +82,7 @@ msgstr "Modificato, non pronto per il commit"
#: git-gui.sh:1325 git-gui.sh:1330
msgid "Staged for commit"
-msgstr "Pronto al commit"
+msgstr "Pronto per il commit"
#: git-gui.sh:1326 git-gui.sh:1331
msgid "Portions staged for commit"
@@ -92,7 +94,7 @@ msgstr "Pronto per il commit, mancante"
#: git-gui.sh:1329
msgid "Untracked, not staged"
-msgstr "Non seguito, non pronto al commit"
+msgstr "Non tracciato, non pronto per il commit"
#: git-gui.sh:1334
msgid "Missing"
@@ -100,7 +102,7 @@ msgstr "Mancante"
#: git-gui.sh:1335
msgid "Staged for removal"
-msgstr "Pronto alla rimozione"
+msgstr "Pronto per la rimozione"
#: git-gui.sh:1336
msgid "Staged for removal, still present"
@@ -128,15 +130,15 @@ msgstr ""
#: git-gui.sh:1609
#, tcl-format
msgid "Invalid font specified in gui.%s:"
-msgstr "Carattere non valido specificato nella gui.%s:"
+msgstr "Caratteri non valido specificato nella gui.%s:"
#: git-gui.sh:1634
msgid "Main Font"
-msgstr "Carattere principale"
+msgstr "Caratteri principali"
#: git-gui.sh:1635
msgid "Diff/Console Font"
-msgstr "Carattere per confronti e terminale"
+msgstr "Caratteri per confronti e terminale"
#: git-gui.sh:1649
msgid "Repository"
@@ -156,11 +158,11 @@ msgstr "Commit"
#: git-gui.sh:1658 lib/merge.tcl:121 lib/merge.tcl:150 lib/merge.tcl:168
msgid "Merge"
-msgstr "Fondi (Merge)"
+msgstr "Fusione (Merge)"
#: git-gui.sh:1659
msgid "Fetch"
-msgstr "Recupera (Fetch)"
+msgstr "Preleva (Fetch)"
#: git-gui.sh:1660 git-gui.sh:2158 lib/transport.tcl:88 lib/transport.tcl:172
msgid "Push"
@@ -273,7 +275,7 @@ msgstr "Correggi l'ultimo commit"
#: git-gui.sh:1809 git-gui.sh:2136 lib/remote_branch_delete.tcl:99
msgid "Rescan"
-msgstr "Analizza di nuovo"
+msgstr "Analizza nuovamente"
#: git-gui.sh:1815
msgid "Stage To Commit"
@@ -326,7 +328,7 @@ msgstr "Aiuto"
#: git-gui.sh:1938
msgid "Online Documentation"
-msgstr "Documentazione online"
+msgstr "Documentazione sul web"
#: git-gui.sh:2054
msgid "Current Branch:"
@@ -386,11 +388,11 @@ msgstr "Applica/Inverti sezione"
#: git-gui.sh:2391
msgid "Decrease Font Size"
-msgstr "Diminuisci dimensione carattere"
+msgstr "Diminuisci dimensione caratteri"
#: git-gui.sh:2395
msgid "Increase Font Size"
-msgstr "Aumenta dimensione carattere"
+msgstr "Aumenta dimensione caratteri"
#: git-gui.sh:2400
msgid "Show Less Context"
@@ -455,7 +457,7 @@ msgstr "Opzioni"
#: lib/branch_checkout.tcl:39 lib/branch_create.tcl:92
msgid "Fetch Tracking Branch"
-msgstr "Recupera ramo in 'tracking'"
+msgstr "Preleva ramo in 'tracking'"
#: lib/branch_checkout.tcl:44
msgid "Detach From Local Branch"
@@ -511,7 +513,7 @@ msgstr "Checkout dopo la creazione"
#: lib/branch_create.tcl:131
msgid "Please select a tracking branch."
-msgstr "Scegli un ramo in 'tracking'"
+msgstr "Scegliere un ramo in 'tracking'"
#: lib/branch_create.tcl:140
#, tcl-format
@@ -520,7 +522,7 @@ msgstr "Il ramo in 'tracking' %s non è un ramo nell'archivio remoto."
#: lib/branch_create.tcl:153 lib/branch_rename.tcl:86
msgid "Please supply a branch name."
-msgstr "Devi dare un nome al ramo."
+msgstr "Inserire un nome per il ramo."
#: lib/branch_create.tcl:164 lib/branch_rename.tcl:106
#, tcl-format
@@ -558,7 +560,7 @@ msgid ""
"\n"
" Delete the selected branches?"
msgstr ""
-"Recuperare rami cancellati può essere complicato. \n"
+"Prelevare rami cancellati può essere complicato. \n"
"\n"
" Eliminare i rami selezionati?"
@@ -589,7 +591,7 @@ msgstr "Nuovo Nome:"
#: lib/branch_rename.tcl:75
msgid "Please select a branch to rename."
-msgstr "Scegli un ramo da rinominare."
+msgstr "Scegliere un ramo da rinominare."
#: lib/branch_rename.tcl:96 lib/checkout_op.tcl:179
#, tcl-format
@@ -646,7 +648,7 @@ msgid ""
msgstr "Il ramo '%s' esiste già.\n"
"\n"
"Non può effettuare un 'fast-forward' a %s.\n"
-"E' richiesta una fusione."
+"E' necessaria una fusione."
#: lib/checkout_op.tcl:220
#, tcl-format
@@ -660,7 +662,7 @@ msgstr "Aggiornamento di '%s' fallito."
#: lib/checkout_op.tcl:251
msgid "Staging area (index) is already locked."
-msgstr "L'area di preparazione al commit (indice) è già bloccata."
+msgstr "L'area di preparazione per il commit (indice) è già bloccata."
#: lib/checkout_op.tcl:266
msgid ""
@@ -691,7 +693,7 @@ msgstr "E' richiesta una fusione a livello file."
#: lib/checkout_op.tcl:358
#, tcl-format
msgid "Staying on branch '%s'."
-msgstr "Resto sul ramo '%s'."
+msgstr "Si rimarrà sul ramo '%s'."
#: lib/checkout_op.tcl:429
msgid ""
@@ -700,9 +702,9 @@ msgid ""
"If you wanted to be on a branch, create one now starting from 'This Detached "
"Checkout'."
msgstr ""
-"Non sei più su un ramo locale.\n"
+"Non si è più su un ramo locale\n"
"\n"
-"Se volevi rimanere su un ramo, creane uno ora a partire da 'Questo checkout "
+"Se si vuole rimanere su un ramo, crearne uno ora a partire da 'Questo checkout "
"staccato'."
#: lib/checkout_op.tcl:478
@@ -712,7 +714,7 @@ msgstr "Ripristinare '%s' a '%s' comporterà la perdita dei seguenti commit:"
#: lib/checkout_op.tcl:500
msgid "Recovering lost commits may not be easy."
-msgstr "Recuperare commit perduti potrebbe non essere semplice."
+msgstr "Prelevare i commit perduti potrebbe non essere semplice."
#: lib/checkout_op.tcl:505
#, tcl-format
@@ -735,7 +737,7 @@ msgid ""
msgstr ""
"Preparazione ramo corrente fallita.\n"
"\n"
-"Questa directory di lavoro è stata convertita solo parzialmente. I tuoi file "
+"Questa directory di lavoro è stata convertita solo parzialmente. I file "
"sono stati aggiornati correttamente, ma l'aggiornamento di un file di Git ha "
"prodotto degli errori.\n"
"\n"
@@ -796,7 +798,7 @@ msgid ""
msgstr ""
"Non è possibile effettuare una correzione durante una fusione.\n"
"\n"
-"In questo momento stai effettuando una fusione che non è stata del tutto "
+"In questo momento si sta effettuando una fusione che non è stata del tutto "
"completata. Non puoi correggere il commit precedente a meno che prima tu non "
"interrompa l'operazione di fusione in corso.\n"
@@ -1117,7 +1119,7 @@ msgstr "Fusione fallita. Bisogna risolvere i conflitti."
#: lib/merge.tcl:158
#, tcl-format
msgid "Merge Into %s"
-msgstr "Fondi in %s"
+msgstr "Fusione in %s"
#: lib/merge.tcl:177
msgid "Revision To Merge"
@@ -1177,7 +1179,7 @@ msgstr "Interruzione completata. Pronto."
#: lib/option.tcl:77
msgid "git-gui - a graphical user interface for Git."
-msgstr "git-gui - una interfaccia grafica per Git."
+msgstr "git-gui - un'interfaccia grafica per Git."
#: lib/option.tcl:164
msgid "Restore Defaults"
@@ -1254,7 +1256,7 @@ msgstr "Remoto:"
#: lib/remote_branch_delete.tcl:66 lib/transport.tcl:133
msgid "Arbitrary URL:"
-msgstr ""
+msgstr "URL arbitrario:"
#: lib/remote_branch_delete.tcl:84
msgid "Branches"
@@ -1283,11 +1285,11 @@ msgid ""
"necessary commits. Try fetching from %s first."
msgstr ""
"Una o più verifiche di fusione sono fallite perché mancano i commit "
-"necessari. Prova prima a recuperarli da %s."
+"necessari. Prova prima a prelevarli da %s."
#: lib/remote_branch_delete.tcl:207
msgid "Please select one or more branches to delete."
-msgstr "Scegli uno o più rami da cancellare."
+msgstr "Scegliere uno o più rami da cancellare."
#: lib/remote_branch_delete.tcl:216
msgid ""
@@ -1295,7 +1297,7 @@ msgid ""
"\n"
"Delete the selected branches?"
msgstr ""
-"Recuperare rami cancellati è difficile.\n"
+"Prelevare rami cancellati è difficile.\n"
"\n"
"Cancellare i rami selezionati?"
@@ -1316,7 +1318,7 @@ msgstr "Analisi in corso %s..."
#: lib/remote.tcl:162
#, tcl-format
msgid "Fetch from %s..."
-msgstr "Recupera da %s..."
+msgstr "Preleva da %s..."
#: lib/remote.tcl:172
#, tcl-format
@@ -1384,3 +1386,4 @@ msgstr "Utilizza 'thin pack' (per connessioni lente)"
#: lib/transport.tcl:159
msgid "Include tags"
msgstr "Includi etichette"
+
--
1.5.3.rc4.29.g74276
^ permalink raw reply related
* Re: [PATCH] Further changes, thanks to <tp@lists.linux.it>
From: Paolo Ciarrocchi @ 2007-08-08 22:36 UTC (permalink / raw)
To: Michael; +Cc: git
In-Reply-To: <4d8e3fd30708081450n142bfea6tb30f063da0559f2e@mail.gmail.com>
On 8/8/07, Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> wrote:
> On 8/8/07, Michael <barra_cuda@katamail.com> wrote:
> > On Wednesday 08 August 2007 17:27, Paolo Ciarrocchi wrote:
> > > Further changes, thanks to <tp@lists.linux.it>
> > >
> > > Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com>
> > > ---
> >
> > Is it just me, or this patch is corrupted?
I pushed to the mob branch a new patch and sent to the list a new email.
Out of curiosity, what MUA do you use/suggest?
I use sylpheed-claws 1.0.5 but it ois not very gmail friendly, it
complains that it is not possible to deliver the message even if the
message is correctly delivered :-(
[00:38:16] ESMTP< 250 ENHANCEDSTATUSCODES
[00:38:16] ESMTP> [AUTH PLAIN]
[00:38:16] ESMTP< 235 2.7.0 Accepted
[00:38:16] ESMTP> MAIL FROM:<paolo.ciarrocchi@gmail.com> SIZE=360
[00:38:16] SMTP< 250 2.1.0 OK
[00:38:16] SMTP> RCPT TO:<paolo.ciarrocchi@gmail.com>
[00:38:17] SMTP< 250 2.1.5 OK
[00:38:17] SMTP> DATA
[00:38:17] SMTP< 354 Go ahead
[00:38:17] SMTP> . (EOM)
[00:38:23] SMTP< 250 2.0.0 OK 1186612547 w28sm1037333uge
[00:38:23] SMTP> QUIT
** Error occurred while sending the message.
Ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
^ permalink raw reply
* Re: [PATCH] checkout_entry: only try to create directories when no file existed there
From: Junio C Hamano @ 2007-08-08 22:40 UTC (permalink / raw)
To: Johannes Schindelin; +Cc: git
In-Reply-To: <Pine.LNX.4.64.0708082239120.21857@racer.site>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> Now, if we have to remove it, we did a stat() before that. It succeeded.
> So we know that "a/b/c/d/e/f/" exists. It might contain some symlinks,
> but it exists.
Yes, it is exactly the thing. It might contain a/b/c as symlink
but the index does not say a/b/c _IS_ a symlink, and the code
"fixes" that. Otherwise, you would get inconsistent result from
"git checkout" depending on random symlink you happen to have in
your working tree.
^ permalink raw reply
* Re: [PATCH] Further changes, thanks to <tp@lists.linux.it>
From: Paolo Ciarrocchi @ 2007-08-08 22:53 UTC (permalink / raw)
To: Michael; +Cc: git
In-Reply-To: <4d8e3fd30708081536t1ca75203xad14a2437ce07994@mail.gmail.com>
On 8/9/07, Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> wrote:
> I pushed to the mob branch a new patch and sent to the list a new email.
I don't see the patch in the list <sgrunt>
You can have a look at it pulling from the repository or pointing your
browser to:
http://repo.or.cz/w/git-gui/git-gui-i18n.git?a=commitdiff;h=01000140e8174e4ab32dd49cc2e910e8e2e5f914
Ciao,
--
Paolo
http://paolo.ciarrocchi.googlepages.com/
^ permalink raw reply
* Re: [PATCH] checkout_entry: only try to create directories when no file existed there
From: Johannes Schindelin @ 2007-08-08 22:54 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
In-Reply-To: <7vejid1wh2.fsf@assigned-by-dhcp.cox.net>
Hi,
On Wed, 8 Aug 2007, Junio C Hamano wrote:
> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
>
> > Now, if we have to remove it, we did a stat() before that. It succeeded.
> > So we know that "a/b/c/d/e/f/" exists. It might contain some symlinks,
> > but it exists.
>
> Yes, it is exactly the thing. It might contain a/b/c as symlink
> but the index does not say a/b/c _IS_ a symlink, and the code
> "fixes" that. Otherwise, you would get inconsistent result from
> "git checkout" depending on random symlink you happen to have in
> your working tree.
Ah, I see what you're getting to.
If user had a symlink called, say "syml", to, say $HOME, and now switches
to a branch which has "syml/.bash_profile", then the given code path would
try to replace the symlink with a directory.
Hmm.
Ciao,
Dscho
^ permalink raw reply
* [StGIT PATCH 0/2] Branch renaming bugfix
From: Karl Hasselström @ 2007-08-08 22:56 UTC (permalink / raw)
To: Catalin Marinas; +Cc: git
This series consists of a test that demonstrates a bug in the branch
renaming (failure to rename the branch.<branchname>.stgit section),
and a fix.
--
Karl Hasselström, kha@treskal.com
www.treskal.com/kalle
^ permalink raw reply
* [StGIT PATCH 1/2] Test that all branch config information is renamed
From: Karl Hasselström @ 2007-08-08 22:56 UTC (permalink / raw)
To: Catalin Marinas; +Cc: git
In-Reply-To: <20070808225522.17114.3065.stgit@yoghurt>
This test currently fails (which is precisely why it's needed, of
course.) This is bug 9692 in the bug tracker.
Signed-off-by: Karl Hasselström <kha@treskal.com>
---
t/t1001-branch-rename.sh | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/t/t1001-branch-rename.sh b/t/t1001-branch-rename.sh
index 28da15c..28af8ae 100755
--- a/t/t1001-branch-rename.sh
+++ b/t/t1001-branch-rename.sh
@@ -26,7 +26,8 @@ test_expect_success \
'Rename an stgit branch' \
'stg branch -c buz &&
stg branch -r foo bar &&
- test -z `find .git -name foo | tee /dev/stderr`
+ test -z `find .git -name foo | tee /dev/stderr` &&
+ test -z $(git config -l | grep branch\\.foo)
'
test_done
^ permalink raw reply related
* [StGIT PATCH 2/2] Rename all config sections of a branch
From: Karl Hasselström @ 2007-08-08 22:56 UTC (permalink / raw)
To: Catalin Marinas; +Cc: git
In-Reply-To: <20070808225522.17114.3065.stgit@yoghurt>
Just renaming the branch.branchname section doesn't rename the
branch.branchname.stgit section -- we have to do that explicitly.
This fixes bug 9692.
Signed-off-by: Karl Hasselström <kha@treskal.com>
---
stgit/stack.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/stgit/stack.py b/stgit/stack.py
index dbd7ea4..9c15b3f 100644
--- a/stgit/stack.py
+++ b/stgit/stack.py
@@ -616,8 +616,8 @@ class Series(PatchSet):
self.get_name(), to_stack.get_name())
# Rename the config section
- config.rename_section("branch.%s" % self.get_name(),
- "branch.%s" % to_name)
+ for k in ['branch.%s', 'branch.%s.stgit']:
+ config.rename_section(k % self.get_name(), k % to_name)
self.__init__(to_name)
^ permalink raw reply related
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: Junio C Hamano @ 2007-08-08 22:59 UTC (permalink / raw)
To: David Kastrup; +Cc: git
In-Reply-To: <591c5679ea79b76cd5db57443b1d691bde842351.1186484406.git.dak@gnu.org>
David Kastrup <dak@gnu.org> writes:
> @@ -139,6 +154,18 @@ XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css
> user-manual.html: user-manual.xml
> xsltproc $(XSLTOPTS) -o $@ $(XSLT) $<
>
> +git.info: user-manual.xml
> + $(RM) $@ $*.texi
> + $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout | \
> + perl -ne 'if (/^\@setfilename/) {$$_="\@setfilename git.info\
> +"} elsif (/^\@direntry/) {print "\@dircategory Development\
> +\@direntry\
> +* Git: (git). A fast distributed revision control system\
> +\@end direntry\
> +"} print unless (/^\@direntry/ .. /^\@end direntry/)' > $*.texi
> + $(MAKEINFO) --no-split $*.texi
> + $(RM) $*.texi
> +
This part worries me.
Historically (as you probably know, having suffered a lot more
than me with this issue), multi-line command script in Makefile
was hugely unportable. Some "make" implementations stripped
backslash linefeed at the end, some other implementations
stripped only backslash, yet some other kept both backslash and
linefeed. It was a mess.
Admittably we are already quite dependent on GNU make, so this
is probably not a huge deal, but I have a vague recollection
that even GNU make itself changed its behaviour over time with
respect to this exact area, and I had to adjust a few Makefiles
to accomodate both old and new GNU make.
The standard workaround is of course to have this perl script
part as a separate, "Documentation/fixup-texi.perl" script and
invoke it from the Makefile.
^ permalink raw reply
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: Junio C Hamano @ 2007-08-08 23:05 UTC (permalink / raw)
To: David Kastrup; +Cc: git
In-Reply-To: <7vabt11vkj.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
> David Kastrup <dak@gnu.org> writes:
>
>> @@ -139,6 +154,18 @@ XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css
>> user-manual.html: user-manual.xml
>> xsltproc $(XSLTOPTS) -o $@ $(XSLT) $<
>>
>> +git.info: user-manual.xml
>> + $(RM) $@ $*.texi
>> + $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout | \
>> + perl -ne 'if (/^\@setfilename/) {$$_="\@setfilename git.info\
>> +"} elsif (/^\@direntry/) {print "\@dircategory Development\
>> +\@direntry\
>> +* Git: (git). A fast distributed revision control system\
>> +\@end direntry\
>> +"} print unless (/^\@direntry/ .. /^\@end direntry/)' > $*.texi
>> + $(MAKEINFO) --no-split $*.texi
>> + $(RM) $*.texi
>> +
>
> This part worries me.
Aside from possible portability issue of multi-line script,
there is another slight problem I am not sure if it is worth
fixing. If you do not have docbook2x-texi installed, nobody
notices that resulting $*.texi was a garbage and an almost empty
git.info is generated.
^ permalink raw reply
* Re: git on Cygwin: Not a valid object name HEAD
From: Mark Levedahl @ 2007-08-08 23:07 UTC (permalink / raw)
To: Steffen Prohaska; +Cc: Git Mailing List
In-Reply-To: <7E22DF40-1E28-4B8A-B132-18B05136B5E9@zib.de>
Steffen Prohaska wrote:
>
Let me guess, you have Cygwin on the path along with Msys, and had it
that way when you downloaded the package and it tried to build. Hmmm.
Maybe Cygwin executables conflict with Msys executables. Nah. Couldn't
be. Must be a bug.
Mark
^ permalink raw reply
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: Junio C Hamano @ 2007-08-08 23:18 UTC (permalink / raw)
To: David Kastrup; +Cc: git
In-Reply-To: <7v643p1vbr.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
>> This part worries me.
>
> Aside from possible portability issue of multi-line script,
> there is another slight problem I am not sure if it is worth
> fixing. If you do not have docbook2x-texi installed, nobody
> notices that resulting $*.texi was a garbage and an almost empty
> git.info is generated.
How about doing something like this instead?
---
Documentation/Makefile | 13 ++++---------
Documentation/fix-texi.perl | 15 +++++++++++++++
2 files changed, 19 insertions(+), 9 deletions(-)
create mode 100755 Documentation/fix-texi.perl
diff --git a/Documentation/Makefile b/Documentation/Makefile
index 56d12aa..8c33729 100644
--- a/Documentation/Makefile
+++ b/Documentation/Makefile
@@ -154,16 +154,11 @@ user-manual.html: user-manual.xml
xsltproc $(XSLTOPTS) -o $@ $(XSLT) $<
git.info: user-manual.xml
- $(RM) $@ $*.texi
- $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout | \
- perl -ne 'if (/^\@setfilename/) {$$_="\@setfilename git.info\
-"} elsif (/^\@direntry/) {print "\@dircategory Development\
-\@direntry\
-* Git: (git). A fast distributed revision control system\
-\@end direntry\
-"} print unless (/^\@direntry/ .. /^\@end direntry/)' > $*.texi
+ $(RM) $@ $*.texi $*.texi+
+ $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout >$*.texi+
+ perl fix-texi.perl <$*.texi+ >$*.texi
$(MAKEINFO) --no-split $*.texi
- $(RM) $*.texi
+ $(RM) $*.texi $*.texi+
howto-index.txt: howto-index.sh $(wildcard howto/*.txt)
$(RM) $@+ $@
diff --git a/Documentation/fix-texi.perl b/Documentation/fix-texi.perl
new file mode 100755
index 0000000..ff7d78f
--- /dev/null
+++ b/Documentation/fix-texi.perl
@@ -0,0 +1,15 @@
+#!/usr/bin/perl -w
+
+while (<>) {
+ if (/^\@setfilename/) {
+ $_ = "\@setfilename git.info\n";
+ } elsif (/^\@direntry/) {
+ print '@dircategory Development
+@direntry
+* Git: (git). A fast distributed revision control system
+@end direntry
+'; }
+ unless (/^\@direntry/../^\@end direntry/) {
+ print;
+ }
+}
^ permalink raw reply related
* Re: 'pu' branch for StGIT
From: Karl Hasselström @ 2007-08-08 23:23 UTC (permalink / raw)
To: Pavel Roskin; +Cc: git, Catalin Marinas, Yann Dirson
In-Reply-To: <1186611514.7383.4.camel@dv>
On 2007-08-08 18:18:34 -0400, Pavel Roskin wrote:
> On Wed, 2007-08-08 at 23:39 +0200, Karl Hasselström wrote:
>
> > I can't reproduce.
>
> OK, it's trickier. There are some bad patch names that don't get
> imported properly. In particular, patches ending with ".diff" are
> committed after import.
Ah, sneaky. And it turns out to be not a problem with import, but a
problem with dots in patch names. It's just that import is the only
place those are typically created.
It was all due to a sloppy regexp. This is the fix:
diff --git a/stgit/stack.py b/stgit/stack.py
index 4186ba9..c403f51 100644
--- a/stgit/stack.py
+++ b/stgit/stack.py
@@ -391,11 +391,11 @@ def read_refs(branch):
given branch. The patches are listed by name; the branch head is
None."""
refs = {}
- patchpat = re.compile(r'^refs/patches/%s/([^\.]+)$' % branch)
+ patchpat = re.compile(r'^refs/patches/%s/(.+)$' % branch)
for line in git._output_lines('git-show-ref'):
sha1, ref = line.split()
m = re.match(patchpat, ref)
- if m:
+ if m and not m.group(1).endswith('.log'):
refs[m.group(1)] = sha1
elif ref == 'refs/heads/%s' % branch:
refs[None] = sha1
Thanks for taking the time to track this down -- with the detailed
symptoms you gave, I found it in no time. I've pushed an updated
series (as well as the other patches I've posted tonight) to
git://repo.or.cz/stgit/kha.git.
--
Karl Hasselström, kha@treskal.com
www.treskal.com/kalle
^ permalink raw reply related
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: David Kastrup @ 2007-08-08 23:25 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
In-Reply-To: <7vabt11vkj.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
> David Kastrup <dak@gnu.org> writes:
>
>> +git.info: user-manual.xml
>> + $(RM) $@ $*.texi
>> + $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout | \
>> + perl -ne 'if (/^\@setfilename/) {$$_="\@setfilename git.info\
>> +"} elsif (/^\@direntry/) {print "\@dircategory Development\
>> +\@direntry\
>> +* Git: (git). A fast distributed revision control system\
>> +\@end direntry\
>> +"} print unless (/^\@direntry/ .. /^\@end direntry/)' > $*.texi
>> + $(MAKEINFO) --no-split $*.texi
>> + $(RM) $*.texi
>> +
>
> This part worries me.
>
> Historically (as you probably know, having suffered a lot more
> than me with this issue), multi-line command script in Makefile
> was hugely unportable. Some "make" implementations stripped
> backslash linefeed at the end, some other implementations
> stripped only backslash, yet some other kept both backslash and
> linefeed. It was a mess.
>
> Admittably we are already quite dependent on GNU make,
Yes, definitely. That's why I did it that way in the first place. It
is probably not inconceivable, however, that even then some
combination of make port and perl port to Windows would get into a
tizzy.
> so this is probably not a huge deal, but I have a vague recollection
> that even GNU make itself changed its behaviour over time with
> respect to this exact area, and I had to adjust a few Makefiles to
> accomodate both old and new GNU make.
I have to admit that I did not know in advance how this would work out
and adapted the code to the behavior.
> The standard workaround is of course to have this perl script
> part as a separate, "Documentation/fixup-texi.perl" script and
> invoke it from the Makefile.
I can code this as a single overlong line reasonably easy. And it is
not actually necessary to do the @setfilename replacement: one can
just specify an override of the output file name. That shortens the
Perl script. I'll have to see whether I can get rid of it completely,
but the documentation for docbook2X is really bad (and the author did
not respond to Email yet). And googling on the net showed that I am
not the only one who fixed up after docbook2X manually.
Don't expect a new patch in this area soon: I am messing with other
stuff right now and it does not make sense reworking this again when I
am not sure yet whether I can throw it out altogether.
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
^ permalink raw reply
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: David Kastrup @ 2007-08-08 23:27 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
In-Reply-To: <7v643p1vbr.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
> Junio C Hamano <gitster@pobox.com> writes:
>
>> David Kastrup <dak@gnu.org> writes:
>>
>>> @@ -139,6 +154,18 @@ XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css
>>> user-manual.html: user-manual.xml
>>> xsltproc $(XSLTOPTS) -o $@ $(XSLT) $<
>>>
>>> +git.info: user-manual.xml
>>> + $(RM) $@ $*.texi
>>> + $(DOCBOOK2X_TEXI) user-manual.xml --to-stdout | \
>>> + perl -ne 'if (/^\@setfilename/) {$$_="\@setfilename git.info\
[...]
> Aside from possible portability issue of multi-line script, there is
> another slight problem I am not sure if it is worth fixing. If you
> do not have docbook2x-texi installed, nobody notices that resulting
> $*.texi was a garbage and an almost empty git.info is generated.
Good catch.
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
^ permalink raw reply
* Re: git-svn: commit author x commit committer issue
From: Quy Tonthat @ 2007-08-08 15:42 UTC (permalink / raw)
To: Richard MUSIL; +Cc: git
In-Reply-To: <46B9C92B.3000000@st.com>
Richard MUSIL wrote:
> Normally, when patch is applied, git distinguishes commit author and
> commit committer (relying on info from patch).
> However, after the patches are committed to svn repository using:
> git-svn dcommit
> author and committer data are set to same values (or at least time and
> date, I cannot verify it for names).
> I wonder if there is any reason for this behavior, because I would
> definitely like to keep original commit info (which came from patch) in
> my git repository.
I'm sure this worked before (author and committee are different, that is).
Something went wrong recently but I haven't got time to look into the problem.
I hope someone would.
Quy
^ permalink raw reply
* Re: [install info (using perl) 1/2] Add support for an info version of the user manual
From: David Kastrup @ 2007-08-08 23:46 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
In-Reply-To: <7v1wed1up3.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
> Junio C Hamano <gitster@pobox.com> writes:
>
> How about doing something like this instead?
>
> ---
>
> Documentation/Makefile | 13 ++++---------
> Documentation/fix-texi.perl | 15 +++++++++++++++
> 2 files changed, 19 insertions(+), 9 deletions(-)
> create mode 100755 Documentation/fix-texi.perl
>
> diff --git a/Documentation/Makefile b/Documentation/Makefile
> index 56d12aa..8c33729 100644
> --- a/Documentation/Makefile
> +++ b/Documentation/Makefile
> new file mode 100755
> index 0000000..ff7d78f
> --- /dev/null
> +++ b/Documentation/fix-texi.perl
[...]
It makes Perl look like a programming language instead of line noise.
But putting it into a file with .perl extension will make users
recognize it nevertheless. So
Acked-by: David Kastrup <dak@gnu.org>
I can fold this patch in and repost (probably not too many people have
applied the previous patches and would require a good fast forward
path, so one would probably not need a 3-commit version built on top
of the existing patches), or you may do so at your discretion.
Thanks, looks much nicer. I still hope to rationalize Perl away
altogether at some point of time, but...
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
^ permalink raw reply
* [PATCH] allow git-bundle to create bottomless bundle
From: Junio C Hamano @ 2007-08-09 0:01 UTC (permalink / raw)
To: Johannes Schindelin
Cc: Shawn O. Pearce, Nguyen Thai Ngoc Duy, Git Mailing List,
Mark Levedahl
In-Reply-To: <7vlkcl4zcw.fsf@assigned-by-dhcp.cox.net>
While "git bundle" was a useful way to sneakernet incremental
changes, we did not allow:
$ git bundle create v2.6.20.bndl v2.6.20
to create a bundle that contains the whole history to a
well-known good revision. Such a bundle can be mirrored
everywhere, and people can prime their repository with it to
reduce the load on the repository that serves near the tip of
the development.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
Junio C Hamano <gitster@pobox.com> writes:
> *1* Sheesh. While I was writing this I noticed that the current
> 'git bundle' is suitable only for incremental sneakernet but
> not for this particular use case.
>
> $ git bundle create 2612.bndl v2.6.12
>
> does not work, although
>
> $ git bundle create 2612-2613.bndl v2.6.12..v2.6.13
>
> does. We need to fix this.
Only very lightly tested, but the fix looks obvious enough.
builtin-bundle.c | 10 +++++++++-
t/t5510-fetch.sh | 8 ++++++++
2 files changed, 17 insertions(+), 1 deletions(-)
diff --git a/builtin-bundle.c b/builtin-bundle.c
index 6ae5ab0..cb439ca 100644
--- a/builtin-bundle.c
+++ b/builtin-bundle.c
@@ -208,6 +208,10 @@ static int create_bundle(struct bundle_header *header, const char *path,
struct rev_info revs;
struct child_process rls;
+ /*
+ * NEEDSWORK: this should use something like lock-file
+ * to create temporary that is cleaned up upon error.
+ */
bundle_fd = (!strcmp(path, "-") ? 1 :
open(path, O_CREAT | O_EXCL | O_WRONLY, 0666));
if (bundle_fd < 0)
@@ -267,8 +271,12 @@ static int create_bundle(struct bundle_header *header, const char *path,
* Make sure the refs we wrote out is correct; --max-count and
* other limiting options could have prevented all the tips
* from getting output.
+ *
+ * Non commit objects such as tags and blobs do not have
+ * this issue as they are not affected by those extra
+ * constraints.
*/
- if (!(e->item->flags & SHOWN)) {
+ if (!(e->item->flags & SHOWN) && e->item->type == OBJ_COMMIT) {
warning("ref '%s' is excluded by the rev-list options",
e->name);
continue;
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index 426017e..439430f 100755
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
@@ -145,4 +145,12 @@ test_expect_success 'bundle does not prerequisite objects' '
test 4 = $(git verify-pack -v bundle.pack | wc -l)
'
+test_expect_success 'bundle should be able to create a full history' '
+
+ cd "$D" &&
+ git tag -a -m '1.0' v1.0 master &&
+ git bundle create bundle4 v1.0
+
+'
+
test_done
^ permalink raw reply related
* Re: 'pu' branch for StGIT
From: Pavel Roskin @ 2007-08-09 0:10 UTC (permalink / raw)
To: Karl Hasselström; +Cc: git, Catalin Marinas, Yann Dirson
In-Reply-To: <20070808232349.GA23172@diana.vm.bytemark.co.uk>
Quoting Karl Hasselström <kha@treskal.com>:
> It was all due to a sloppy regexp. This is the fix:
Thank you!
And by the way, please fix the description of the commit where you
added --smtp-server option. You added it to "stg mail", not to "stg
add".
--
Regards,
Pavel Roskin
^ permalink raw reply
* Re: [PATCH] allow git-bundle to create bottomless bundle
From: Johannes Schindelin @ 2007-08-09 0:28 UTC (permalink / raw)
To: Junio C Hamano
Cc: Shawn O. Pearce, Nguyen Thai Ngoc Duy, Git Mailing List,
Mark Levedahl
In-Reply-To: <7vps1xzic2.fsf_-_@assigned-by-dhcp.cox.net>
Hi,
On Wed, 8 Aug 2007, Junio C Hamano wrote:
> + *
> + * Non commit objects such as tags and blobs do not have
> + * this issue as they are not affected by those extra
> + * constraints.
> */
> - if (!(e->item->flags & SHOWN)) {
> + if (!(e->item->flags & SHOWN) && e->item->type == OBJ_COMMIT) {
That is all? Heh.
Thanks for fixing this bug,
Dscho
^ permalink raw reply
* Re: [PATCH] allow git-bundle to create bottomless bundle
From: Mark Levedahl @ 2007-08-09 2:48 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Johannes Schindelin, Git Mailing List, Mark Levedahl
In-Reply-To: <7vps1xzic2.fsf_-_@assigned-by-dhcp.cox.net>
Junio C Hamano wrote:
> While "git bundle" was a useful way to sneakernet incremental
> changes, we did not allow:
>
Thanks - I've been thinking for months I could fix this bug, never
figured it out and didn't want to nag Dscho one more time. I confirm
that this allows creation of bundles with arbitrary refs, not just those
under refs/heads. Yahoo!
Mark
^ 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