Re: [PATCH] column doc: rewrite documentation for column.ui

2013-06-25 Thread Ramkumar Ramachandra
Junio C Hamano wrote: > One micronit (read: if you think the suggested change is a good > idea, I could just locally amend it) is that it would read better > and also easier to maintain to say > > These options control > > without "three". Both 'man' and 'html' output looked good. Sure, a

[PATCH] documentation: add git transport security notice

2013-06-25 Thread Fraser Tweedale
The fact that the git transport does not do any authentication is easily overlooked. For example, DNS poisoning may result in fetching from somewhere that was not intended. Add a brief security notice to the "GIT URLS" section of the documentation stating that the git transport should be used wit

Re: [PATCH 11/16] rev-list: add bitmap mode to speed up lists

2013-06-25 Thread Jeff King
On Tue, Jun 25, 2013 at 09:22:28AM -0700, Thomas Rast wrote: > Vicent Marti writes: > > > Calling `git rev-list --use-bitmaps [committish]` is the equivalent > > of `git rev-list --objects`, but the rev list is performed based on > > a bitmap result instead of using a manual counting objects pha

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Jeff King
On Tue, Jun 25, 2013 at 09:33:11PM +0200, Vicent Martí wrote: > > One way we side-stepped the size inflation problem in JGit was to only > > use the bitmap index information when sending data on the wire to a > > client. Here delta reuse plays a significant factor in building the > > pack, and we

Re: [PATCH 03/16] pack-objects: use a faster hash table

2013-06-25 Thread Jeff King
On Tue, Jun 25, 2013 at 10:14:17PM -0400, Jeff King wrote: > So I suspect two things (but as I said, haven't verified): > > 1. You could speed up pack-objects just by keeping the table half full > rather than 3/4 full. I wasn't able to show any measurable speedup with this. I tried to mak

[PATCH v2 5/5] git-prompt.sh: add missing information in comments

2013-06-25 Thread Eduardo R. D'Avila
Mention that the command below is needed for prompt in ZSH with PS1: setopt PROMPT_SUBST Rephrase some parts that mention only the "current branch name" being displayed in the prompt. Replace it by stating that the "repository status" is displayed. Make it clear that colored prompt is only avai

[PATCH v2 4/5] git-prompt.sh: do not print duplicate clean color code

2013-06-25 Thread Eduardo R. D'Avila
Do not print a duplicate clean color code when there is no other indicators other than the current branch in colored prompt. Acked-by: SZEDER Gábor Signed-off-by: Eduardo R. D'Avila --- 1 1 contrib/completion/git-prompt.sh 4 4 t/t9903-bash-prompt.sh contrib/completion/gi

[PATCH v2 3/5] t9903: remove redundant tests

2013-06-25 Thread Eduardo R. D'Avila
After refactoring __git_ps1_colorize_gitstring, codepaths for bash and zsh became mostly common and tests for bash and zsh became redundant. Remove tests for zsh. Keep one minimal test that stress the difference in codepaths for bash and zsh. Suggested-by: SZEDER Gábor Signed-off-by: Eduardo R.

[PATCH v2 2/5] git-prompt.sh: refactor colored prompt code

2013-06-25 Thread Eduardo R. D'Avila
__git_ps1_colorize_gitstring() sets color codes and builds the prompt gitstring. It has duplicated code to handle color codes for bash and zsh shells. __git_ps1() also has duplicated logic to build the prompt gitstring. Remove duplication of logic to build gitstring in __git_ps1_colorize_gitstring

[PATCH v2 1/5] t9903: add tests for git-prompt pcmode

2013-06-25 Thread Eduardo R. D'Avila
git-prompt.sh lacks tests for PROMPT_COMMAND mode. Add tests for: * pcmode prompt without colors * pcmode prompt with colors for bash * pcmode prompt with colors for zsh Having these tests enables an upcoming refactor in a safe way. Signed-off-by: Eduardo R. D'Avila --- 254 0 t/t9903-

[PATCH v2 0/5] git-prompt: cleaning and improvement

2013-06-25 Thread Eduardo R. D'Avila
Changes since the first version [1]: - During refactorization in 2/5, mention what the lack of \[...\] can affect. - New patch 3/5 that removes redundant tests (noticed by SZEDER Gábor [2]) - Rephrasing in 5/5: - rephrasing suggested by SZEDER Gábor [3] - rephrase some parts that mention o

Re: [PATCH 03/16] pack-objects: use a faster hash table

2013-06-25 Thread Jeff King
On Tue, Jun 25, 2013 at 04:03:22PM +0200, Thomas Rast wrote: > > The big win here, however, is in the massively reduced amount of hash > > collisions (as you can see from the huge reduction of time spent in > > `hashcmp` after the change). These greatly improved lookup times > > will result critic

Re: [PATCH 11/16] rev-list: add bitmap mode to speed up lists

2013-06-25 Thread Vicent Martí
I'm afraid I cannot reproduce the segfault locally (assuming you're performing the rev-list on the git/git repository). Could you please send me more information, and a core dump if possible? On Tue, Jun 25, 2013 at 6:22 PM, Thomas Rast wrote: > Vicent Marti writes: > >> Calling `git rev-list --

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Andrew Pimlott
Excerpts from Junio C Hamano's message of Tue Jun 25 14:33:18 -0700 2013: > Andrew Pimlott writes: > > Just reponding for the "procedual" part for now. > > > So if I don't want to break the discussion, should I append the unedited > > format-patch output to my message after "scissors", or should

Re: [PATCH 13/16] repack: consider bitmaps when performing repacks

2013-06-25 Thread Vicent Martí
On Wed, Jun 26, 2013 at 1:00 AM, Junio C Hamano wrote: >> @@ -156,6 +156,11 @@ do >> fullbases="$fullbases pack-$name" >> chmod a-w "$PACKTMP-$name.pack" >> chmod a-w "$PACKTMP-$name.idx" >> + >> + test -f "$PACKTMP-$name.bitmap" && >> + chmod a-w "$PACKTMP-$name.bitmap"

Re: [PATCH 10/16] pack-objects: use bitmaps when packing objects

2013-06-25 Thread Vicent Martí
On Wed, Jun 26, 2013 at 1:06 AM, Junio C Hamano wrote: >> @@ -83,6 +84,9 @@ static struct progress *progress_state; >> static int pack_compression_level = Z_DEFAULT_COMPRESSION; >> static int pack_compression_seen; >> >> +static int bitmap_support; >> +static int use_bitmap_index; > > OK. > >> @

Re: [PATCH 03/16] pack-objects: use a faster hash table

2013-06-25 Thread Vicent Martí
On Wed, Jun 26, 2013 at 12:48 AM, Junio C Hamano wrote: > After this, the function returns. The original did not add to the > table the object name we are looking at, but the new code first adds > it to the table with the unconditional kh_put_sha1() above. Is a > call to kh_del_sha1() missing he

Re: [PATCH 10/16] pack-objects: use bitmaps when packing objects

2013-06-25 Thread Junio C Hamano
Vicent Marti writes: > @@ -83,6 +84,9 @@ static struct progress *progress_state; > static int pack_compression_level = Z_DEFAULT_COMPRESSION; > static int pack_compression_seen; > > +static int bitmap_support; > +static int use_bitmap_index; OK. > @@ -2131,6 +2135,10 @@ static int git_pack_

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Andrew Pimlott
Excerpts from Junio C Hamano's message of Tue Jun 25 14:45:07 -0700 2013: > After all, autosquash will give the user an opportunity to eyeball > the result of automatic rearrangement. If the user did this: > > git commit -m original > git commit --fixup original ;# obviously fixing th

Re: [PATCH 13/16] repack: consider bitmaps when performing repacks

2013-06-25 Thread Junio C Hamano
Vicent Marti writes: > @@ -156,6 +156,11 @@ do > fullbases="$fullbases pack-$name" > chmod a-w "$PACKTMP-$name.pack" > chmod a-w "$PACKTMP-$name.idx" > + > + test -f "$PACKTMP-$name.bitmap" && > + chmod a-w "$PACKTMP-$name.bitmap" && > + mv -f "$PACKTMP-$name.bitmap"

Re: [PATCH 08/16] ewah: compressed bitmap implementation

2013-06-25 Thread Junio C Hamano
Junio C Hamano writes: > Vicent Marti writes: > >> The library is re-licensed under the GPLv2 with the permission of Daniel >> Lemire, the original author. The source code for the C version can >> be found on GitHub: >> >> https://github.com/vmg/libewok >> >> The original Java implementatio

Re: [PATCH 03/16] pack-objects: use a faster hash table

2013-06-25 Thread Junio C Hamano
Vicent Marti writes: > @@ -901,19 +896,19 @@ static int no_try_delta(const char *path) > return 0; > } > > -static int add_object_entry(const unsigned char *sha1, enum object_type type, > - const char *name, int exclude) > +static int add_object_entry_1(const unsi

Call For Papers: Venice, Italy --- September 28-30, 2013 (Indexed in ISI ELSEVIER, SCOPUS, ACM, PubMed, Zentralblatt MATH, British Library, EBSCO, SWETS, EMBASE, CAS) git@vger.kernel.org

2013-06-25 Thread Rena N. Politi
Call For Papers and Special Sessions September 28-30, 2013, Venice, Italy http://www.europment.org The 2013 Intern. Conf. on Systems, Control, and Informatics The 2013 Intern. Conf. on Electronics, Signal Processing and Communication Systems The 2013 Intern. Conf. on Applied Mathematics and Com

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Vicent Martí
On Tue, Jun 25, 2013 at 5:58 PM, Thomas Rast wrote: > >> This is the technical documentation and design rationale for the new >> Bitmap v2 on-disk format. > > Hrmpf, that's what I get for reading the series in order... > >> + The folowing flags are supported: >

Re: [PATCH] column doc: rewrite documentation for column.ui

2013-06-25 Thread Junio C Hamano
Ramkumar Ramachandra writes: > The configuration option column.ui is very poorly documented, and it is > unclear what the defaults are, and what option can be combined with > what. Rewrite it by splitting up the options into three sections > clearly showing how COL_ENABLED, COL_LAYOUT_MASK, and

Re: [PATCH] [submodule] Add depth to submodule update

2013-06-25 Thread Heiko Voigt
On Tue, Jun 25, 2013 at 12:49:25AM +0200, Fredrik Gustafsson wrote: > Used only when a clone is initialized. This is useful when the submodule(s) > are huge and you're not really interested in anything but the latest commit. > > Signed-off-by: Fredrik Gustafsson I this is a valid use case. But t

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Vicent Martí
On Tue, Jun 25, 2013 at 11:17 PM, Junio C Hamano wrote: > What case are you talking about? > > The n-th object must be one of these four types and can never be of > more than one type at the same time, so a natural expectation from > the reader is "If you OR them together, you will get the same se

What's cooking in git.git (Jun 2013, #08; Tue, 25)

2013-06-25 Thread Junio C Hamano
Here are the topics that have been cooking. Commits prefixed with '-' are only in 'pu' (proposed updates) while commits prefixed with '+' are in 'next'. You can find the changes described here in the integration branches of the repositories listed at http://git-blame.blogspot.com/p/git-publi

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Junio C Hamano
Junio C Hamano writes: I guess I made typoes in the examples that made then unusable... > I think it is fine not to be too smart, as long as we do not lose > information that would help the user to compensate. > > After all, autosquash will give the user an opportunity to eyeball > the result of

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Junio C Hamano
Andrew Pimlott writes: > I agree that it is better to preserve information as long as feasible. > If we are going to strip it, it may as well be later. That is Thomas's > rearrange_squash patch, which I will send again. Thanks. > The next question is, do we go all the way and respect the neste

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Junio C Hamano
Andrew Pimlott writes: > diff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt > index c84854a..6b2e1c8 100644 > --- a/Documentation/git-rebase.txt > +++ b/Documentation/git-rebase.txt > @@ -389,7 +389,9 @@ squash/fixup series. > the same ..., automatically modify the tod

Re: [PATCH 11/16] rev-list: add bitmap mode to speed up lists

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > Calling `git rev-list --use-bitmaps [committish]` is the equivalent > of `git rev-list --objects`, but the rev list is performed based on > a bitmap result instead of using a manual counting objects phase. Why would we ever want to not --use-bitmaps, once it actually works

Re: [PATCH 00/16] Speed up Counting Objects with bitmap data

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > Like with every other patch that offers performance improvements, > sample benchmarks are provided (spoiler: they are pretty fucking > cool). Great stuff. I read the first half, and skimmed the second half. See the individual replies for comments. However: > Documenta

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Junio C Hamano
Andrew Pimlott writes: Just reponding for the "procedual" part for now. > So if I don't want to break the discussion, should I append the unedited > format-patch output to my message after "scissors", or should I send it > as a whole new message with --in-reply-to? Or something else? I'll try

Re: [PATCH 08/16] ewah: compressed bitmap implementation

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > The library is re-licensed under the GPLv2 with the permission of Daniel > Lemire, the original author. This says "GPLv2", but the license blurbs all say "or (at your option) any later version". IANAL, does this cause any problems? If so, can they be GPLv2-only instead?

Re: [PATCH 03/16] pack-objects: use a faster hash table

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > This commit brings `khash.h`, a header only hash table implementation > that while remaining rather simple (uses quadratic probing and a > standard hashing scheme) and self-contained, offers a significant > performance improvement in both insertion and lookup times. > > `kh

Re: [PATCH 02/16] sha1_file: refactor into `find_pack_object_pos`

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > if (use_lookup) { > - int pos = sha1_entry_pos(index, stride, 0, > - lo, hi, p->num_objects, sha1); > - if (pos < 0) > - return 0; > - return nth_packed_object_offset(p, pos);

Re: [PATCH 10/16] pack-objects: use bitmaps when packing objects

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > diff --git a/Makefile b/Makefile > index e03c773..0f2e72b 100644 > --- a/Makefile > +++ b/Makefile > @@ -703,6 +703,7 @@ LIB_H += notes.h > LIB_H += object.h > LIB_H += pack-revindex.h > LIB_H += pack.h > +LIB_H += pack-bitmap.h > LIB_H += parse-options.h > LIB_H += pa

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Thomas Rast
Vicent Marti writes: > This is the technical documentation and design rationale for the new > Bitmap v2 on-disk format. Hrmpf, that's what I get for reading the series in order... > + The folowing flags are supported: ^^ typos marked by ^ > +

Re: [RFC/PATCH 0/1] cygwin: Remove the Win32 l/stat() functions

2013-06-25 Thread Junio C Hamano
Johannes Sixt writes: > Some context: This is about a patch by Ramsay that removes the > "schizophrenic lstat" hack for Cygwin. Junio, can you please queue that > patch in pu? Sure. Thanks. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@v

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Junio C Hamano
Vicent Martí writes: >>> + There is a bitmap for each Git object type, stored in the >>> following >>> + order: >>> + >>> + - Commits >>> + - Trees >>> + - Blobs >>> + - Tags >>> +

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-25 Thread Torsten Bögershausen
> +++ b/diff.c > @@ -2647,6 +2647,10 @@ static int diff_populate_gitlink(struct diff_filespec > *s, int size_only) > int diff_populate_filespec(struct diff_filespec *s, int size_only) > { > int err = 0; > + enum safe_crlf crlf_warn = (safe_crlf != SAFE_CRLF_FAIL > +

Re: [PATCH] rebase -i: fixup fixup! fixup!

2013-06-25 Thread Andrew Pimlott
Excerpts from Junio C Hamano's message of Mon Jun 17 07:27:20 -0700 2013: > Thomas Rast writes: > > I'm not sure it's worth arguing about whether the "fixup! fixup!" is a > > symptom of some underlying problem, and changing rebase is only tapering > > over the symptom; or whether it's actually a

Re: [PATCH] Do not ignore merge options in interactive rebase

2013-06-25 Thread Junio C Hamano
Junio C Hamano writes: > You should use ${var:+if_set_to_nonempty_use_this} here. > ... > So munging it manually with sloppy "sed" script is simply wrong. Perhaps something like this on top of your patch squashed in? The eval magic lets the shell to split $strategy_opts back into individual wor

Re: [RFC/PATCH 0/1] cygwin: Remove the Win32 l/stat() functions

2013-06-25 Thread Torsten Bögershausen
On 25.06.13 21:23, Johannes Sixt wrote: > Am 25.06.2013 00:10, schrieb Junio C Hamano: >> Mark Levedahl writes: >> >>> On 06/22/2013 03:38 PM, Ramsay Jones wrote: Also, apart from running the git test-suite, I have the Win32 l/stat functions disabled on all of my repos. In particular, I

Re: [PATCH 09/16] documentation: add documentation for the bitmap format

2013-06-25 Thread Vicent Martí
On Tue, Jun 25, 2013 at 7:42 AM, Shawn Pearce wrote: > I very much hate seeing a file format that is supposed to be portable > that supports both big-endian and little-endian encoding. Well, the bitmap index is not supposed to be portable, as it doesn't get sent over the wire in any situation. Re

Re: [PATCH v6 0/5] Reroll patches against v1.8.3.1

2013-06-25 Thread Junio C Hamano
Alexey Shumkin writes: > 4. [PATCH v6 4/5] pretty: Add failing tests: --format output should honor > logOutputEncoding > iso8859-5 encoding reverted back to cp1251 encoding (as it was in v4 > series) Thanks for a reroll, but why this change? The reason I asked you to avoid 8859-5 is bec

Re: [PATCH v14 03/16] quote.c: remove path_relative, use relative_path instead

2013-06-25 Thread Junio C Hamano
Jiang Xin writes: > 2013/6/25 Junio C Hamano : >> Jiang Xin writes: >> >>> Since there is an enhanced version of relative_path() in path.c, >>> remove duplicate counterpart path_relative() in quote.c. >> >> There is no nice comparison chart before and after like you had in >> patch 02/16? >> > >

Re: [RFC/PATCH 0/1] cygwin: Remove the Win32 l/stat() functions

2013-06-25 Thread Johannes Sixt
Am 25.06.2013 00:10, schrieb Junio C Hamano: > Mark Levedahl writes: > >> On 06/22/2013 03:38 PM, Ramsay Jones wrote: >>> Also, apart from running the git test-suite, I have the Win32 >>> l/stat functions disabled on all of my repos. In particular, I have >>> core.filemode set to true. (At one po

Re: [PATCH] Do not ignore merge options in interactive rebase

2013-06-25 Thread Junio C Hamano
Arnaud Fontaine writes: > Fix inconsistency where `--strategy` and/or `--strategy-option` can be > specified in git rebase, but with `--interactive` argument only there > were completely ignored. > > Signed-off-by: Arnaud Fontaine > --- > git-rebase--interactive.sh| 13 ++--- > t/t3

[PATCH] .mailmap: Map "H.Merijn Brand" to "H. Merijn Brand"

2013-06-25 Thread Stefan Beller
This patch was created by searching for duplicates of email addresses in the shortlog by git shortlog -sne |awk '{ print $NF }' |sort |uniq -d This will yield all email addresses, which are found multiple times within the shortlog. We can assume that commiters having the same email address are

[PATCH v15 09/16] git-clean: add colors to interactive git-clean

2013-06-25 Thread Jiang Xin
Show header, help, error messages, and prompt in colors for interactive git-clean. Re-use config variables, such as "color.interactive" and "color.interactive." for command `git-add--interactive`. Signed-off-by: Jiang Xin Comments-by: Matthieu Moy Signed-off-by: Junio C Hamano --- Documentatio

[PATCH v15 12/16] git-clean: add select by numbers interactive action

2013-06-25 Thread Jiang Xin
Draw a multiple choice menu using `list_and_choose` to select items to be deleted by numbers. User can input: * 1,5-7 : select 1,5,6,7 items to be deleted * * : select all items to be deleted * -*: unselect all, nothing will be deleted *: (empty) finish selecting, and retur

[PATCH] column doc: rewrite documentation for column.ui

2013-06-25 Thread Ramkumar Ramachandra
The configuration option column.ui is very poorly documented, and it is unclear what the defaults are, and what option can be combined with what. Rewrite it by splitting up the options into three sections clearly showing how COL_ENABLED, COL_LAYOUT_MASK, and COL_DENSE work. Signed-off-by: Ramkuma

[PATCH v15 10/16] git-clean: use a git-add-interactive compatible UI

2013-06-25 Thread Jiang Xin
Rewrite menu using a new method `list_and_choose`, which is borrowed from `git-add--interactive.perl`. We will use this framework to add new actions for interactive git-clean later. Please NOTE: * Method `list_and_choose` return an array of integers, and * it is up to you to free the allocated

[PATCH v15 14/16] git-clean: add documentation for interactive git-clean

2013-06-25 Thread Jiang Xin
Add new section "Interactive mode" for documentation of interactive git-clean. Signed-off-by: Jiang Xin Helped-by: Eric Sunshine Signed-off-by: Junio C Hamano --- Documentation/git-clean.txt | 65 +++-- 1 file changed, 63 insertions(+), 2 deletions(-) d

[PATCH v15 13/16] git-clean: add ask each interactive action

2013-06-25 Thread Jiang Xin
Add a new action for interactive git-clean: ask each. It's just like the "rm -i" command, that the user must confirm one by one for each file or directory to be cleaned. Signed-off-by: Jiang Xin Signed-off-by: Junio C Hamano --- builtin/clean.c | 36 1 file

[PATCH v15 16/16] test: run testcases with POSIX absolute paths on Windows

2013-06-25 Thread Jiang Xin
Some test cases are skipped on Windows by marking with POSIX prereq. This is because arguments look like absolute paths (such as /a/b) for regular Windows programs (*.exe executables, no bash scripts) are changed to Windows paths (like C:/msysgit/a/b). There is no cygpath nor equivalent on msysGit

[PATCH v15 08/16] git-clean: show items of del_list in columns

2013-06-25 Thread Jiang Xin
When there are lots of items to be cleaned, it is hard to see them all in one screen. Show them in columns will solve this problem. Signed-off-by: Jiang Xin Comments-by: Matthieu Moy Signed-off-by: Junio C Hamano --- Documentation/config.txt | 4 builtin/clean.c | 49 +++

[PATCH v15 11/16] git-clean: add filter by pattern interactive action

2013-06-25 Thread Jiang Xin
Add a new action for interactive git-clean: filter by pattern. When the user chooses this action, user can input space-separated patterns (the same syntax as gitignore), and each clean candidate that matches with one of the patterns will be excluded from cleaning. When the user feels it's OK, press

[PATCH v15 15/16] test: add t7301 for git-clean--interactive

2013-06-25 Thread Jiang Xin
Add test cases for git-clean--interactive. Signed-off-by: Jiang Xin Signed-off-by: Junio C Hamano --- t/t7301-clean-interactive.sh | 439 +++ 1 file changed, 439 insertions(+) create mode 100755 t/t7301-clean-interactive.sh diff --git a/t/t7301-clean-in

[PATCH v15 07/16] git-clean: add support for -i/--interactive

2013-06-25 Thread Jiang Xin
Show what would be done and the user must confirm before actually cleaning. Would remove ... Would remove ... Would remove ... Remove [y/n]? Press "y" to start cleaning, and press "n" if you want to abort. Signed-off-by: Jiang Xin Signed-off-by: Junio C Hamano --- Documentati

[PATCH v15 04/16] Refactor quote_path_relative, remove unused params

2013-06-25 Thread Jiang Xin
After substitute path_relative() in quote.c with relative_path() from path.c, parameters (such as len and prefix_len) are obsolete in function quote_path_relative(). Remove unused parameters and change the order of parameters for quote_path_relative() function. Signed-off-by: Jiang Xin Signed-off

[PATCH v15 06/16] git-clean: refactor git-clean into two phases

2013-06-25 Thread Jiang Xin
Before introducing interactive git-clean, refactor git-clean operations into two phases: * hold cleaning items in del_list, * and remove them in a separate loop at the end. We will introduce interactive git-clean between the two phases. The interactive git-clean will show what would be done and

[PATCH v15 00/16] Interactive git clean

2013-06-25 Thread Jiang Xin
Update since v14: * Add more testcases for relative_path. See patch 01/16. * Refactor: change arguments name for relative_path (in path.c), i.e. abc -> in, base -> prefix. This is because the first argument is not restricted to absolute path any more. See patch 02/16. * Move git-ls-f

[PATCH v15 03/16] quote.c: substitute path_relative with relative_path

2013-06-25 Thread Jiang Xin
Substitute the function path_relative in quote.c with the function relative_path. Function relative_path can be treated as an enhanced and robust version of path_relative. Outputs of path_relative and it's replacement (relative_path) are the same for the following cases: path prefix

[PATCH v15 01/16] test: add test cases for relative_path

2013-06-25 Thread Jiang Xin
Add subcommand "relative_path" in test-path-utils, and add test cases in t0060. Johannes tested this commit on Windows, and found that some relative_path tests should be skipped on Windows. This is because the bash on Windows rewrites arguments of regular Windows programs, such as git and the test

[PATCH v15 05/16] Refactor write_name_quoted_relative, remove unused params

2013-06-25 Thread Jiang Xin
After substitute path_relative() in quote.c with relative_path() from path.c, parameters (such as len and prefix_len) are obsolete in function write_name_quoted_relative(). Remove unused parameters from write_name_quoted_relative() and related functions. Signed-off-by: Jiang Xin Signed-off-by: Ju

[PATCH v15 02/16] path.c: refactor relative_path(), not only strip prefix

2013-06-25 Thread Jiang Xin
Original design of relative_path() is simple, just strip the prefix (*base) from the absolute path (*abs). In most cases, we need a real relative path, such as: ../foo, ../../bar. That's why there is another reimplementation (path_relative()) in quote.c. Borrowed some codes from path_relative() in

Re: Basic git-archive --remote question

2013-06-25 Thread Carlos Martín Nieto
On Mon, 2013-06-24 at 15:53 -0400, Greg Freemyer wrote: > I'm trying to create a tarball from a git tag and I can't get the > syntax right. The documentation is not very clear. > > Can someone help me? > > == details > > git v1.8.1.4 > > The upstream git repo is at: https://github.com/dkovar/a

Re: [PATCH 07/16] compat: add endinanness helpers

2013-06-25 Thread Vicent Martí
On Tue, Jun 25, 2013 at 3:08 PM, Peter Krefting wrote: > endian(3) claims that glibc 2.9+ define be64toh() and htobe64() which should > do what you are looking for. The manual page does mention them being named > differently across OSes, though, so you may need to be careful with that. I'm aware

Re: [PATCH 07/16] compat: add endinanness helpers

2013-06-25 Thread Peter Krefting
Vicent Marti: The POSIX standard doesn't currently define a `nothll`/`htonll` function pair to perform network-to-host and host-to-network swaps of 64-bit data. These 64-bit swaps are necessary for the on-disk storage of EWAH bitmaps if they are not in native byte order. endian(3) claims tha

Re: [PATCH 10/16] pack-objects: use bitmaps when packing objects

2013-06-25 Thread Ramkumar Ramachandra
Vicent Marti wrote: > $ time ../git/git pack-objects --all --stdout > Counting objects: 3053537, done. > Compressing objects: 100% (495706/495706), done. > Total 3053537 (delta 2529614), reused 3053537 (delta 2529614) > > real0m36.686s > user0

Re: [PATCH v14 05/16] Refactor write_name_quoted_relative, remove unused params

2013-06-25 Thread Jiang Xin
2013/6/25 Junio C Hamano : > Jiang Xin writes: > >> -static void write_name(const char* name, size_t len) >> +static void write_name(const char *name) >> { >> - write_name_quoted_relative(name, len, prefix, prefix_len, stdout, >> - line_terminator); >> + >> + /* turn o

Re: [PATCH v14 04/16] Refactor quote_path_relative, remove unused params

2013-06-25 Thread Jiang Xin
2013/6/25 Junio C Hamano : > Jiang Xin writes: > >> After substitute path_relative() in quote.c with relative_path() from >> path.c, parameters (such as len and prefix_len) are obsolete in function >> quote_path_relative(). Remove unused parameters and change the order of >> parameters for quote_p

Re: [PATCH v14 03/16] quote.c: remove path_relative, use relative_path instead

2013-06-25 Thread Jiang Xin
2013/6/25 Junio C Hamano : > Jiang Xin writes: > >> Since there is an enhanced version of relative_path() in path.c, >> remove duplicate counterpart path_relative() in quote.c. > > There is no nice comparison chart before and after like you had in > patch 02/16? > You mean drawing a table to comp

Re: [PATCH v2 13/14] t/t5515-fetch-merge-logic: don't use {branches,remotes}-file

2013-06-25 Thread Ramkumar Ramachandra
Santi Béjar wrote: > If you think it's not worth testing the merge logic with remotes in > {branches,remotes}-files you can consider just removing these remotes and > the associated result files. Thanks, but Junio has already decided to keep them and dropped these patches. -- To unsubscribe from t

[PATCH v6 1/5] t6006 (rev-list-format): don't hardcode SHA-1 in expected outputs

2013-06-25 Thread Alexey Shumkin
The expected SHA-1 digests are always available in variables. Use them instead of hardcoding. Signed-off-by: Alexey Shumkin --- t/t6006-rev-list-format.sh | 140 + 1 file changed, 77 insertions(+), 63 deletions(-) diff --git a/t/t6006-rev-list-format.

[PATCH v6 3/5] t4205 (log-pretty-formats): don't hardcode SHA-1 in expected outputs

2013-06-25 Thread Alexey Shumkin
The expected SHA-1 digests are always available in variables. Use them instead of hardcoding. Signed-off-by: Alexey Shumkin --- t/t4205-log-pretty-formats.sh | 48 +++ 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/t/t4205-log-pretty-forma

[PATCH v6 4/5] pretty: Add failing tests: --format output should honor logOutputEncoding

2013-06-25 Thread Alexey Shumkin
One can set an alias $ git config alias.lg "log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cd) %C(bold blue)<%an>%Creset' --abbrev-commit --date=local" to see the log as a pretty tree (like *gitk* but in a terminal). However, log messages writ

[PATCH v6 0/5] Reroll patches against v1.8.3.1

2013-06-25 Thread Alexey Shumkin
It's all started here [http://thread.gmane.org/gmane.comp.version-control.git/177634] and recently continued later [http://thread.gmane.org/gmane.comp.version-control.git/214419] v6 of this patch series includes Junio's suggestions against v5: 1. [PATCH v6 1/5] t6006 (rev-list-format): don't ha

[PATCH v6 5/5] pretty: --format output should honor logOutputEncoding

2013-06-25 Thread Alexey Shumkin
One can set an alias $ git config [--global] alias.lg "log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cd) %C(bold blue)<%an>%Creset' --abbrev-commit --date=local" to see the log as a pretty tree (like *gitk* but in a terminal). However, log m

[PATCH v6 2/5] t7102 (reset): don't hardcode SHA-1 in expected outputs

2013-06-25 Thread Alexey Shumkin
The expected SHA-1 digests are always available in variables. Use them instead of hardcoding. Signed-off-by: Alexey Shumkin --- t/t7102-reset.sh | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/t/t7102-reset.sh b/t/t7102-reset.sh index df82ec9..05dfb27 100755 --- a/t/t

Re: Another core.safecrlf behavor with git diff/git status

2013-06-25 Thread Yann Droneaud
Hi, Le 24.06.2013 18:55, Junio C Hamano a écrit : Yann Droneaud writes: - Why git diff does not always report the CRLF/LF mismatch ? Most likely because you are telling safecrlf not to error out but just warn, and then you are not fixing the cause of the warning? So diff would say "Ok, you

Re: Splitting a rev list into 2 sets

2013-06-25 Thread Francis Moreau
Hello Thomas, On Mon, Jun 24, 2013 at 11:59 AM, Thomas Rast wrote: > Francis Moreau writes: > >> On Thu, Jun 20, 2013 at 3:20 PM, Thomas Rast wrote: >>> positive=$(git rev-parse "$@" | grep -v '^\^') >>> negative=$(git rev-parse "$@" | grep '^\^') >>> boundary=$(git rev-list --boundary $p

Re: [PATCH v14 01/16] test: add test cases for relative_path

2013-06-25 Thread Jiang Xin
2013/6/25 Junio C Hamano : >> Add prefix _ to workaround the absolute path rewritten issue in >> msysGit is interesting, but these test cases have already been >> tested in Linux, right? > > The most important thing is what we want to test in these tests. > The special test program is to try runnin