git mailing list

FromSubjectsort iconDate
Carlos Rica
graphical committing micro-tutorial for newbies
This is an image created by me after reading the second tutorial to graphically show the commands explained in the last part of it. It could be valuable to help newbies to understand those steps. Unfortunatelly, I used a bitmap editor to draw it quickly, so now it is difficult to modify, but I hope you will catch the idea. Others can use it to explain things or even make it more complete. You can copy, publish or modify it for whatever you want. You don't need to ask me first for ...
Aug 28, 4:16 pm 2007
Petr Baudis
[PATCH 2/2] git-add: Make the filename globbing note a b ...
I think the trick with Git-side filename globbing is important and perhaps not that well know. Clarify a bit in git-add documentation what it means. Signed-off-by: Petr Baudis <pasky@suse.cz> --- Documentation/git-add.txt | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Documentation/git-add.txt b/Documentation/git-add.txt index e5efbc9..2fe7355 100644 --- a/Documentation/git-add.txt +++ b/Documentation/git-add.txt @@ -33,9 +33,9 @@ files have changes that ...
Aug 28, 3:41 pm 2007
Petr Baudis
[PATCH 1/2] git-add: Make the "tried to add ignored file ...
Currently the error message seems to imply (at least to me) that only the listed files were withheld and the rest of the files was added to the index, even though that's obviously not the case. Signed-off-by: Petr Baudis <pasky@suse.cz> --- builtin-add.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/builtin-add.c b/builtin-add.c index b08e688..105a9f0 100644 --- a/builtin-add.c +++ b/builtin-add.c @@ -155,7 +155,7 @@ static int git_add_config(const char ...
Aug 28, 3:41 pm 2007
Simon Sasburg
Subject: [PATCH] git-svn: improve git-svn find-rev outpu ...
For one of my projects I've been using 'svnversion' to automatically generate a 'build number' to include in the version string of the project. 'svnversion' will output the revision of the current checkout, possibly with an 'M' appended if you've made local modifications. This obviously wont work if you have a git-svn repository instead of an svn checkout. This patch adds this behaviour to git-svn find-rev, so 'git-svn find-rev HEAD' should be usable instead of 'svnversion'. Previously ...
Aug 28, 3:38 pm 2007
Jari Aalto
[PATCH] Require exactly 7 char width unresolved merge co ...
Add end anchor to limit regexp '[<>=]){7}'; the size of the conflict markers. This prevents in some extent incorrect matches of underlined headings: HEADINGS LIKE THIS ================== Other changes: - Collapse multiple Perl warn functions calls into onex - Add empty lines to separate code chunk paragraphs - Add prototype to function definition: sub bad_line ($,$) - Change 'print STDERR' calls to standard warn() Signed-off-by: Jari Aalto <jari.aalto@cante.net> --- ...
Aug 28, 3:37 pm 2007
Junio C Hamano
Re: [PATCH] Require exactly 7 char width unresolved merg ...
I thought modern file-level merge added comments on where things came from on <<< and >>> lines. Insisting on /^={7}$/ might be I would usually say "Don't. If you want to have clean-up patches, do them as separate patches, please", here. This is especially true if your primary point of the patch is sound but "Other changes" are questionable --- you do not want a good fix Ok, but I can see you haven't even tested this patch with one of the warn that supposedly has three strings as ...
Aug 28, 5:04 pm 2007
Patrick Aljord
best practice for a 3 devs team?
Hey all, We are 3 developers working on the same project. I was thinking what would be the best practice for us. We have just switched from svn and for now we are all working on the master branch that we push to a ssh git repository. I was thinking about maybe each of us could create our own branch like 'git branch <dev_name>' but then how would it go? Each one of us would push our own branch to the remote repository and each one of us could cherry pick the change from the remote branch of each ...
Aug 28, 3:20 pm 2007
Andreas Ericsson
Re: best practice for a 3 devs team?
This is what we do at work. We're 3-6 developers on each project, and each of us have our own branch, into which we merge our topic-branches. Someone is then designated integrator of the project, and responsible for merging branches or cherrypicking commits into master. In our case, we use 'testing' rather than 'master', to denote that the test-department should take over and try out all the features/fixes we've added. The test-team only ever gets email when something ends up on their ...
Aug 28, 3:38 pm 2007
Andrew Grover
Re: stg doesn't like git commit --amend
Thanks, missed that. -- Andy -
Aug 28, 1:52 pm 2007
Andrew Grover
stg doesn't like git commit --amend
See below. Using stg with git commit --amend creates big problems, yet stg has no way (?) to alter commit descriptions. Any advice? Thanks -- Andy [agrover@sitar git]$ stg version Stacked GIT 0.12.1 git version 1.5.2.4 Python version 2.5 (r25:51908, Apr 10 2007, 10:27:40) [GCC 4.1.2 20070403 (Red Hat 4.1.2-8)] [agrover@sitar git]$ stg clone linux-2.6/ stg-smp Cloning "linux-2.6/" into "stg-smp"... Initialized empty Git repository in /home/agrover/git/stg-smp/.git/ remote: Generating ...
Aug 28, 1:44 pm 2007
Petr Baudis
Re: stg doesn't like git commit --amend
stg refresh -e ? -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 1:49 pm 2007
Jakub Narebski
Re: repo.or.cz wishes?
From http://en.wikipedia.org/wiki/Transport_Secure_Layer (emphasizis in the form of capital letters mine) TLS provides endpoint authentication and communications privacy over the Internet using cryptography. Typically, only the server is authenticated (i.e., its identity is ensured) while the client remains unauthenticated; this means that the end user (whether an individual or an application, such as a Web browser) can be sure with whom they are communicating. The next level of ...
Aug 28, 11:51 am 2007
Petr Baudis
Re: [PATCH] gitweb: Fix escaping HTML of project owner i ...
Acked-by: Petr Baudis <pasky@suse.cz> -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 10:33 am 2007
Jon Smirl
Re: [PATCH] gitweb: Fix escaping HTML of project owner i ...
I added the escapes, I'm just getting confused about when I need to escape and not escape in gitweb. It is not consistent everywhere. The -- Jon Smirl jonsmirl@gmail.com -
Aug 28, 11:46 am 2007
Jakub Narebski
[PATCH] gitweb: Fix escaping HTML of project owner in 'p ...
This for example allows to put email address in the project owner field in the projects index file (when $projects_list points to a file, and not to a directory), in the form of: path/to/repo.git Random+J+Developer+<random@developer.example.org> Noticed-by: Jon Smirl <jonsmirl@gmail.com> Signed-off-by: Jakub Narebski <jnareb@gmail.com> --- This is resend of a patch which appeared at the bottom of email deep in the "gitweb-projects", as Message-Id: ...
Aug 28, 7:05 am 2007
Jon Smirl
Re: [PATCH] gitweb: Fix escaping HTML of project owner i ...
I tried adding an email address to hometext.html yesterday, I got the same XML errors caused by the <> that I received in the project owner -- Jon Smirl jonsmirl@gmail.com -
Aug 28, 11:27 am 2007
Jakub Narebski
Re: [PATCH] gitweb: Fix escaping HTML of project owner i ...
Be it HTML or XHTML fragment, you have to escape '<' and '>' yourself, by using '<' and '&rt;' entities; if we HTML-escaped contents of hometext.html (BTW. the filename depends on build time configuration) we could not put for example links there... -- Jakub Narebski Poland -
Aug 28, 11:39 am 2007
Jakub Narebski
Re: [PATCH] gitweb: Fix escaping HTML of project owner i ...
Actually it is _different_ problem, because while projects list file is meant to be *plain text* file with two space separated, URL-encoded strings per line, hometext.html (and header.html, gooter.html and per repository README.html) is meant as a *fragment* to insert on gitweb page, and of course it should follow the same syntax as main gitweb page. Which might be HTML, or might be XHTML. So if you need something which needs escaping, do this in hometext.html. -- Jakub ...
Aug 28, 11:25 am 2007
Jon Smirl Aug 28, 11:08 am 2007
Josh England
cloning/pulling hooks
When cloning an existing repository, is there any way to grab the .git/hooks files as part of the clone (or pull)? -JE -
Aug 28, 9:46 am 2007
Petr Baudis
Re: cloning/pulling hooks
Hi, No. You can add the appropriate instructions to instructions how to clone the repository, users have to install the hooks manually. Now I went on with a large writeup on considerations for implementing such a feature (including security), but then I scrapped it. What would you like to use these hooks for? Really, perhaps it's best to instead do any "post-commit" etc. checks at the push time instead of the commit time, so that developers can still freely commit locally, e.g. ...
Aug 28, 10:27 am 2007
Josh England
Re: cloning/pulling hooks
Thanks Petr. I think I'll look at using the git clone --template functionality and just keep my own templates around. -JE -
Aug 28, 10:35 am 2007
Johannes Sixt
gitk: cherry-pick issue
Please run this on a checkout of git.git: $ git checkout -b gitktmp v1.5.3-rc6 $ gitk HEAD^.. 324a8bd Then right-click on 324a8bd git-send-email --cc-cmd (which is in 'next') and choose "Cherry-pick this commit". I get this error: can't read "nbmp": no such variable can't read "nbmp": no such variable (reading value of variable to increment) invoked from within "incr nbmp" (procedure "addnewchild" line 11) invoked from within "addnewchild $newhead ...
Aug 28, 9:24 am 2007
Paul Mackerras
Re: gitk: cherry-pick issue
I assume you have "Show nearby tags" turned off. I'll fix it, but in the short term you can work around it by turning "Show nearby tags" on. Paul. -
Aug 28, 4:31 pm 2007
Junio C Hamano
Re: EDITOR with tilde not expanded in git-commit
All true. Does the one in git-sh-setup.sh do that correctly? For arguments I think it does the right thing (eval ... '"$@"' means "give the four letter string " $ @ " to the shell, have it expand and split the args --- which essentially means do not molest them with $IFS). For the command name part, it does: eval "${GIT_EDITOR:=vi}" '"$@"' which means that you need to say GIT_EDITOR="'/home/my programs/emacs' -nw" if you installed your emacs in "/home/my programs/" ...
Aug 28, 2:56 pm 2007
Junio C Hamano
Re: EDITOR with tilde not expanded in git-commit
is a _good_ compromise. It just was that it would make it even _better_ compromise if we can demonstrate that the above setting would work equally well with other programs. -
Aug 28, 4:46 pm 2007
David Kastrup
Re: EDITOR with tilde not expanded in git-commit
In any case, should be addressed with commit 08874658b450600e72bb7cb0d0747c1ec4b0bfe1 from the first of August. -- David Kastrup -
Aug 28, 8:25 am 2007
David Kastrup
Re: EDITOR with tilde not expanded in git-commit
Huh? It could execute arbitrary code, like an editor. Which is the whole point of the variable. What you might be thinking of is that it might execute material which has a non-local impact on the calling environment. If that is your concern, just wrap the eval inside of parens, like (eval ...). But frankly: setuid shell scripts are a security hole fit to drive a truck through, anyway. One does not need eval for that. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum -
Aug 28, 2:55 pm 2007
Matthieu Moy
Re: EDITOR with tilde not expanded in git-commit
That's definitely a problem, but since environment variables can't contain complex data-structures, you have no other way to allow the user to specify a command with multiple arguments (EDITOR="emacs -nw" for example). Anyway, if you had a space in your $HOME, you would already have quoted it in $EDITOR before using git, because this is the way other Without the eval, you also treat data as code. If you set EDITOR=halt, whether or not you use eval, "git commit" will shutdown your ...
Aug 28, 9:05 am 2007
Bill Lear
Re: EDITOR with tilde not expanded in git-commit
Interesting, this uses eval: git_editor() { : "${GIT_EDITOR:=$(git config core.editor)}" : "${GIT_EDITOR:=${VISUAL:-${EDITOR}}}" [...] eval "${GIT_EDITOR:=vi}" '"$@"' } I was told eval was "wrong on multiple levels". Bill -
Aug 28, 8:36 am 2007
Thomas Adam
Re: EDITOR with tilde not expanded in git-commit
You're not allowed that anyway. It's simply ignored for shell scripts. (Will this shed-painting ever end?) -- Thomas Adam -
Aug 28, 2:59 pm 2007
Randal L. Schwartz
Re: EDITOR with tilde not expanded in git-commit
>>>>> "Bill" == Bill Lear <rael@zopyra.com> writes: Bill> I was told eval was "wrong on multiple levels". I should elaborate. Using "eval" here means that you *then* have to be careful about whitespace quoting. For example, if my $HOME had a space in it, EDITOR="$HOME/bin/superemacs" would be broken if you add the extra eval, since the whitespace would be treated as a delimeter on the second lexing. I'd have to figure out how to set EDITOR with the right quotes or backwhacks in it ...
Aug 28, 8:55 am 2007
Johannes Schindelin
Re: EDITOR with tilde not expanded in git-commit
Hi, Yes, I never felt good about our change in the EDITOR handling. In related news, I don't see why Bill's colleague does not just change the broken ~ to the proper $HOME. Ciao, Dscho -
Aug 28, 2:01 pm 2007
David Kastrup
Re: EDITOR with tilde not expanded in git-commit
You can't have both the ability to use a command with options as well as an unquoted command with spaces in its path. It is rather glaringly obvious. A space is a space is a space. Without a way of quoting it, the argument splitting space is the same the path-contained one. If you do something like woozle='"a b c"' set $woozle echo $1 echo $2 echo $3 you get "a b c" Quotes don't get reinterpreted. At this level, only IFS-splitting If you are lucky. There is also the ...
Aug 28, 3:22 pm 2007
David Kastrup
Re: EDITOR with tilde not expanded in git-commit
EDITOR="\"$HOME/bin/superemacs\" -nw" It's like most of the rest of the world reads the EDITOR variable and there is little point for git not to follow suit. It has been tested and discussed. That you missed this because of your killfile Quite so. ~ is really something mostly for interactive use. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum -
Aug 28, 3:07 pm 2007
Kyle Rose
Re: EDITOR with tilde not expanded in git-commit
It's not clear to me how this ever would have worked. Programs *can* execute $EDITOR with system(3), but it's possible they could execute it with exec, in which case the binary "~/bin/xemacs -nw" definitely would not be found. The right solution to this IMO is to do both of the following: (1) Create a shell script ~/bin/xemacs-nox that contains #! /bin/bash xemacs -nw "$@" (2) Set the editor to EDITOR=~/bin/xemacs-nox Note the distinct LACK of double quotes around the value, which ...
Aug 28, 8:22 am 2007
Randal L. Schwartz
Re: EDITOR with tilde not expanded in git-commit
>>>>> "Matthieu" == Matthieu Moy <Matthieu.Moy@imag.fr> writes: Matthieu> C does not have tilde expansion or "eval", but it has "system()": Matthieu> int main () { Matthieu> system("~/bin/scripts/moy-editor.sh foo.txt"); Matthieu> } Matthieu> works as you'd expect. And that's because it forks a /bin/sh to process that. And your modern /bin/sh apparently understands tilde expansion. *that* wouldn't have worked back when /bin/sh was really the bourne shell and not some cheap ...
Aug 28, 9:00 am 2007
Randal L. Schwartz
Re: EDITOR with tilde not expanded in git-commit
>>>>> "Bill" == Bill Lear <rael@zopyra.com> writes: Bill> Of course, and one could use a full path also, but tilde is a Bill> perfectly valid replacement for $HOME, Only to a shell. The kernel has no clue about it. I'd even say "only to *some* shells" as well, but most modern shells now understand it. Bill> and I think git should support Bill> it, and not force the user to work around it. The eval solution is wrong on multiple levels. -- Randal L. Schwartz - Stonehenge Consulting ...
Aug 28, 8:16 am 2007
Nguyen Thai Ngoc Duy
Re: EDITOR with tilde not expanded in git-commit
Why not set EDITOR="$HOME/bin/xemacs -nw"? It should work well IMHO. -- Duy -
Aug 28, 7:37 am 2007
Bill Lear
Re: EDITOR with tilde not expanded in git-commit
Of course, and one could use a full path also, but tilde is a perfectly valid replacement for $HOME, and I think git should support it, and not force the user to work around it. Bill -
Aug 28, 7:44 am 2007
Mike Hommey
Re: EDITOR with tilde not expanded in git-commit
The right question is more, what is your /bin/sh. $ EDITOR="~/bin/xemacs -nw"; ${VISUAL:-${EDITOR:-vi}} foo bash: ~/bin/xemacs: No such file or directory $ EDITOR="~/bin/xemacs -nw"; ${VISUAL:-${EDITOR:-vi}} foo dash: ~/bin/xemacs: not found Mike -
Aug 28, 8:20 am 2007
Alex Riesen
Re: EDITOR with tilde not expanded in git-commit
EDITOR=~/bin/xemacs\ -nw No need for the script. -
Aug 28, 10:47 am 2007
Kyle Rose
Re: EDITOR with tilde not expanded in git-commit
As I stated in the message to which you replied, that only works if the calling program is guaranteed to use system or its equivalent to load the $EDITOR. Git et al. may do that, but I don't know that there's any guarantee of it working universally: other programs do use $EDITOR, you know. ;-) That's why I recommend a script: simple and universal. Kyle -
Aug 28, 10:52 am 2007
Matthieu Moy
Re: EDITOR with tilde not expanded in git-commit
C does not have tilde expansion or "eval", but it has "system()": int main () { system("~/bin/scripts/moy-editor.sh foo.txt"); } works as you'd expect. -- Matthieu -
Aug 28, 8:58 am 2007
Bill Lear
Re: EDITOR with tilde not expanded in git-commit
As I said, EDITOR is set to "~/bin/xemacs -nw", that is, he did something like this: zsh, but I use bash and it failed for me as well. Bill -
Aug 28, 8:17 am 2007
Matthieu Moy
Re: EDITOR with tilde not expanded in git-commit
This one is not a good argument. If you write this: export EDITOR=~/bin/emacs the shell does the tilde expansion, and git doesn't have to worry I just checked, and at least less, svn, cvs and mutt do the tilde expansion themselves (the way you expect). To me, that is an argument: if a setup works with most unix-ish tools, it should work for git too. Now, for the good news: with the latest git, it just works! commit 08874658b450600e72bb7cb0d0747c1ec4b0bfe1 Author: David Kastrup ...
Aug 28, 8:50 am 2007
Petr Baudis
Re: EDITOR with tilde not expanded in git-commit
$ (x='a b'; $x) bash: a: command not found $ (x='~/a b'; $x) bash: ~/a: No such file or directory -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 7:58 am 2007
Petr Baudis
Re: EDITOR with tilde not expanded in git-commit
Ah, yeah, sorry. Apparently, I've already worked too much today. ;-) -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 8:27 am 2007
Bill Lear
EDITOR with tilde not expanded in git-commit
My co-worker is visually impaired, and he uses a custom emacs. His EDITOR is set to something like "~/bin/xemacs -nw". When git-commit runs, it complains: % git-commit git-commit: line 582: ~/bin/xemacs -nw: No such file or directory So, I fiddled with the following line in git-commit: ${VISUAL:-${EDITOR:-vi}} "$GIT_DIR/COMMIT_EDITMSG" and changed it to: eval ${VISUAL:-${EDITOR:-vi}} "$GIT_DIR/COMMIT_EDITMSG" and it seems to work as I would expect in this ...
Aug 28, 7:12 am 2007
Petr Baudis
Re: EDITOR with tilde not expanded in git-commit
That your point is wrong. Shell will perform word splitting after variable expansion. But it will perform variable expansion after tilde expansion, and that's the trouble. -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 8:24 am 2007
Mike Hommey
Re: EDITOR with tilde not expanded in git-commit
That's exactly what I said. It should only happen if ${VISUAL:-${EDITOR:-vi}} was quoted. And yet, look at his error message. Mike -
Aug 28, 8:25 am 2007
Mike Hommey Aug 28, 8:03 am 2007
Mike Hommey
Re: EDITOR with tilde not expanded in git-commit
I don't see how this line could trigger an error like the one you get. Your error message doesn't tell you it doesn't expand the tilde, it tells you it uses the whole string ! It is looking for a "xemacs -nw" file under $HOME/bin, which obviously doesn't exist. Now, theorically, this should not happen unless you quote the whole variable substitution thing. What is your co-worker's shell ? Mike -
Aug 28, 7:52 am 2007
Bill Lear
Re: EDITOR with tilde not expanded in git-commit
You then are apparently mistaken in your reasoning. 1) It was definitely not quoted; 2) the EDITOR setting was as I said; and 3) the error message came out exactly as I said. Bill -
Aug 28, 8:28 am 2007
Matthieu Moy
Re: EDITOR with tilde not expanded in git-commit
Yes. That's a good reason not to use system() on hardcoded values. I wouldn't write the line of code above in a real-life program. But here, the argument of system() comes from the user-configuration. If he's running on a machine whose shell does tilde expansion, he can use tilde-expansion in his configuration. On windows, I believe system() has some windows-specific things, but the user probably expects to be able to use them if he runs windows. -- Matthieu -
Aug 28, 9:11 am 2007
Bill Lear
Re: EDITOR with tilde not expanded in git-commit
Well it is certainly valid to a user to set their EDITOR in that way, both in bash and zsh, so "only to a shell" is false, not even considering that he works with this every day with plenty of other tools, and has not seen a problem with them. I do notice that cvs pukes on this, however: % cd bin % ln -s /usr/bin/vim vingo % cd ~/testo % EDITOR="~/bin/vingo -C" % cvs commit cvs commit: cannot exec ~/bin/vingo: No such file or directory Fine with me: that's why I brought it up and asked ...
Aug 28, 8:24 am 2007
Alex Riesen
Re: verifying commit IDs
git rev-list has --stdin for specifying the commits. It will fail the whole command if one of of them is invalid, though. The program can be extended, possibly -
Aug 28, 11:20 am 2007
Paul Mackerras
verifying commit IDs
Is there a fast and easy way to find out which of a set of SHA1 ids refer to commits that (still) exist in a repository? This is for use in gitk and there could be several ids, so I'd prefer to avoid a fork/exec per id. I could do a git cat-file -t $id for each id, but that's a fork/exec per id. git rev-parse doesn't check whether an id actually refers to an existing commit, so it isn't the answer. What I want to be able to do is to cache the condensed topology information that gitk uses ...
Aug 28, 4:06 am 2007
Jon Loeliger
Re: verifying commit IDs
Hmmmm.... I've occasionally wanted something similar, perhaps. When one receives a git-generated patch, it has a bunch of SHA1s in it, but those SHA1s all belong to individual files. I've wanted to find a commit, perhaps the most recent, perhaps the oldest, that still contains all of those blob SHA1s. I _think_ any such commit is then going to allow the patch to be applied without conflict, and would form "a correct" starting point for a branch with the given patch applied. Thoughts? In ...
Aug 28, 11:27 am 2007
Andreas Ericsson
Re: verifying commit IDs
Assuming you have a completely random set of ids, I think the easiest way to do it would be to extend git-cat-file to accept several ids I'm assuming you will still have to do git-rev-list to get the new commits since the last known location of a branch head. If so, git rev-list <bogus-sha1>..<rewound-branch-tip> should be enough to tell you you need to re-read that branch's entire history. I just got up though, and since I don't drink coffee, waking up is a lengthy process for me. -- ...
Aug 28, 4:21 am 2007
Junio C Hamano
Re: verifying commit IDs
Well, that is essentially "git am -3" does _without_ requiring a single commit that has those blobs in the same commit. As long as the preimage blobs are found in your repository, it will synthesize a tree that has them and applies the patch -- and then it does a three-way merge between the result and the state you originally tried to apply the patch to, using that synthesized tree as the merge base. -
Aug 28, 12:19 pm 2007
Giuseppe Bilotta
Re: git-svn tags and branches
Sorry but I fail to see the reason why you would have to move or delete the git tag if there are commits under a tags directory. I assume that your reasoning is that otherwise checking out the tag from svn and checking out the tag from git would give different results, but that's the reason for having the tags/tagname branch, not for shuffling the git tag around. -- Giuseppe "Oblomov" Bilotta -
Aug 28, 2:37 am 2007
Sam Vilain
Re: git-svn tags and branches
Right, but I think the bad practice should be propagated anyway. It will affect virtually no-one, and serves to make it the case that even if such a thing happened, then just fetching the tag gives the expected behaviour. However I'd be prepared to accept that perhaps new tags should be made, eg "tags/svntagname.r1234", to reflect the fact there are there multiple Coming up with agreed test cases is half (indeed sometimes most of) the I think it's quite important that this isn't ...
Aug 28, 8:49 pm 2007
Sam Vilain
Re: git-svn tags and branches
Well, because it's the behaviour that the repository owner is indicating. Just like in git if you have a tag you don't like, you can delete it and re-create it, I think that's what we should do. The new version of the tag would point to the new head of the tags/tagname branch. But until that re-writing of the tag happens, the branch doesn't need to exist as it introduces no new commits. Sam. -
Aug 28, 3:49 pm 2007
Giuseppe Bilotta
Re: git-svn tags and branches
[some of you may get this mail twice, sorry for the mistake] I gather from the man page that doing this is highly frowned upon, and requires manual intervention from all the poor souls that pulled in the mean time. Maybe something of the sort could be done by git-svn. When a post-tag commit is found, git-svn could warn the user and instruct it to do git-svn move-tags-forward or whatever if he wants the tags to be moved Indeed. I've been looking through the git-svn code to see if I ...
Aug 28, 4:20 pm 2007
Reece Dunn
git-p4: rebase does not work when run from a sub-directo ...
Hi, When running `git-p4 rebase` from a subdirectory of the main repository, I get: fatal: cannot locate git repository foo/.git even though the path reported as `foo` is the correct path to the main repository. This is with git 1.5.0.3, running on Windows/cygwin with a recent version of git-p4. - Reece -
Aug 28, 1:23 am 2007
Linus Torvalds
Re: git: cannot rename foo to Foo on a case-insensitive ...
You could also have done git update-index --force-delete foo git add Foo without actually ever *moving* the file, since "foo" and "Foo" are the It would be really quite hard to decide that the two filenames are just the same file in different cases. It's a deeply filesystem-specific issue. It may be "obvious" for "foo" vs "Foo", but what about all the interesting cases like German, where the "sharp s" (single letter: '
Aug 28, 3:32 pm 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
Wincent Colaiuta wrote: > El 28/8/2007, a las 13:02, Florian Weimer escribi
Aug 28, 7:07 am 2007
Reece Dunn
git: cannot rename foo to Foo on a case-insensitive file ...
Hi, Running the following: echo "hello" > foo git add foo && git commit -m "move test (1)" git mv foo Foo using a case-insensitive filesystem (this was done running git 1.5.0.3 and git 1.5.1.3 on Windows using cygwin), I get the following error: fatal: destination exists, source=foo, destination=Foo Are there any plans to support this on case-insensitive filesystems, or is it going to remain broken? Thanks, - Reece -
Aug 28, 1:17 am 2007
Linus Torvalds Aug 28, 4:01 pm 2007
Reece Dunn
Re: git: cannot rename foo to Foo on a case-insensitive ...
I meant s/sensitivity/insensitivity/ in this context. I was not suggesting dropping git's case *sensitivity* to support case insensitive filesystems. That would be an insane idea as there would NTFS supports this absurd behaviour as well. Therefore, this applies to all Windows-based platforms, which means that changing the case of I get: $ git mv -f foo Foo Warning: destination exists; will overwrite! fatal: Huh? Cache entry for Foo unknown? and: $ git status # ...
Aug 28, 5:56 am 2007
Johannes Schindelin
Re: git: cannot rename foo to Foo on a case-insensitive ...
Hi, The problem is _really_ the filesystem, as you experienced. You just cannot do an "mv foo Foo". You cannot. And that is _exactly_ the problem you experience with git, since at some point, git tries exactly that: "mv foo Foo". So it really, really, really is not a git problem. Just as I told you in my other reply. Ciao, Dscho -
Aug 28, 3:43 am 2007
Florian Weimer
Re: git: cannot rename foo to Foo on a case-insensitive ...
Except that those file systems are case-insensitive, but case-preserving. This means that "mv foo Foo" makes sense, and some tools actually support this operation (if "mv" doesn't, it's a shame). -- Florian Weimer <fweimer@bfk.de> BFK edv-consulting GmbH http://www.bfk.de/ Kriegsstra
Aug 28, 4:02 am 2007
Johannes Schindelin
Re: git: cannot rename foo to Foo on a case-insensitive ...
Hi, What did you expect? A regular "mv foo Foo" does not work either! So it is not like this is a bug in git, but in your setup. Ciao, Dscho -
Aug 28, 2:09 am 2007
Wincent Colaiuta
Re: git: cannot rename foo to Foo on a case-insensitive ...
El 28/8/2007, a las 13:02, Florian Weimer escribi
Aug 28, 6:07 am 2007
Wincent Colaiuta
Re: git: cannot rename foo to Foo on a case-insensitive ...
El 28/8/2007, a las 16:07, Andreas Ericsson escribi
Aug 28, 7:31 am 2007
Petr Baudis
Re: git: cannot rename foo to Foo on a case-insensitive ...
Well, naively speaking (I have no idea how case _in_sensitivity is actually implemented in Git, and I don't even have any sane way how to test it :), what would happen if you just rename 'foo' to 'Foo' _only_ in the index? I think that's preciselly what the OP wants and shouldn't erally break anything and should also be pretty simple to implement (the question is if documentation, cluttery and bitrot costs of this change would pay off for the feature). -- Petr "Pasky" Baudis Early to ...
Aug 28, 3:52 am 2007
David Kastrup
Re: git: cannot rename foo to Foo on a case-insensitive ...
Those two are actually known to be different. "ß" and "SS" would be harder: when words are ambiguous like "Masse" ("mass") against "Maße" ("measures"), the capitalization is actually allowed to turn "ß" into Those are different. The problem is "STRASSE" vs "straße" (identical). Things become even more fun in Turkish: "i" and "I" are _different_ letters not just because of case: the uppercase version of "i" actually is "İ", and the lowercase version of "I" is "ı". So what do you do with ...
Aug 28, 3:44 pm 2007
Reece Dunn
Re: git: cannot rename foo to Foo on a case-insensitive ...
I have tried the following: git mv foo foo.tmp git mv foo.tmp Foo which correctly reports: I haven't got any code yet, but from the analysis above, it would be a special case in the mv command when the files are the same and the case is different. However, given that the double move works as expected, I don't see this as being a big issue. - Reece -
Aug 28, 3:17 am 2007
Wincent Colaiuta
Re: git: cannot rename foo to Foo on a case-insensitive ...
El 28/8/2007, a las 22:45, Johannes Schindelin escribi
Aug 28, 7:12 pm 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
Well, mv supports what the underlying api supports. I confess myself amazed that applications need to handle this sort of thing when it should really just be a special case in the underlying library. -- Andreas Ericsson andreas.ericsson@op5.se OP5 AB www.op5.se Tel: +46 8-230225 Fax: +46 8-230231 -
Aug 28, 4:07 am 2007
Johannes Schindelin
Re: git: cannot rename foo to Foo on a case-insensitive ...
Hi, It is right that they support it. But since the _default_ is case insensitive (but only as long as it is not _reporting_ file names), it is _as bad_ as "doesn't even have a case sensitive filesystem". No sophistry helps here. Ciao, Dscho -
Aug 28, 1:45 pm 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
It's going to remain in the state it is, although I disagree that that state is broken. Adding case-sensitivity to a content tracker on a case-insensitive file system would be quite a lot of work for a very small gain. As usual, should you present some small and elegant piece of code that makes git capable of dealing with this while running with no slowdown at all on sane systems, I'm sure it'd be accepted, or at least very thoroughly discussed by the heavy names on the list. Without the ...
Aug 28, 2:39 am 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
But without case sensitivity in the tracker there's no way "mv foo Foo" Yes, because then you give the filesystem some leeway in that it doesn't have to create two files with conflicting hash entries. And that's the hoop, I suspect. Some really insane filesystems have the odd ability to report case sensitively while not actually supporting it (VFAT, I think, displays this absurd capability). Either way, the tools manipulating the file- True. What happens when you "git mv -f foo ...
Aug 28, 4:03 am 2007
Johannes Schindelin
Re: git: cannot rename foo to Foo on a case-insensitive ...
Hi, Then git status would report the file as deleted, and the original file as untracked, since those filesystems are actually only _half_ case insensitive, as Florian wrote: they _report_ the case, but they pretend that different cases refer to the _same_ file nevertheless. Ciao, Dscho -
Aug 28, 4:12 am 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
If you rename 'foo' to 'Foo' in the index, the filesystem will still say it has 'foo' in the working directory. You could ofcourse rename it in the index, delete it from the working directory and then check it out from the index under the new name, but that means there'll be a short time during which the file is deleted. That doesn't feel entirely safe to me. Better then to do something like git_rename("foo", "Foo"); if (src_and_dst_are_same) { git_rename ("foo", "foo1"); git_rename ...
Aug 28, 4:12 am 2007
David Kastrup
Re: git: cannot rename foo to Foo on a case-insensitive ...
Linux has case insensitive file systems as well: vfat, smbfs and possibly some others. If one can manage to come up with a way that deals gracefully with it (and not conditioned on the operating system), that's not just a boon on Windows. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum -
Aug 28, 2:46 pm 2007
Andreas Ericsson
Re: git: cannot rename foo to Foo on a case-insensitive ...
It needs to be dealt with either in the filesystem implementation (kernel level), or in the library providing the interface to the kernel calls. If it's done in the application, code duplication will be ridiculous, and application behaviour will be inconsistent. If it's done in the library, there'll possibly be an extra cmp+branch each time someone tries to move a file to a destination that already exists. It doesn't happen *that* often, so the extra overhead might be acceptable. The ...
Aug 28, 3:21 pm 2007
Johannes Schindelin
Re: git: cannot rename foo to Foo on a case-insensitive ...
Hi, I acknowledged that. But it does not change the _meaning_ of Andreas' criticism. They took a perfectly sane system, and turned it into a mess. Yes, you _can_ change the setting. No, most don't. Yes, the effect is... you guessed it: the same as if they did not allow case sensitivity at all. Plenty of people have this setup, and we have to suffer. Sigh. Hth, Dscho -
Aug 28, 7:23 pm 2007
Reece Dunn
git-p4: importing a changelist that moves foo to Foo del ...
Hi, If you are using git-p4 on Windows, with a Linux-based Perforce server, clone/rebase for a changelist containing: p4 integrate foo Foo p4 delete foo (i.e. move foo Foo) ends up deleting the file in question, so it is no longer contained in the git repository. This may be a core git issue (which I am going to raise as a separate issue), but I don't yet understand git-p4 enough to say for sure. - Reece -
Aug 28, 1:08 am 2007
Jeff King
Re: What's in git.git (stable)
I guess you didn't see the follow-on discussion and patch (or perhaps you didn't care). I was holding the patch for post-1.5.3. It's behaviorally equivalent, but a little nicer code. But now that his has Ditto here. His patch feels a bit hack-ish to me, and I have just posted an alternative (which is most definitely post-1.5.3). To be honest, I didn't expect you to take any patches on this in another -rc. -Peff -
Aug 28, 1:25 am 2007
Jeff King
Re: What's in git.git (stable)
OK, thanks for the explanation. I will keep hashing it out with Dscho, and see if we have something useful for post-1.5.3. -Peff -
Aug 28, 2:30 am 2007
Junio C Hamano
Re: What's in git.git (stable)
Well, post 1.5.3 may be a good time for code cleanups. I saw your patch and I think that is equivalent, just nicer and easier to read, but I had enough time to do the usual round of test for I think this is about the same low impact patch as two two fixes to log family I queued to 'next', which I am very tempted to merge to 'master' by -rc7 (one is the "git log --name-status" stuff, including your suggested improvement). Yes, merge weight code felt hackish, and more importantly, favoring ...
Aug 28, 2:24 am 2007
Junio C Hamano
What's in git.git (stable)
Will do the final rc for 1.5.3 hopefully tomorrow night or Wednesday at the latest. Honest. Promise. Unless the late last minute "fixes" break other things, that is. ---------------------------------------------------------------- * The 'master' branch has these since the last announcement in addition to the above. Brian Hetro (5): Documentation: For consistency, use CVS instead of cvs. Documentation: Correct various misspellings and typos. Make usage documentation for git-am ...
Aug 27, 11:39 pm 2007
Giuseppe Bilotta
Re: gitweb and remote branches
If I read the git_get_heads_list correctly, it uses for-each-ref on refs/heads, so -a doesn't (and wouldn't) work. So adding refs/remotes is probably a better idea. -- Giuseppe "Oblomov" Bilotta -
Aug 28, 2:51 am 2007
Giuseppe Bilotta
Re: gitweb and remote branches
Ok, this is hopefully the last time I reply to myself. I'm inlining the quick'n'dirty patch I've whipped up, hoping that gmail doesn't destroy it too much.. -- Giuseppe "Oblomov" Bilotta --- gitweb.cgi 2007-08-26 12:41:13.000000000 +0200 +++ gitweb.cgi-my 2007-08-28 13:47:15.000000000 +0200 @@ -1667,7 +1667,7 @@ sub git_get_heads_list { open my $fd, '-|', git_cmd(), 'for-each-ref', ($limit ? '--count='.($limit+1) : ()), '--sort=-committerdate', '--format=%(objectname) %(refname) ...
Aug 28, 4:53 am 2007
Giuseppe Bilotta
Re: gitweb and remote branches
I've given a better look at the code and I think I can whip up a patch to implemet the feature. I have no idea about how to create a new option in gitweb though, so I'll have to leave it that to someone else. -- Giuseppe "Oblomov" Bilotta -
Aug 28, 2:53 am 2007
Johannes Schindelin
Re: [PATCH] Change options to alphabetical order
Hi, I agree that sorting by topic is easier to read. Rarely do you look up the meaning of an option you know, but you look up an option for a meaning. And when looking for "-m" in the man page, why not use the pager's search function? Ciao, Dscho -
Aug 28, 1:56 am 2007
Junio C Hamano
Re: [PATCH] Change options to alphabetical order
If it is "rarely" or not depends on how familiar you are with the tool, and what question you are asking. I recently asked this: "I know there are two options, audio and video encoding bitrates, and vaguely recall they are not named symmetrically. Were they -ab vs -b, or -b vs -vb?". An alphabetical _index_ would have helped in such a situation, but so would typing "/-ab" or "/-b " in less. When you are looking for an option but already know the concepts and you have seen the documentation ...
Aug 28, 2:49 am 2007
Rogan Dawes
Re: Advise Requested: Branching, Merging, and Deployment
It sounds like you could use the following strategy: Have a primary Development branch. When a developer needs to add a feature, he forks a "topic branch" from Development, and implements the feature. When the feature is complete and tested, the topic branch is merged back into Development. Since forking and merging is one of git's strengths, it should be quite possible to have multiple "topic branches" in progress at any one time, obviously modulo interdependencies. Once the ...
Aug 28, 12:58 am 2007
Johannes Schindelin
Re: Non-GNU CC compiler support
Hi, IIRC Sun's CC was tested successfully. AFAIK any ANSI-C compiler should do. Ciao, Dscho -
Aug 28, 1:36 am 2007
Shawn O. Pearce
Re: git-import.sh using git-fast-import
Yeah, that makes a lot of sense. If there were a lot of files git-add would have taken a lot of time in prior versions, before that O(n^2) bug was fixed. Thanks for retesting. -- Shawn. -
Aug 27, 9:22 pm 2007
Jeff King
Re: git-import.sh using git-fast-import
It's a bit faster, but you still get killed on passing all of the data through userspace and a pipe, rather than just having git-add hash it directly. Some timings importing git.git's contents: git-import-core real 0m0.839s user 0m0.504s sys 0m0.304s git-import-shell real 0m4.947s user 0m2.604s sys 0m2.912s git-import-perl real 0m1.400s user 0m1.144s sys 0m0.180s where 'git-import-core' is this: #!/bin/sh git-init git-add . ...
Aug 27, 10:54 pm 2007
Shawn O. Pearce
Re: git-import.sh using git-fast-import
fast-import will also accept the shorter (perhaps more common) form: This might be more clear as: print $fi "data $len\n"; -- Shawn. -
Aug 27, 11:21 pm 2007
Jeff King
Re: git-import.sh using git-fast-import
Yes, see the other part of the thread. But it's not fair to just repack the non-fast-import version, since the packs fast-import generates are Can I bless it with your Signed-off-by? -Peff -
Aug 27, 11:43 pm 2007
Shawn O. Pearce
Re: git-import.sh using git-fast-import
I'm not sure this really warrants C. Just a language that is able to do lots of file IO, avoids forks to do it, and is also simple enough that most readers could follow it. Your shell script fits all byt the "avoids forks" part. Anyone who seriously needs the Uhhh. That's not very good. How many files? What was their average size? What was the size of the largest file? Binary? Text? We should be able to handle this. The fact that it killed your system means we should ...
Aug 27, 9:20 pm 2007
Nguyen Thai Ngoc Duy
Re: git-import.sh using git-fast-import
I imported a ~1gb directory (including all subdirectories). I don't remember git-add or git-commit that died. It ate all my memory, froze -- Duy -
Aug 27, 9:04 pm 2007
Shawn O. Pearce
Re: git-import.sh using git-fast-import
It may also have to do with the large amount of data going over a pipe, as well as the fact that we have to write the data into the packfile then go back and reread all of it to compute the SHA-1 of the entire thing. That's a lot of IO, all going through your poor Yea, so like the parallel pack-objects experiment that Nico had done recently we decreased wall-clock time at the expense of using a larger amount of the system resources. That is bad as we use more CPU time than we saved in ...
Aug 28, 8:47 pm 2007
Jeff King
Re: git-import.sh using git-fast-import
That is much more readable, and considering that this is meant to be an Oops, yes; that was left from a previous iteration. I will incorporate both and re-send after 1.5.3; thanks for your comments. -Peff -
Aug 27, 11:36 pm 2007
Shawn O. Pearce
Re: git-import.sh using git-fast-import
Right. Now that fast-import has a 'progress' command in its stream language it may be possible to let it read from raw files in the UNIX filesystem. I almost implemented this a while ago but realized it wasn't very useful because the frontend couldn't tell when fast-import was done reading from the file. With 'progress' That doesn't surprise me. It would be very hard to beat `git-add .`. Where fast-import usually wins is avoiding many fork+exec if you are doing many individual commits. ...
Aug 27, 11:11 pm 2007
Nguyen Thai Ngoc Duy
Re: git-import.sh using git-fast-import
Should the script contain git-repack -d as well? git-fast-import does Please do. I'm a lazy guy :-) -- Duy -
Aug 27, 11:26 pm 2007
Nguyen Thai Ngoc Duy
Re: git-import.sh using git-fast-import
Tested again. Core git runs fine. It must have been O(n^2) bug that has been fixed in -rc3. So the script is educational only. -- Duy -
Aug 27, 9:14 pm 2007
Jeff King
Re: git-import.sh using git-fast-import
Just for giggles, here's the timing of the "core" and "perl" versions, both with a "git repack -a -d -f" afterwards. core: real 0m3.353s user 0m2.108s sys 0m0.580s perl: real 0m3.138s user 0m2.704s sys 0m0.236s So the perl version actually wins here, though with two caveats: - the core version spends more sys time. Presumably this is because it actually gives you a working index, whereas the fast-import version does not. - the perl version actually ...
Aug 27, 11:33 pm 2007
David Kastrup
Re: git-svn tags and branches
"remain"? Things don't need to stay the same. Most (but not necessarily all) Subversion tags presumably start out as "tags", top level trunk copies, and then "just a final fix" gets in at some point of time. Of course, one can also "tag" off branches, or of subdirectories or whatever in Subversion. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum -
Aug 27, 10:49 pm 2007
Giuseppe Bilotta
Re: git-svn tags and branches
Although this is a good argument *for* branches, it's not a good argument *against* tags. The svn tag would be converted to a git annotated tag at 'first commit' time, and if there are subsequent commits to the svn tag directory (as opposed to the usually corresponding branch directory) "tags/tagname" branch would be created in git. -- Giuseppe "Oblomov" Bilotta -
Aug 28, 2:09 am 2007
Shawn O. Pearce
Re: Git User's Survey 2007 partial summary
On both Mac OS X and Windows (Cygwin and MSYS) Tcl/Tk has a native look and feel. I don't have git-gui looking completely like a native Mac OS X application, but it is close enough that its fine for its current state of development. On Windows it fits in alongside the rest of the c**p^H^H^H^Hawesome programs on that platform. git-gui only looks horrible on UNIX X11, where Tk has just not gotten the level of UI improvement that it has on Mac OS X and Windows. I'm waiting for Tk 8.5 where the ...
Aug 27, 9:31 pm 2007
Johannes Schindelin
Re: Git User's Survey 2007 partial summary
Hi, FWIW I think that they just get it from http://tcltkaqua.sourceforge.net/ Ciao, Dscho -
Aug 28, 2:03 am 2007
Matthieu Moy
Re: [RFC][PATCH] remarks about custom diff driver
Ahh. That is the thing I was looking for. side-note: strbuf.h should also be used in populate_from_stdin (which is currently O(n^2) because of a linear increment + xrealloc), and I guess run-command.h can be used in spawn_prog regardless of my patch, isn't it? Thanks for your help, -- Matthieu -
Aug 28, 2:45 am 2007
Johannes Schindelin
Re: [RFC][PATCH] remarks about custom diff driver
Hi, Some comments: this patch would merit a cleanup patch first, which _only_ renames all the _diff_ stuff to _cmd_. That would make the actual patch very much easier to read, too. Also, you probably want to use the run-command.h "API" instead of rolling it on your own, with strbuf.h to collect the converted text. Otherwise you would duplicate code, and make porting to Windows harder than necessary. Ciao, Dscho -
Aug 28, 2:27 am 2007
Mike Hommey
[PATCH] Document range looking syntax of git-diff arguments
git-diff accepts range looking syntax that was not yet documented, and that is the very opposite of what is described in git-rev-parse. Signed-off-by: Mike Hommey <mh@glandium.org> --- Documentation/git-diff.txt | 32 ++++++++++++++++++++++++++++++-- 1 files changed, 30 insertions(+), 2 deletions(-) diff --git a/Documentation/git-diff.txt b/Documentation/git-diff.txt index b36e705..dcb103e 100644 --- a/Documentation/git-diff.txt +++ b/Documentation/git-diff.txt @@ -43,9 +43,22 @@ tree ...
Aug 27, 10:50 pm 2007
Linus Torvalds
Re: [PATCH] Document range looking syntax of git-diff ar ...
If you document the ... thing, you should also fix the comment that comes afterwards. The "commit...commit" syntax can *not* take a tree-ish, since it requires This might be worth specifying even more clearly somewhere, and explaining *why*. "git diff" really is special, because it deals entirely in end-points. Almost all of the rest of git is about *sets* of commits, rather than just two end-points. Linus -
Aug 28, 3:18 pm 2007
Junio C Hamano
Re: Confusion about diffing branches
Heh, deep magic ;-). Essentially, the traditional "single commit" behaviour is implemented as a special case that - has one and only one positive ref specified on the command line; - without -$count (or -n $count). Everything else uses the usual revision range parsing machinery, including the case you specify the same ref twice redundantly on the command line in duplicates. Even that counts as "not just one positive ref on the command line" and triggers the usual revision range ...
Aug 28, 12:34 am 2007
Junio C Hamano
Re: [PATCH] Document range looking syntax of git-diff ar ...
With respect to this point, I think what we already have as of last night is much better than the above. -
Aug 28, 4:18 pm 2007
Theodore Tso
Re: Confusion about diffing branches
Maybe the last sentence should be omitted? The fact that sometimes you need to specify --root is pretty well hidden as a plumbing-level option up until now, so what --root does is largely an impleementation detail that the average user doesn't need to know and would probably confuse him/her deeply anyway. (i.e., it's needed by git-diff-tree, but it's not needed by git-diff.) BTW, I'm probably missing some history here, but why isn't --root/rev->show_root_diff=1 the default? Why do we ...
Aug 28, 4:49 am 2007
Catalin Marinas
Re: [PATCH 1/2] gitweb: Lift any characters restriction ...
It should do this with the --auto option (though I haven't checked it recently). -- Catalin -
Aug 28, 5:59 am 2007
Andy Parkins
Re: repo.or.cz wishes?
I'm not so sure that what you do with a connection is a relevant part of a URL. What about this: $ ssh somehost mycommand If I wrote that as a URL should it be mycommand+ssh://somehost/ ? Obviously not. The protocol part tells you how to talk, not what you should be done with it. The very fact that the first thing git does is run git-daemon (or whatever) demonstrates that you are talking "ssh" protocol _not_ "git+ssh" protocol. Andy -- Dr Andy Parkins, M Eng ...
Aug 28, 5:26 am 2007
Petr Baudis
Re: repo.or.cz wishes?
That is possible as well, but I like the method I've proposed better since if there are any objects that _really_ aren't referenced anymore, The overhead for fetching over HTTP might be insane. -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 4:48 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, It _is_ hard, if you want to keep any kind of safe permissions. Think Nope: for b in $(git ls-remote /that/other/repo | sed "s/^[^ ]* //") do git push /that/other/repo :$b done Ciao, Dscho -
Aug 28, 4:32 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, Ah, I was reminded again about a pretty obscure bug with http transport: http-fetch uses all alternates and http-alternates it finds. However, the alternates are wrong, since they are for the ssh:// protocol. So here comes my wish: could you install http-alternates for all forks (and preferably include the http-alternates of a forked project, so that a fork of a fork works)? Thank you very, very much, Dscho -
Aug 28, 2:20 am 2007
Sven Verdoolaege
Re: repo.or.cz wishes?
What would be the use of that (outside of gitweb) ? skimo -
Aug 28, 1:49 am 2007
David Symonds
Re: repo.or.cz wishes?
Well, my original point, which I carefully disguised with my misunderstanding of git:// URLs, was that the URL should be enough to locate the resource (say, a git repo); you shouldn't restrict what those resources are used for, so that the URLs *can* be for more than just git, because they are Uniform, and they only *locate* a resource, Sorry, I meant something like wget. Those keys are close together, heh. Dave. -
Aug 27, 11:06 pm 2007
Jeff King
Re: repo.or.cz wishes?
It isn't fetch-only since 4b3b1e1e488fe83a8a889ff26cf88355692b6a8c (though you have to enable it with a config option). -Peff -
Aug 28, 1:30 am 2007
Petr Baudis
Re: repo.or.cz wishes?
Hi, yes, I already did this the last week. -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 2:24 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, Sorry for not mentioning it, but IMHO it does not really matter for this discussion, or does it? Ciao, Dscho -
Aug 28, 2:17 am 2007
Shawn O. Pearce
Re: repo.or.cz wishes?
Its not isolated to repo.or.cz. Its what happens when you use `git clone --shared A B` and the repository A that you borrow from removes objects that B depends upon. That is exactly what repo.or.cz is doing, and it is exactly what I'm doing at day-job with some large repositories. You more or less cannot repack A without making sure it takes B's refs into account when it generates the new packfile. But that's actually a problem because A doesn't have B's ODB, and some objects that are ...
Aug 27, 9:10 pm 2007
Jeff King
Re: repo.or.cz wishes?
Sorry, I have not been keeping up with this thread, so I may be confused. But I thought you were saying that there is no point to git-daemon over TLS, since git-daemon is purely for fetching public data. My point is that it's not, and thus there might be some value to it (though really, I would have no interest in implementing it -- its functionality would be a duplicate of git over ssh, which works fine). -Peff -
Aug 28, 2:28 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, Hmm. I think you'll have to hack pack-objects, or you'll have to create dummy refs from the dangling objects/blobs. The latter is probably easier, since it just involves a "git fsck --lost-found" and putting the found things into a "refs/I-dont-wanna-lose-you/" refspace. But it will be certainly more expensive. The upside of this method would be that you have an integrity test for free. Putting all objects into a single database could easily break the current packfile ...
Aug 28, 4:06 am 2007
Petr Baudis
Re: repo.or.cz wishes?
Hi, I actually *don't* want any objects to go ever away from a project. I just have no idea how to prevent it but still have some sane packing behaviour. I've been already thinking about this few years ago and even ended up with some patches in progress, but never finished them... (What I've found in my IRC logs:) 22:03 < pasky> I do run git repack -a -d but as far as I understand, that should be fine 22:03 < gitster> Huh? "repack -a -d" within git.git? 22:04 < gitster> What ...
Aug 28, 3:19 am 2007
Linus Torvalds
Re: repo.or.cz wishes?
There's possibly another reason: using TLS for validating not the *client* or encrypting the data, but in order to be able to trust the *server* in the face of man-in-the-middle attacks etc. A lot of people think if authentication as a way to verify the identity of the client. But it's equally valid as a way to verifyt that the server you talk to is the one you _expected_ to talk to. [ That said, I'd also actually like to support encrypted git repositories, at least on a ...
Aug 28, 3:45 pm 2007
Jing Xue
Re: repo.or.cz wishes?
There is still the question though - "located by _whom_?" IMHO, the answer to that question determines the _different contexts_ for these URLs. When I'm specifying a URL on a git command line (e.g. "git clone /url/to/some/repo"), it does seem redundant to say the least to have to always prefix the underlying protocol with "git+". (I think Linus had a good point here, in that if we were to say "git clone git+ssh://...", we should also say "git clone git+rsync://..." etc. for ...
Aug 28, 7:31 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, But maybe on repo.or.cz we can do something about it? Like using a global object database, or actually teaching git about _splitting_ object databases into parts: something along the lines of "we repack the forked projects before the forkees. That way, the objects will be still there when the forkee "lost" them, but will be repacked into the forked project's database". Ciao, Dscho -
Aug 28, 1:25 am 2007
Theodore Tso
Re: repo.or.cz wishes?
This has been discussed before, and it wouldn't be *that* hard to have "git clone --shared" create a backpointer from B to A, so that "git-prune" could also search the B's refs and not prune anything that Why don't you even allow people to push into A? That should be This is morally the same, but it makes the hardlink step easier (only one pack to link from A to B), and by using git-gc mit makes it conceptually easier for people to understand what's going on. git --git-dir=A gc ln ...
Aug 28, 4:19 am 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, I really have to wonder what the benefits are. git:// does not need authentification, it is fetch-only, and you can (and should!) verify the integrity with git-fsck anyway. So all TLS would add to is waste bandwidth and CPU cycles. Ciao, Dscho -
Aug 28, 1:27 am 2007
David Kastrup
Re: repo.or.cz wishes?
Huh? Do you think a URL "http:" ceases to be a URL if there is It doesn't to me. Not least of all because rsync does not work using URLs to start with. Can all of the U-is-Universal-flouting people read the manual pages of the utilities they are advertising? It would make the discussion less surreal. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum -
Aug 27, 10:44 pm 2007
Johannes Schindelin
Re: repo.or.cz wishes?
Hi, Thank you for responding _that_ quickly :-) Ciao, Dscho -
Aug 28, 2:52 am 2007
Jakub Narebski
Re: repo.or.cz wishes?
For the hypothetical (planned?) future '--recurse-submodules' option to git-diff family, git-ls-tree and git-ls-files, git-fetch and git-push (but I think not git-pull), perhaps git-log (besides what it supports by the way of git-diff-tree), maybe even git-status and git-commit. Gitweb support is a special case of git-ls-tree support, of sorts. BTW I think this would need complementing "lightweight checkout" support, i.e. core.gitdir (overrideable by GIT_DIR and --git-dir) and ...
Aug 28, 2:56 pm 2007
Petr Baudis
Re: [PATCH] [RED] git-init: Cannot setup bare repository
Thanks, latest next works fine for me and cg-admin-setuprepo! -- Petr "Pasky" Baudis Early to rise and early to bed makes a male healthy and wealthy and dead. -- James Thurber -
Aug 28, 8:49 am 2007
Johannes Schindelin
Re: .gitignore, .gitattributes, .gitmodules, .gitpreciou ...
Hi, Hehe, I was a little confused by your answer... I guess I did not respond Happily, file properties as well hidden as these have _no_ _place_ in source code that needs to be tracked. Ciao, Dscho -
Aug 28, 1:45 am 2007
Johannes Schindelin
Re: .gitignore, .gitattributes, .gitmodules, .gitpreciou ...
Hi, To the contrary. People having those insane setups seem to be unable to admit it. And I'm sure you saw some on this very list, like me. They never shut up, they only get louder. Ciao, Dscho -
Aug 28, 4:07 pm 2007
Sam Vilain
Re: .gitignore, .gitattributes, .gitmodules, .gitpreciou ...
But you're restricting your statements to tidy, sane code bases. Are there any particular reasons that git shouldn't be able to track insane code bases, with attributes etc? It sure would shut up a whole load of people. Sam. -
Aug 28, 3:43 pm 2007
Johannes Schindelin
Re: .gitignore, .gitattributes, .gitmodules, .gitpreciou ...
Hi, I do not see these cases. You can have these cases, basically: - .gitattributes in worktree (then it does not matter what else we have), - .gitattributes not in the worktree, but in the index (then that is taken) In the latter case, there could be conflicts _in_ .gitattributes, in which case those .gitattributes are ignored. It would be 2x3, not 3x3. Ciao, Dscho -
Aug 28, 1:49 am 2007
Petr Baudis
Re: [PATCH 1/2] Add "--only-untracked" flag to status co ...
On Sat, Aug 25, 2007 at 08:10:05AM CEST, Junio C Hamano wrote: > V
Aug 28, 3:43 am 2007
Matthieu Moy
Re: [PATCH 1/2] Add "--only-untracked" flag to status co ...
I use it, but for a very particular use-case: I use git-svn to track projects for which no one else uses git, so I just don't bother svn users with in-tree ignore list. -- Matthieu -
Aug 28, 4:13 am 2007
Andreas Ericsson Aug 28, 3:50 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
On Tue, Aug 28, 2007 at 10:54:43AM +0200, Uwe Kleine-K
Aug 28, 2:00 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
Yes, I am beginning to think this is getting very complex for a problem that really hasn't proven itself to be worth considering. Sure, I suppose name-rev is a little bit of a memory hog, but running Uwe's tests only consumed about 17M even on my static implementation. That really isn't enough to worry about. I still prefer my implementation to the MERGE_TRAVERSAL_WEIGHT, but that is perhaps a matter of preference. With mine, you could plug in comparators to tweak the names (e.g., number of ...
Aug 28, 4:34 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
Hrm. I was puzzled at first by what you meant, and then I thought about some more, and came up with this. Which is perhaps what you intended all along, or maybe not. We are going to store the same prefixes over and over again. For example, when storing v2.6.22-rc1~1038^2~20^2~5, we can consider the sequence (1/1038, 2/20, 2/5). There are likely to be many nearby commits sharing 1/1038, and a few sharing 2/20. We can't make a linked list in the forward direction, since the '1/1038' will go ...
Aug 28, 3:26 am 2007
Uwe
Re: [PATCH] name-rev: Fix non-shortest description
Hello Johannes, That's what I meant. I only want to make a statement like: If you want feature xy, you need to update to at least v2.6.22-rc1. I didn't think deeply about it, but there was a similar discussion for git describe which implied counting refs on all paths leading to a given tag. It might be different here, as we look in the other direction. Best regards Uwe -- Uwe Kleine-K
Aug 28, 1:54 am 2007
Uwe
Re: [PATCH] name-rev: Fix non-shortest description
Hello Jeff, Jeff King wrote: > On Tue, Aug 28, 2007 at 10:54:43AM +0200, Uwe Kleine-K
Aug 28, 2:17 am 2007
Johannes Schindelin
Re: [PATCH] name-rev: Fix non-shortest description
Hi, The problem is: what is oldest? We cannot rely on the timestamps. And doing the naive thing -- counting edges in the commit graph (in effect using a weighting of 1) -- ends up in ugly names such as tags/v2.6.22-rc1~1^2^2^2~11^2~13^2~8^2~1^3~5 Besides, you successfully hid from yours truly what your hypothetic flag should accomplish. Ciao, Dscho -
Aug 28, 1:39 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
Yes, I considered making it dynamic, which would probably end up saving quite a bit of memory (since most commits use many fewer than 32) I think 32 is a reasonable limit in general, since at some point, do you Let's say we allocate dynamically. The average per-commit number of stored merge traversals for linux-2.6 is 1.79. Each traversal is 5 bytes (though I think we could easily drop it to 3 or 4 -- do we expect generation counters larger 1.7 million?), for an average of 10 bytes stored per ...
Aug 28, 2:25 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
On Tue, Aug 28, 2007 at 11:17:19AM +0200, Uwe Kleine-K
Aug 28, 2:26 am 2007
Johannes Schindelin
Re: [PATCH] name-rev: Fix non-shortest description
Hi, Good point; I forgot about that strdup. But then, we could spare even more space when not using an array, but a linked list for the generation numbers... It is a small performance impact, but in reality it will not matter, methinks. Ciao, Dscho -
Aug 28, 3:03 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
Can't that number get stale if the pointed-to rev_name improves? That is, if I have named a rev "foo~20^2~5", and another rev points at it with "^2~30", then in the second rev we know that the number of merge traversals is 2. But what if foo~20^2~5 is actually "bar", and when we process the "bar" ref, our merge traversal number _should_ shrink to 1. But it won't, since when we're processing the pointed-to rev, we don't know which commits point to it. I have a feeling we would eventually hit ...
Aug 28, 4:11 am 2007
Johannes Schindelin
Re: [PATCH] name-rev: Fix non-shortest description
Hi, Okay, I could have been clearer: make rev_name a linked list, where only the first contains the actual root of the name (i.e. "v2.6.22-rc1"). This can be made const char *, so that it is not allocated. Then, like you described, you can have instances of rev_name, pointing to other instances of rev_name instead of a root. And to speed up comparison (and to know whether to point to a rev_name or a const char *) you can store the number of merge traversals: struct rev_name ...
Aug 28, 4:02 am 2007
Jeff King
Re: [PATCH] name-rev: Fix non-shortest description
That's a clever trick, and I think it should work in most cases as long as there are fewer than 65535 generations (though I haven't really thought hard about it). Here's my alternate approach which builds a stack of merge traversals, and let's you compare two stacks (it uses the same criteria as the original, but now we have the other generational information accessible for comparison). It comes up with the answer Uwe expects for his problem commit, and I think in general is the "right" ...
Aug 28, 1:20 am 2007
Johannes Schindelin
Re: [PATCH] name-rev: Fix non-shortest description
Hi, This is exactly what I tried to avoid, and why I did _not_ do the "correct" fix. In some real-life (i.e. non-OpenSource) repositories you do get a mess, and you do get quite a lot of messy merges. So I am not at all convinced that this holds together in such setups. Besides, name-rev is already a memory hog. Your patch makes it worse. IOW I think that my patch is a good trade off between correct and working. Ciao, Dscho -
Aug 28, 2:15 am 2007
Johannes Schindelin
Re: [PATCH] name-rev: Fix non-shortest description
Hi, Well, we could actually do the correct thing, and not have a fifo, but a Fibonacci heap, so that we traverse the commits by cost. Then there Most comparisons (I guess) would be relatively cheap, since the traversals alone would suffice, and most of the others would be relatively short. But I really wonder now if it is not just easier to increase MERGE_TRAVERSAL_WEIGHT to (1<<24) and be done with it once and (probably) for all. Ciao, Dscho -
Aug 28, 4:28 am 2007
Paolo Ciarrocchi
Re: Git User's Survey 2007
Hi Jakub, sorry for being so late but I had some problems to be fixed in my real life. I forwarded the invite to the survey to my LUG and to an important Italian web site dedicated to OS. I hope they will publish the article. Regards, -- Paolo http://paolo.ciarrocchi.googlepages.com/ -
Aug 28, 12:52 am 2007
Johannes Schindelin
Re: [PATCH/RFH] Fix initialization of a bare repository
Hi, Let's hope that your suspicion holds better than my worktree/gitdir suspicion... In any case, ACK on your patch. Ciao, Dscho -
Aug 28, 2:08 am 2007
Junio C Hamano
Re: [PATCH/RFH] Fix initialization of a bare repository
Looks good. On top of these two... An earlier commit 6acbcb92 unfortunately defined --bare as a synonym to "export GIT_DIR=`pwd`", but I have to say that this was done without much thinking. To be more precise and fair to the commit, it did so without thinking outside the case it wanted to deal with. It wanted to deal with the case where the user did _not_ have GIT_DIR exported, and did: $ cd some-bare-repository $ git --bare repack -a -d In this case, its exporting cwd as ...
Aug 27, 10:53 pm 2007
Jakub Narebski
Re: [BUG] gitweb on repo.or.cz shows buggy commitdiff
There is no 'B' status in raw tree output. Broken filepairs can be left as pair of addition 'A' and deletion 'D', or merged into modification with dissimilarity score, e.g. 'M064'. See Documentation/diffcore.txt: the latest implementation always merges all the broken pairs back into modifications, but the resulting patch output is formatted differently for easier review in case of such a complete rewrite by showing the entire contents of old version prefixed with '-', followed by ...
Aug 28, 6:38 am 2007
Jakub Narebski
[PATCH] gitweb: Fix and simplify "split patch" detection
There are some cases when one line from "raw" git-diff output (raw format) corresponds to more than one patch in the patchset git-diff output; we call this situation "split patch". Current code misdetected subsequent patches (for different files) with the same pre-image and post-image as fragments of "split patch", leading to mislabeled from-file/to-file diff header etc. We could parse from_file and to_file from the "git diff header" in the patch, i.e. from the "^diff" line in patchset, and ...
Aug 28, 5:08 pm 2007
previous daytodaynext day
August 27, 2007August 28, 2007August 27, 2007