git mailing list

FromSubjectsort iconDate
Jakub Narebski
StGIT 0.13 recognizes but not list packed StGIT controlled b...
I use Stacked GIT 0.13 with git 1.5.3.5 (and Python 2.4.3). StGIT does recognize old StGIT branches (and converts them), but "stg branch -l" list only one branch. I guess that is cause by the fact that all the rest of branches are packed. So the question is: how to unpack branches, and how to prevent branches from being packed by "git-gc"? Another StGIT question: how to check if given branch is controlled by StGIT (needed for my bash prompt)? -- Jakub Narebski Poland -
Nov 18, 7:05 pm 2007
Ping Yin
[PATCH] Fix start_command closing cmd->out/in regardless ...
When 'FILE *fp' is assigned to child_process.out and then start_command or run_command is run, the standard output of the child process is expected to be outputed to fp. However, sometimes fp is not expected to be closed since further IO may be still performmed on fp. --- run-command.c | 4 ---- 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/run-command.c b/run-command.c index 476d00c..4e5f58d 100644 --- a/run-command.c +++ b/run-command.c @@ -115,13 +115,9 @@ int start_comma...
Nov 18, 1:36 pm 2007
Junio C Hamano
Re: [PATCH] Fix start_command closing cmd->out/in regardl...
Could you clarify "However, sometimes" with a concrete codepath that has this problem in the proposed commit log message, and Sign-off your patch please? -
Nov 18, 2:52 pm 2007
Ping Yin
[PATCH] builtin-commit: Fix git-commit honoring status.color
status.color shouldn't be honored when committing since the run-status output is fed to the editor. --- builtin-commit.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/builtin-commit.c b/builtin-commit.c index 8db74ed..4396e7d 100644 --- a/builtin-commit.c +++ b/builtin-commit.c @@ -45,6 +45,7 @@ static int quiet, verbose, untracked_files, no_verify; static int no_edit, initial_commit, in_merge; const char *only_include_assumed; struct strbuf message; +extern int...
Nov 18, 1:10 pm 2007
Junio C Hamano
Re: [PATCH] builtin-commit: Fix git-commit honoring status.c...
Although I admit I do not care much about the "status color", I suspect this patch is not quite right. When prepare_log_message() returns "no committable changes" and we are not in merge, the calling cmd_commit() does another run_status() to show the status of the index and the work tree to the stdout, and at that point, we _do_ want to honor the configuration setting you are discarding with this assignment. --- builtin-commit.c | 5 ++++- wt-status.h | 1 + 2 files changed, 5 ...
Nov 18, 3:55 pm 2007
Junio C Hamano
[PATCH] builtin-commit: run commit-msg hook with correct mes...
It should run with $GIT_DIR/COMMIT_EDITMSG, not just COMMIT_EDITMSG. Signed-off-by: Junio C Hamano <gitster@pobox.com> --- * Other things I noticed that are still broken: - "git commit -v" does not give you the diff in the message template for your final review; - message_is_empty() is bogus. It does run stripspace() but does not strip out the diff "git commit -v" would produce before doing its comparison; builtin-commit.c | 2 +- 1 files changed, 1 inser...
Nov 18, 4:30 pm 2007
Christian Couder
[PATCH] Bisect: use "$GIT_DIR/BISECT_NAMES" to check if we a...
Previously we tested if the "$GIT_DIR/refs/bisect" directory existed, to check if we were bisecting. Now with packed refs, it is simpler to check if the file "$GIT_DIR/BISECT_NAMES" exists, as it is already created when starting bisection and removed when reseting bisection. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> --- git-bisect.sh | 7 ++----- 1 files changed, 2 insertions(+), 5 deletions(-) diff --git a/git-bisect.sh b/git-bisect.sh index 4748c6a..01593eb 100755...
Nov 18, 11:34 am 2007
Jon Smirl
! [rejected] master -> master (non-fast forward)
What's causing this? I'm using stgit on the master branch. I'm fixing it each time on the remote server by deleting the ref to master. jonsmirl@terra:~/ds$ git push digispeaker To ssh://jonsmirl1@git.digispeaker.com/~/projects/digispeaker-kernel.git ! [rejected] master -> master (non-fast forward) error: failed to push to 'ssh://jonsmirl1@git.digispeaker.com/~/projects/digispeaker-kernel.git' jonsmirl@terra:~/ds$ On the server I have: [core] repositoryformatversion = 0 ...
Nov 18, 11:12 am 2007
Junio C Hamano
Re: ! [rejected] master -> master (non-fast forward)
A "non-fast forward" means that you had this history earlier: o---o---A / ---o pushed "A" to the remote's 'master', then built this history: o---o---A / ---o---o---o---o---A' by rewinding and rebuilding, and the tip of the branch now points at A', which you tried to push to the remote. Which often causes troubles for people who are fetching from the branch you are pushing into, and forbidden by default as a safety measure. As long as the p...
Nov 18, 2:10 pm 2007
Jon Smirl
Re: ! [rejected] master -> master (non-fast forward)
stgit must be doing this when I rebase. It pops all of it's patches, moves to head of linus/master and then rebases them. What is the right way to share repositories using stgit? I have a set of patches which I am working on for kernel inclusion. I have them applied as a stgit stack on top of linus/master. I need to share this patch stack with other developers. These developers may want to change one of my patches. Right now they are emailing me deltas and I apply them to the appropriate stgit ...
Nov 18, 2:42 pm 2007
Alex Riesen
Re: ! [rejected] master -> master (non-fast forward)
the branch you are pushing does not fast-forward to the one on digispeaker. IOW, the master on digispeaker has changed since you made changes on your local master. -
Nov 18, 2:29 pm 2007
Henrik Vendelbo
only accessing some git repos: Am I configuring daemon wrong?
I run the daemon against a base directory with all my repos. /repositories + /blingon + /config + /thepia + /config The config directories are git repositories, and the repos are made available with the following command: henrik-computer:~ x$ git daemon --export-all --verbose --base-path=/repositories [337] Connection from 192.168.9.130:56583 [337] Extended attributes (20 bytes) exist <host=192.168.9.165> [337] Request upload-pack for '/blingon/all' [337] Disconnected ...
Nov 18, 9:18 am 2007
Junio C Hamano
Re: only accessing some git repos: Am I configuring daemon w...
Lack of any whitelist on the command line and --export-all? Do you see "not in whitelist" in your error log? -
Nov 18, 2:48 pm 2007
Johannes Sixt
[RFC] Alternates and broken repos: A pack and prune scheme t...
As you know, repo.or.cz uses alternates in order to reduce the space that the repositories of forked projects require. Recently, it happened that a fork (4msysgit.git) became broken because it was using an object that was pruned away from the repository that it was borrowing from (mingw.git). This happened even though 4msysgit did not use the branch of mingw.git that was rebased and whose objects were pruned. The reason is that a merge in 4msysgit.git resulted in a blob that was also in the r...
Nov 18, 7:25 am 2007
Junio C Hamano
Re: [RFC] Alternates and broken repos: A pack and prune sche...
I would imagine that would work as long as it can be controlled when all the involved repositories are repacked and pruned, such as on repo.or.cz case (but on the other hand it is not really controlled well there and that is the reason you wrote the message X-<). -
Nov 18, 2:39 pm 2007
Johannes Sixt
Re: [RFC] Alternates and broken repos: A pack and prune sche...
Well, I think in many situations pack and prune can be controlled. To be precise, if alternates are used pack and prune *must* be controlled. Currently, the control is very simple: "don't prune" (and I don't recall ATM what you must not do when you repack). Anyway, judging from the responses so far it seems that people can live with "don't prune" (or not using alternates) ;-) Repositories getting broken this way isn't exactly my itch, either, so... I spelled out a possible solution if someo...
Nov 18, 4:01 pm 2007
Junio C Hamano
Re: [RFC] Alternates and broken repos: A pack and prune sche...
Because my point was not "don't prune is good enough", I think you are judging from too small number of responses (in fact, zero). My point was that even the existing setup that is well known to the public (i.e. repo.or.cz) does not seem to be controlled, and adding a nicer mechanism (e.g. I do not think there currently is a canned way to prepare a pack that contains only unreachable objects --- you need to script it anew) for a better control may not help the situation much, unless it is actual...
Nov 18, 4:10 pm 2007
Junio C Hamano
[PATCH] file_exists(): dangling symlinks do exist
This function is used to see if a path given by the user does exist on the filesystem. A symbolic link that does not point anywhere does exist but running stat() on it would yield an error, and it incorrectly said it does not exist. Signed-off-by: Junio C Hamano <gitster@pobox.com> --- dir.c | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/dir.c b/dir.c index 01790ab..87e5dec 100644 --- a/dir.c +++ b/dir.c @@ -688,11 +688,10 @@ int read_directory(struct d...
Nov 18, 6:21 am 2007
Junio C Hamano
[PATCH] Export three helper functions from ls-files
This exports three helper functions from ls-files. * pathspec_match() checks if a given path matches a set of pathspecs and optionally records which pathspec was used. This function used to be called "match()" but renamed to be a bit less vague. * report_path_error() takes a set of pathspecs and the record pathspec_match() above leaves, and gives error message. This was split out of the main function of ls-files. * overlay_tree_on_cache() takes a tree-ish (typically "HEAD") ...
Nov 18, 6:21 am 2007
Junio C Hamano
[PATCH] Fix add_files_to_cache() to take pathspec, not user ...
This separates the logic to limit the extent of change to the index by where you are (controlled by "prefix") and what you specify from the command line (controlled by "pathspec"). Signed-off-by: Junio C Hamano <gitster@pobox.com> --- builtin-add.c | 8 +++++--- cache.h | 4 +++- commit.h | 1 - 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/builtin-add.c b/builtin-add.c index 45b14e8..16f8557 100644 --- a/builtin-add.c +++ b/builtin-add.c @@ -111,1...
Nov 18, 6:21 am 2007
Junio C Hamano
[PATCH] builtin-commit: fix partial-commit support
When making a partial-commit, we need to prepare two index files, one to be used to write out the tree to be committed (temporary index) and the other to be used as the index file after the commit is made. The temporary index needs to be initialized to HEAD and then all the named paths on the command line need to be staged on top of the index. For this, running add_files_to_cache() that compares what is in the index and the paths given from the command line is not enough -- the comparison will mi...
Nov 18, 6:21 am 2007
Junio C Hamano
Re: [PATCH] builtin-commit: fix partial-commit support
- read the index file after pre-commit hook returns, as the This ", but keep the addition" is no longer necessary; the set of paths discovered in step (0) _will_ include the added paths -
Nov 18, 6:57 am 2007
Junio C Hamano
Re: [PATCH] builtin-commit: fix partial-commit support
This "excluded", and the whole "struct dir" business is unneeded, as we are walking on the index and finding the set of paths the user cares about. -
Nov 18, 2:44 pm 2007
Junio C Hamano
Re: [PATCH] builtin-commit: fix partial-commit support
The above four are to be applied on top of kh/commit series, (without the WIP I sent out last night) on top of Dscho's "Replace "runstatus" with "status" in the tests" patch. With these, all tests in t/ finally passes for me ;-) But I am not a heavy user of partial commits nor commits from subdirectories, so there may still be breakages. -
Nov 18, 6:26 am 2007
Shawn O. Pearce
[PATCH] Fix warning about bitfield in struct ref
cache.h:503: warning: type of bit-field 'force' is a GCC extension cache.h:504: warning: type of bit-field 'merge' is a GCC extension cache.h:505: warning: type of bit-field 'nonfastforward' is a GCC extension cache.h:506: warning: type of bit-field 'deletion' is a GCC extension So we change it to an 'unsigned int' which is not a GCC extension. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> --- cache.h | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a...
Nov 18, 5:31 am 2007
Jeff King
[PATCH] avoid "defined but not used" warning for fetch_objs_...
Because this function is static and used only by the http-walker, when NO_CURL is defined, gcc emits a "defined but not used" warning. Signed-off-by: Jeff King <peff@peff.net> --- On master. I like to compile with -Werror to make sure I don't miss warnings as the compile scrolls by. This fix feels a little wrong, since the function isn't specific to http support, but hopefully the comment should be obvious if we ever add another similar commit walker that needs it. transport.c | 2 ...
Nov 18, 4:17 am 2007
Jeff King
[PATCH] send-pack: improve error reporting for total remote ...
If the remote doesn't give us per-ref status reports, then we pessimistically assume that all refs failed. However, instead of just exiting the function, we now mark them individually as failed. This lets us print the usual status table, but refs which failed in this way are marked individually (alongside refs which may have failed for other reasons, like being rejected for non-ff status). Signed-off-by: Jeff King <peff@peff.net> --- I think this is a bit nicer. However, I noticed that...
Nov 18, 1:58 am 2007
Jeff King
[PATCH 3/2] send-pack: fix "everything up-to-date" message
This has always been slightly inaccurate, since it used the new_refs counter, which really meant "did we send any objects," so deletions were not counted. It has gotten even worse with recent patches, since we no longer look at the 'ret' value, meaning we would say "up to date" if non-ff pushes were rejected. Instead, we now claim up to date iff every ref is either unmatched or up to date. Any other case should already have generated a status line. Signed-off-by: Jeff King <peff@peff.net&g...
Nov 18, 4:08 am 2007
Jeff King
[PATCH 1/2] make "find_ref_by_name" a public function
This was a static in remote.c, but is generally useful. Signed-off-by: Jeff King <peff@peff.net> --- cache.h | 2 ++ refs.c | 8 ++++++++ remote.c | 8 -------- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/cache.h b/cache.h index ba9178f..1f3f113 100644 --- a/cache.h +++ b/cache.h @@ -521,6 +521,8 @@ struct ref { #define REF_HEADS (1u << 1) #define REF_TAGS (1u << 2) +extern struct ref *find_ref_by_name(struct ref *list, const char *nam...
Nov 18, 3:13 am 2007
Jeff King
[PATCH 2/2] send-pack: tighten remote error reporting
Previously, we set all ref pushes to 'OK', and then marked them as errors if the remote reported so. This has the problem that if the remote dies or fails to report a ref, we just assume it was OK. Instead, we use a new non-OK state to indicate that we are expecting status (if the remote doesn't support the report-status feature, we fall back on the old behavior). Thus we can flag refs for which we expected a status, but got none (conversely, we now also print a warning for refs for which we get ...
Nov 18, 3:16 am 2007
Jeff King
Re: [PATCH 2/2] send-pack: tighten remote error reporting
Gah, that should of course be: And the same here. I had resisted making a test that checked the exact output format, because such things are often a pain to keep up to date. But that's two regressions in patches I've submitted that would have been caught. Maybe I should just pay more attention. -Peff -
Nov 18, 3:59 am 2007
Jeff King
Re: [PATCH] send-pack: improve error reporting for total rem...
This turned out to be pretty easy, given the other recent changes, and I think it actually makes the code a bit clearer. Please scrap the patch to which I am replying, and I will post a replacement series in a second. -Peff -
Nov 18, 3:09 am 2007
Jeff King
Re: [PATCH] send-pack: improve error reporting for total rem...
> Subject: [PATCH] send-pack: improve error reporting for total remote unpack Oops, the subject was supposed to be "...total remote _failure_". -Peff -
Nov 18, 1:59 am 2007
Junio C Hamano
[PATCH] grep -An -Bm: fix invocation of external grep command
When building command line to invoke external grep, the arguments to -A/-B/-C options were placd in randarg[] buffer, but the code forgot that snprintf() does not count terminating NUL in its return value. This caused "git grep -A1 -B2" to invoke external grep with "-B21 -A1". Signed-off-by: Junio C Hamano <gitster@pobox.com> --- * This bug was present since mid May, 2006. builtin-grep.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/builtin-grep.c b/...
Nov 18, 1:18 am 2007
Robin Rosenberg
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
I think this explanation deserves a place in the commit too. -- robin -
Nov 18, 7:03 am 2007
Junio C Hamano
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
If the rationale was "running in a thread is more natural on the platform", I would understand it. But "_must_ run because there is no fork(2)" solicits a "Huh? How does Cygwin does it then?" from me. -
Nov 17, 8:42 pm 2007
Johannes Sixt
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
Alex has answered this. We are not going to copy Cygwin's fork() into git. -- Hannes -
Nov 18, 5:36 am 2007
Junio C Hamano
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
Wholeheartedly agree, and I feel dirty after looking at that thing. Nothing against Cygwin folks, of course. The reason I wanted to close pipes as early as possible was because I did not want to get bitten by "read() waiting forever for EOF due to an extra unclosed fd on the writer end of the pipe() without the writer not writing anything to it" problem, which is an often-seen mistake. As long as you did not introduce that problem the change is fine by me. -
Nov 18, 6:16 am 2007
Johannes Sixt
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
That was my concern, too, and I spent quite a few brain cycles to verify that this is not the case here. -- Hannes -
Nov 18, 8:23 am 2007
Alex Riesen
Re: [PATCH] fetch-pack: Prepare for a side-band demultiplexe...
You wont believe it: they start the currently running program again and copy parents memory over into the child. Sometimes it fails. If you want something scary: http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/fork.cc?rev=1.193&content-t... -
Nov 17, 9:05 pm 2007
Junio C Hamano
Re: What's cooking in git.git (topics)
True. Let's have it in 'next' then. -
Nov 17, 9:29 pm 2007
Junio C Hamano
Re: [Advance Warning PATCH] Move gitk to its own subdirectory
Not necessarily. The policy is completely up to the superproject (which is git.git). Currently, the policy is "make all" and "make install" in git.git builds and installs what are considered core parts of the system which includes git-gui and gitk. gitk nor git-gui should not become useless without being in git.git (iow, their build procedure better not depend on things outside their subtree), but I do not think that is a hard requirement either. Shawn *chose* to keep git-gui buildable and ...
Nov 17, 9:18 pm 2007
Junio C Hamano
Re: [PATCH 3/3] send-pack: assign remote errors to each ref
It probably would not matter for sane repositories, but with thousands of refs, strlen() and prefixcmp() may start to hurt: struct ref *ref; int reflen; const char *msg = strchr(line, ' '); if (!msg) return NULL; reflen = msg - line; msg++; for (ref = refs; ref; ref = ref->next) { if (strncmp(line, ref->name, reflen) || line[reflen] != ' ') continue; ... return ref->next; } return NULL; but the "hint" optimization probably make the ab...
Nov 17, 9:03 pm 2007
Jeff King
Re: [PATCH 3/3] send-pack: assign remote errors to each ref
It is actually _just_ prefixcmp. Or do you mean the strlen we call in prefixcmp? If so, I think the right solution is to make prefixcmp Nothing else sets the string, so the latter is not possible (perhaps it should be "remote_error" for clarity). It is less clear that we are not overwriting another status; however, if you look at do_send_pack, we only actually send the remote refs that are getting REF_STATUS_OK. A broken or malicious remote could change the push status of an arbitrary ref t...
Nov 17, 10:39 pm 2007
Junio C Hamano
Re: [PATCH 3/3] send-pack: assign remote errors to each ref
I was referring to strlen(ref->name) taken for all refs during the loop. Micro-optimized one finds the end of refname on the I do not think it is particularly a big deal -- perhaps clean it before we touch the vicinity of the code next time. The same Ah, Ok. -
Nov 18, 12:47 am 2007
Jeff King
Re: [PATCH 3/3] send-pack: assign remote errors to each ref
I don't see such a strlen, except in the implementation of prefixcmp, because we continue most of the time based on its result. If you have a false match on the prefixcmp (i.e., a prefix of another ref), you do an extra strlen. But I don't think this is worth micro-optimizing. -Peff -
Nov 18, 1:00 am 2007
Jeff King
Re: [PATCH 3/3] send-pack: assign remote errors to each ref
Not unreasonable, though I started in that direction and it ended up being less readable (which isn't to say that it's not possible). But it looks like Junio has merged to next, so I think it is best to leave it as-is. -Peff -
Nov 17, 8:03 pm 2007
Jeff King
Re: [PATCH 1/3] send-pack: track errors for each ref
I see you fixed up the off-by-one buffer, too. Thanks. -Peff -
Nov 17, 8:15 pm 2007
Jeff King
Re: [PATCH 1/3] send-pack: track errors for each ref
Yes, I also considered changing "from" to "show peer" which might have been nicer. I am not opposed to such a cleanup, but again, not sure if I agree, though I don't feel qualified to comment on what other places that should be used (I was a bit surprised to find out that find_unique_abbrev ever returned NULL, but changing the semantics at Oops, yes. I think it should be hard to trigger (both commits would have to either not be in your db, or not be unique to 40 digits). But clearly it should b...
Nov 17, 8:13 pm 2007
Junio C Hamano
Re: [PATCH 1/3] send-pack: track errors for each ref
I think Daniel is referring to "Put 'else' on the same line as the brace that closes the corresponding 'if' opened", iow: if (...) { ... } else { ... } -
Nov 17, 9:21 pm 2007
previous daytodaynext day
November 17, 2007November 18, 2007November 19, 2007