Re: [PATCH v3] config: add support for http.url.* settings

2013-07-12 Thread Aaron Schrab
At 06:07 -0700 12 Jul 2013, Kyle J. McKay mack...@gmail.com wrote: I don't think it's necessary to split the URL apart though. Whatever URL the user gave to git on the command line (at some point even if it's now stored as a remote setting in config) complete with URL- encoding, user names,

Re: [PATCH v2] CEST is +0200 during April

2013-08-17 Thread Aaron Schrab
Mattias, the convention on this list is to send directly to participants in the thread as well as the list. So I've added Andreas as a recipient. At 05:52 +0200 17 Aug 2013, Mattias Andrée maand...@operamail.com wrote: - For example CET (which is 2 hours ahead UTC) is `+0200`. +

Strange behaviour of git diff branch1 ... branch2

2012-10-26 Thread Aaron Schrab
I came across this odd question on stackoverflow: http://stackoverflow.com/q/13092854/1507392 If git diff is run with ... as a separate argument between two commit-ish arguments causes it to produce strange output. The differences seem to be the same as if ... was left out, but

Re: [PATCH 7/7] push: document --lockref

2013-07-09 Thread Aaron Schrab
At 12:53 -0700 09 Jul 2013, Junio C Hamano gits...@pobox.com wrote: +This is meant to make `--force` safer to use. Imagine that you have +to rebase what you have already published. You will have to +`--force` the push to replace the history you originally published +with the rebased history.

Re: RFC: git config -l should not expose sensitive information

2012-12-20 Thread Aaron Schrab
At 10:04 -0500 20 Dec 2012, Jeff King p...@peff.net wrote: The problem seems to be that people are giving bad advice to tell people to post git config -l output without looking at. Maybe we could help them with a git config --share-config option that dumps all config, but sanitizes the output.

[PATCH 1/4] hooks: Add function to check if a hook exists

2012-12-28 Thread Aaron Schrab
it is anticipated that the return value will either be used as a boolean, or immediately added to an argv_array list which would result in it being duplicated at that point. Signed-off-by: Aaron Schrab aa...@schrab.com --- run-command.c | 15 +-- run-command.h |1 + 2 files changed, 14

[PATCH 2/4] hooks: support variable number of parameters

2012-12-28 Thread Aaron Schrab
at compile time. This function will allow the caller of a hook to determine the number of arguments to pass when preparing to call the hook. The first use of this function will be for a pre-push hook which will add an argument for every reference which is to be pushed. Signed-off-by: Aaron Schrab aa

[PATCH 4/4] Add sample pre-push hook script

2012-12-28 Thread Aaron Schrab
-by: Aaron Schrab aa...@schrab.com --- templates/hooks--pre-push.sample | 63 ++ 1 file changed, 63 insertions(+) create mode 100644 templates/hooks--pre-push.sample diff --git a/templates/hooks--pre-push.sample b/templates/hooks--pre-push.sample new file mode 100644

[PATCH 3/4] push: Add support for pre-push hooks

2012-12-28 Thread Aaron Schrab
(es), the commits which are to be pushed, and even the source branches in some cases. Signed-off-by: Aaron Schrab aa...@schrab.com --- Documentation/githooks.txt | 28 + builtin/push.c |1 + t/t5571-pre-push-hook.sh | 145

[PATCH] Use longer alias names in subdirectory tests

2012-12-28 Thread Aaron Schrab
name for the 'test' alias as well since that is also short and meaningful enough to make it not unlikely that somebody would have a command in their $PATH which will shadow that as well. Signed-off-by: Aaron Schrab aa...@schrab.com --- t/t1020-subdirectory.sh | 12 ++-- 1 file changed, 6

Re: [PATCH 0/4] pre-push hook support

2012-12-29 Thread Aaron Schrab
At 18:01 -0800 28 Dec 2012, Junio C Hamano gits...@pobox.com wrote: One lesson we learned long time ago while doing hooks is to avoid unbound number of command line arguments and instead feed them from the standard input. I think this should do the same. Good point. I had been trying to keep

Re: [PATCH 1/4] hooks: Add function to check if a hook exists

2012-12-29 Thread Aaron Schrab
At 18:08 -0800 28 Dec 2012, Junio C Hamano gits...@pobox.com wrote: Aaron Schrab aa...@schrab.com writes: Create find_hook() function to determine if a given hook exists and is executable. If it is the path to the script will be returned, otherwise NULL is returned. Sounds like a sensible

[PATCH v2 0/3] pre-push hook support

2013-01-12 Thread Aaron Schrab
Main changes since the initial version: * The first patch converts the existing hook callers to use the new find_hook() function. * Information about what is to be pushed is now sent over a pipe rather than passed as command-line parameters. Aaron Schrab (3): hooks: Add function

[PATCH v2 1/3] hooks: Add function to check if a hook exists

2013-01-12 Thread Aaron Schrab
for a longer time are expected to duplicate the return value themselves. Signed-off-by: Aaron Schrab aa...@schrab.com --- builtin/commit.c | 6 ++ builtin/receive-pack.c | 25 +++-- run-command.c | 15 +-- run-command.h | 1 + 4 files

[PATCH v2 2/3] push: Add support for pre-push hooks

2013-01-12 Thread Aaron Schrab
), the commits which are to be pushed, and even the source branches in some cases. Signed-off-by: Aaron Schrab aa...@schrab.com --- Documentation/githooks.txt | 29 ++ builtin/push.c | 1 + t/t5571-pre-push-hook.sh | 129

[PATCH v2 3/3] Add sample pre-push hook script

2013-01-12 Thread Aaron Schrab
-by: Aaron Schrab aa...@schrab.com --- templates/hooks--pre-push.sample | 53 1 file changed, 53 insertions(+) create mode 100644 templates/hooks--pre-push.sample diff --git a/templates/hooks--pre-push.sample b/templates/hooks--pre-push.sample new file mode 100644

[PATCH 2/2] clone: Allow repo using gitfile as a reference

2013-04-07 Thread Aaron Schrab
Try reading gitfile files when processing --reference options to clone. This will allow, among other things, using a submodule checked out with a recent version of git as a reference repository without requiring the user to have internal knowledge of submodule layout. Signed-off-by: Aaron Schrab

[PATCH 1/2] clone: Fix error message for reference repository

2013-04-07 Thread Aaron Schrab
to finding the problem. Signed-off-by: Aaron Schrab aa...@schrab.com --- builtin/clone.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/clone.c b/builtin/clone.c index f9c380e..0a1e0bf 100644 --- a/builtin/clone.c +++ b/builtin/clone.c @@ -241,7 +241,7 @@ static int

Re: [PATCH 1/2] clone: Fix error message for reference repository

2013-04-07 Thread Aaron Schrab
At 16:48 -0700 07 Apr 2013, Jonathan Nieder jrnie...@gmail.com wrote: Hi Aaron, Thanks for the feedback. Aaron Schrab wrote: Do not report an argument to clone's --reference option is not a local directory. Nothing checks for the actual directory so we have no way to know if whether

Re: [PATCH 2/2] clone: Allow repo using gitfile as a reference

2013-04-07 Thread Aaron Schrab
At 16:51 -0700 07 Apr 2013, Jonathan Nieder jrnie...@gmail.com wrote: - char *ref_git; + char *ref_git, *repo; [...] + repo = (char *)read_gitfile(mkpath(%s/.git, ref_git)); Why not make repo a const char * and avoid the cast? The above would seem to make it too tempting

Re: [PATCH 1/2] clone: Fix error message for reference repository

2013-04-07 Thread Aaron Schrab
At 20:06 -0400 07 Apr 2013, I wrote: At 16:48 -0700 07 Apr 2013, Jonathan Nieder jrnie...@gmail.com wrote: Would it make sense for the message to say something like the following? fatal: alternate object store '/path/to/repo.git/objects' is not a local directory That would also

Re: [PATCH 1/2] clone: Fix error message for reference repository

2013-04-08 Thread Aaron Schrab
At 06:58 -0700 08 Apr 2013, Junio C Hamano gits...@pobox.com wrote: I do agree that it would be nice to dereference .git gitfile when we deal with --reference argument, but you do not want to use in-tree repository of a submodule working tree. What happens when you have to check out a version

Re: [PATCH 1/2] clone: Fix error message for reference repository

2013-04-08 Thread Aaron Schrab
At 08:30 -0700 08 Apr 2013, Junio C Hamano gits...@pobox.com wrote: You switch to a version of the superproject with a plain file at dirA/ or there is nothing at dirA. The checkout will fail and you need to manually rectify the situation [*1*], but after that is done, you do not have any

Re: [PATCH 1/2] clone: Fix error message for reference repository

2013-04-08 Thread Aaron Schrab
At 10:57 -0700 08 Apr 2013, Junio C Hamano gits...@pobox.com wrote: In general I am in favor of resolving a gitfile given to --reference when clone interprets it, and have it use the location of the real underlying object store when it grabs objects not in there from the origin and store the

Re: [PATCH 2/2] clone: Allow repo using gitfile as a reference

2013-04-08 Thread Aaron Schrab
At 11:00 -0700 08 Apr 2013, Junio C Hamano gits...@pobox.com wrote: Aaron Schrab aa...@schrab.com writes: Good catch. I'll fix that in the next version. Thanks. The patch otherwise looks good to me. Great, I'll plan to send version 2 of this series later today. -- To unsubscribe from

[PATCH v2 0/2] Using gitfile repository with clone --reference

2013-04-08 Thread Aaron Schrab
Here's the promised second version of this series. The diff in the first patch is unchanged, but I have made significant changes to the commit message to hopefully to a better job of describing why I think the old error message is bad. For the second patch I've eliminated the need to do a cast.

[PATCH 1/2] clone: Fix error message for reference repository

2013-04-08 Thread Aaron Schrab
paths which were checked, but I believe that giving a good description of that would be too verbose for a simple error message and would be too dependent on implementation details. Signed-off-by: Aaron Schrab aa...@schrab.com --- builtin/clone.c |2 +- 1 file changed, 1 insertion(+), 1 deletion

Re: [PATCH 2/2] clone: Allow repo using gitfile as a reference

2013-04-09 Thread Aaron Schrab
At 17:24 -0700 08 Apr 2013, Jonathan Nieder jrnie...@gmail.com wrote: +test_expect_success 'clone using repo with gitfile as a reference' ' + git clone --separate-git-dir=L A M + git clone --reference=M A N What should happen if I pass --reference=M/.git? That isn't supported

Re: [PATCH 2/2] clone: Allow repo using gitfile as a reference

2013-04-09 Thread Aaron Schrab
At 09:47 -0700 09 Apr 2013, Junio C Hamano ju...@pobox.com wrote: Aaron Schrab aa...@schrab.com writes: But if others disagree, I could be convinced to add support for that. If M/.git weren't a gitfile that points elsewhere, that request ought to work, no? A gitfile is the moral equilvalent

[PATCH v3 0/2] Using gitfile repository with clone --reference

2013-04-09 Thread Aaron Schrab
Here's the third version of my series for dealing with gitfiles in clone --reference. The first patch is unchanged from the previous version except for the addition of a Reviewed-by line. The second patch has been modified so that it now supports having a .git file supplied as the argument to

[PATCH v3 1/2] clone: Fix error message for reference repository

2013-04-09 Thread Aaron Schrab
paths which were checked, but I believe that giving a good description of that would be too verbose for a simple error message and would be too dependent on implementation details. Signed-off-by: Aaron Schrab aa...@schrab.com Reviewed-by: Jonathan Nieder jrnie...@gmail.com diff --git a/builtin

[PATCH v3 2/2] clone: Allow repo using gitfile as a reference

2013-04-09 Thread Aaron Schrab
Try reading gitfile files when processing --reference options to clone. This will allow, among other things, using a submodule checked out with a recent version of git as a reference repository without requiring the user to have internal knowledge of submodule layout. Signed-off-by: Aaron Schrab

Re: [PATCH v2 4/5] check-ignore: allow incremental streaming of queries via --stdin

2013-04-11 Thread Aaron Schrab
At 13:05 +0100 11 Apr 2013, Adam Spiers g...@adamspiers.org wrote: The above use case suggests that empty STDIN is actually a reasonable scenario (e.g. when the caller doesn't know in advance whether any queries need to be fed to the background process until after it's already started), so we

Re: difftool: honor --trust-exit-code for builtin tools

2014-11-17 Thread Aaron Schrab
At 10:11 -0800 16 Nov 2014, Junio C Hamano gits...@pobox.com wrote: It does not have any significance that a random shell implementation is not POSIX compliant. That would merely mean that such a shell cannot be used to run POSIX shell scripts like our Porcelain. Right, and I suspect that

Merge without marking conflicts in working tree

2014-11-17 Thread Aaron Schrab
Is there a way to do a merge but only record conflicts in the index, not update the working versions of files with conflict markers? Like many people, I use git to manage configuration files for my shell, editor, git itself, and a number of other things. The vast majority of times that I

Re: Redirect git subcommand to itself?

2015-05-29 Thread Aaron Schrab
At 10:38 +0200 29 May 2015, Christian Neukirchen chneukirc...@gmail.com wrote: Junio C Hamano gits...@pobox.com writes: * You can help yourself with something like this, I suppose: [alias] git = !sh -c 'exec git \$@\' - but I personally feel that it is too ugly to live as part

Re: [RFC-PATCH 1/2] send-email: new option to quote an email and reply to

2016-05-24 Thread Aaron Schrab
At 14:49 +0200 24 May 2016, Matthieu Moy wrote: Samuel GROOT writes: What kind of help text would you want to see? Maybe something like this: GIT: Quoted message body below. GIT: Feel free to trim down the quoted text GIT:

Re: [Opinion gathering] Git remote whitelist/blacklist

2016-05-24 Thread Aaron Schrab
At 14:55 +0200 24 May 2016, Matthieu Moy wrote: So, when trying a forbidden push, Git would deny it and the only way to force the push would be to remove the blacklist from the config, right? Probably the sanest way to go. I thought about adding a "git push

Re: [PATCH 18/18] alternates: use fspathcmp to detect duplicates

2016-10-04 Thread Aaron Schrab
At 16:36 -0400 03 Oct 2016, Jeff King wrote: On a case-insensitive filesystem, we should realize that "a/objects" and "A/objects" are the same path. The current repository being on a case-insensitive filesystem doesn't guarantee that the alternates are as well. On the other

A couple errors dealing with uninitialized submodules

2016-10-20 Thread Aaron Schrab
I was working with a fresh clone of a repository where I'd forgotten that one of the directories was setup as a submodule, so I hadn't initialized it. I tried to add a symlink to a location outside the repository and this failed with an assertion (exact text in comment below). When looking

Re: Is there a way to have local changes in a branch 'bake' while working in different branches?

2016-12-15 Thread Aaron Schrab
At 20:14 + 15 Dec 2016, Larry Minton wrote: Let's say I have a code change that I want to 'bake' for a while locally, just to make sure some edge case doesn't pop up while I am working on other things.  Is there any practical way of doing that? I could constantly

Re: git describe number of commits different from git log count

2016-12-05 Thread Aaron Schrab
At 12:17 +0100 05 Feb 2016, Jan Hudec wrote: I have a repository with following situation: $ git describe next v4.1-2196-g5a414d7 $ git describe next --match=v4.2 v4.2-4757-g5a414d7 Since the tag with fewest commits since is selected, it appears logical. However, v4.2

Re: [PATCH/RFC] completion: complete all possible -no-

2018-05-08 Thread Aaron Schrab
At 17:24 +0200 08 May 2018, Duy Nguyen wrote: It took me so long to reply partly because I remember seeing some guy doing clever trick with tab completion that also shows a short help text in addition to the complete words. I could not find that again and from my reading

[PATCH] sequencer: use configured comment character

2018-06-27 Thread Aaron Schrab
Use configured comment character when generating comments about branches in an instruction sheet. Failure to honor this configuration causes a failure to parse the resulting instruction sheet. Signed-off-by: Aaron Schrab --- sequencer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

Re: [PATCH v3] Documentation: declare "core.ignorecase" as internal variable

2018-06-27 Thread Aaron Schrab
At 12:11 -0700 27 Jun 2018, Junio C Hamano wrote: Hmph. Do other people have difficulty applying this patch to their trees? It is just several lines long so I could retype it myself, but I guess "Content-Type: text/plain; charset=utf-8; format=flowed" has destroyed formatting of the patch

Re: [PATCH 2/2] submodule: munge paths to submodule git directories

2018-08-15 Thread Aaron Schrab
At 15:33 -0700 08 Aug 2018, Brandon Williams wrote: Teach "submodule_name_to_gitdir()" to munge a submodule's name (by url encoding it) before using it to build a path to the submodule's gitdir. Seems like this will be a problem if it results in names that exceed NAME_MAX? On common systems

[PATCH v3] sequencer: use configured comment character

2018-07-15 Thread Aaron Schrab
At 10:15 -0700 12 Jul 2018, Junio C Hamano wrote: >Aaron Schrab writes: >> Note that the comment_line_char has already been resolved by this point, >> even if the user has configured the comment character to be selected >> automatically. > >Isn't this a slight li

Re: [PATCH 0/2] Fix --rebase-merges with custom commentChar

2018-07-11 Thread Aaron Schrab
nor this configuration causes a failure to parse the resulting todo list. Note that the comment_line_char has already been resolved by this point, even if the user has configured the comment character to be selected automatically. Signed-off-by: Aaron Schrab --- sequencer.c | 2 +- 1 file changed