Hi Pranit,
On Sat, 14 May 2016, Pranit Bauva wrote:
> Reimplement the `bisect_voc` shell function in C. This is a too small
> function to be called as a subcommand though the working of this
> function has been tested by calling it as a subcommand.
This leaves me puzzled as to what this patch is
On Sun, May 15, 2016 at 7:07 PM, Vasily Titskiy wrote:
> Do not save states of submodules as stash should ignore it.
Can you explain why this is a good idea?
(It is not obvious to me either way.)
Do we need a test/documentation updates for this?
>
> Signed-off-by: Vasily Titskiy
> ---
> git-s
Hi Junio,
On Fri, 13 May 2016, Junio C Hamano wrote:
> Johannes Schindelin writes:
>
> > On Thu, 12 May 2016, Junio C Hamano wrote:
> >
> >> I took these separately already, and plan to fast-track them as they
> >> are both "trivially correct"; I double checked that what I have match
> >> these
Hi Junio,
On Sun, 15 May 2016, Junio C Hamano wrote:
> diff --git a/commit.c b/commit.c
> index 3f4f371..1f9ee8a 100644
> --- a/commit.c
> +++ b/commit.c
> @@ -415,8 +415,7 @@ int find_commit_subject(const char *commit_buffer, const
> char **subject)
> p++;
> if (*p) {
>
On Sun, May 15, 2016 at 8:31 PM, Eric Sunshine wrote:
> On Sun, May 15, 2016 at 6:57 PM, Junio C Hamano wrote:
>> The double-loop wants to do an early return immediately when one
>> matching macro is found. Eliminate the extra variable 'a' used for
>> that purpose and rewrite the "assign found i
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To finish libifying the apply functionality, apply_all_patches() should not
> die() or exit() in case of error, but return -1.
>
> While doing that we must take care that file descriptors are properly closed
> and, if needed, reset a sensi
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To libify `git apply` functionality we have to signal errors to the
> caller instead of exit()ing.
>
> To do that in a compatible manner with the rest of the error handling
> in "builtin/apply.c", init_apply_state() should return -1 using
On Sun, May 15, 2016 at 6:57 PM, Junio C Hamano wrote:
> The double-loop wants to do an early return immediately when one
> matching macro is found. Eliminate the extra variable 'a' used for
> that purpose and rewrite the "assign found itme to 'a' to make it
What's "itme"?
> non-NULL and force
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To libify `git apply` functionality we must make init_apply_state()
> usable outside "builtin/apply.c".
>
> Let's do that by moving it into a new "apply.c".
Similar to my comment about apply.h and 'struct apply_state', I can
easily see ap
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To libify `git apply` functionality we must make 'struct apply_state'
> usable outside "builtin/apply.c".
Why is this patch plopped right in the middle of a bunch of other
patches which are making functions return -1 rather than die()ing?
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To libify `git apply` functionality we have to signal errors to the
> caller instead of die()ing or exit()ing.
>
> To do that in a compatible manner with the rest of the error handling
> in builtin/apply.c, find_header() should return -1 i
Do not save states of submodules as stash should ignore it.
Signed-off-by: Vasily Titskiy
---
git-stash.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/git-stash.sh b/git-stash.sh
index c7c65e2..b500c44 100755
--- a/git-stash.sh
+++ b/git-stash.sh
@@ -116,7 +116,7 @@ creat
On Wed, May 11, 2016 at 9:17 AM, Christian Couder
wrote:
> To libify `git apply` functionality we have to signal errors to the
> caller instead of die()ing. Let's do that by using error() instead
> of die()ing in read_patch_file().
>
> Signed-off-by: Christian Couder
> ---
> diff --git a/builtin/
On Sun, May 15, 2016 at 08:51:53PM -0400, Chris B wrote:
> I did not see in your example any commit. But if you say so.
I didn't show the commit step. But you can see that I made two identical
pushes, one quiet and one not, and the non-quiet one actually pushed
commits and showed the progress met
I did not see in your example any commit. But if you say so.
I saw git init which would be a new repo.. don't know if it makes a difference.
It's pushing to HTTPS.
I can provide the real example tomorrow.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message t
On Tue, May 10, 2016 at 10:17 AM, Nguyễn Thái Ngọc Duy
wrote:
> Signed-off-by: Nguyễn Thái Ngọc Duy
> ---
> diff --git a/builtin/worktree.c b/builtin/worktree.c
> @@ -498,6 +499,34 @@ static int lock_worktree(int ac, const char **av, const
> char *prefix)
> +static int unlock_worktree(int ac, co
On Tue, May 10, 2016 at 10:17 AM, Nguyễn Thái Ngọc Duy
wrote:
> +static int lock_worktree(int ac, const char **av, const char *prefix)
> +{
> + const char *reason = "", *old_reason;
> + struct option options[] = {
> + OPT_STRING(0, "reason", &reason, N_("string"),
> +
On Sun, May 8, 2016 at 9:34 AM, Pranit Bauva wrote:
> On Sun, May 8, 2016 at 11:53 AM, Pranit Bauva wrote:
>> On Sun, May 8, 2016 at 7:55 AM, Junio C Hamano wrote:
>>> Pranit Bauva writes:
I completely missed your point and you want me to go the Eric Sunshine's
way?
>>>
>>> I am neut
On Tue, May 10, 2016 at 10:17 AM, Nguyễn Thái Ngọc Duy
wrote:
> Signed-off-by: Nguyễn Thái Ngọc Duy
> ---
> diff --git a/Documentation/git-worktree.txt b/Documentation/git-worktree.txt
> @@ -11,6 +11,7 @@ SYNOPSIS
> [verse]
> 'git worktree add' [-f] [--detach] [--checkout] [-b ]
> []
> 'git
Currently, get_host_and_port() is called in git_connect() for the ssh
protocol, and in git_tcp_connect_sock() for the git protocol. Instead
of doing this, just call it from a single place, right after
parse_connect_url(), and pass the host and port separately to
git_*_connect() functions.
We howev
Currently, urls of the for git://user@host don't work because user@host
is not resolving at the DNS level, but we shouldn't be relying on it
being an invalid host name, and actively reject it for containing a
username in the first place.
Signed-off-by: Mike Hommey
---
connect.c | 3 +++
1 file c
I removed the two controvertial patches, and applied the various suggestions
from the last cycle.
Mike Hommey (9):
connect: call get_host_and_port() earlier
connect: only match the host with core.gitProxy
connect: fill the host header in the git protocol with the host and
port variables
The last use of the hostandport variable, besides being strdup'ed before
being split into host and port, is to fill the host header in the git
protocol.
Instead of relying on parse_connect_url() to return a host:port string
that makes sense there, construct one from the host and port variables.
S
Now that nothing besides CONNECT_DIAG_URL is using hostandport, we can
have parse_connect_url() itself do the host and port splitting.
This still leaves "user@" part of the host, if there is one, which will
be addressed in a subsequent change. This however does add /some/
handling of the "user@" p
Signed-off-by: Mike Hommey
---
connect.c | 33 +
1 file changed, 25 insertions(+), 8 deletions(-)
diff --git a/connect.c b/connect.c
index 8813f90..c40ff35 100644
--- a/connect.c
+++ b/connect.c
@@ -588,11 +588,13 @@ static char *get_port(char *host)
* Extract p
Previous changes made both branches handling CONNECT_DIAG_URL identical.
We can now remove one of those branches and have CONNECT_DIAG_URL be
handled in one place.
Signed-off-by: Mike Hommey
---
connect.c | 16 +---
1 file changed, 1 insertion(+), 15 deletions(-)
diff --git a/connec
Signed-off-by: Mike Hommey
---
connect.c | 108 +-
1 file changed, 58 insertions(+), 50 deletions(-)
diff --git a/connect.c b/connect.c
index fdd40b0..ae9ef7b 100644
--- a/connect.c
+++ b/connect.c
@@ -673,6 +673,61 @@ static enum proto
Signed-off-by: Mike Hommey
---
connect.c | 6 ++
t/t5500-fetch-pack.sh | 14 --
2 files changed, 14 insertions(+), 6 deletions(-)
diff --git a/connect.c b/connect.c
index c40ff35..df15ff3 100644
--- a/connect.c
+++ b/connect.c
@@ -703,10 +703,8 @@ struct child_proces
Currently, core.gitProxy doesn't actually match purely on domain names
as documented: it also matches ports.
So a core.gitProxy value like "script for kernel.org" doesn't make the
script called for an url like git://kernel.org:port/path, while it is
called for git://kernel.org/path.
This per-port
On Mon, May 16, 2016 at 2:33 AM, Junio C Hamano wrote:
> Junio C Hamano writes:
>
>> Duy Nguyen writes:
>>
>>> Instead of putting everything in under the same attribute name
>>> "label", make one attribute per label? Would this work?
>>>
>>> *.[ch] c-group code-group
>>
>> The attribute subsyste
When 82dce998 (attr: more matching optimizations from .gitignore,
2012-10-15) changed a pointer to a string "*pattern" into an
embedded "struct pattern" in struct match_attr, it forgot to update
the comment that describes the structure.
Signed-off-by: Junio C Hamano
---
attr.c | 5 ++---
1 file
Signed-off-by: Junio C Hamano
---
attr.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/attr.c b/attr.c
index 94b27f4..aac5c8f 100644
--- a/attr.c
+++ b/attr.c
@@ -183,6 +183,12 @@ static const char *parse_attr(const char *src, int lineno,
const char *cp,
retu
Signed-off-by: Junio C Hamano
---
attr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/attr.c b/attr.c
index aac5c8f..a19946a 100644
--- a/attr.c
+++ b/attr.c
@@ -300,7 +300,7 @@ static struct match_attr *parse_attr_line(const char *line,
const char *src,
* directory (ag
The double-loop wants to do an early return immediately when one
matching macro is found. Eliminate the extra variable 'a' used for
that purpose and rewrite the "assign found itme to 'a' to make it
non-NULL and force the loop(s) to terminate" with a direct return
from there.
Signed-off-by: Junio
Signed-off-by: Junio C Hamano
---
attr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/attr.c b/attr.c
index a7f2c3f..95416d3 100644
--- a/attr.c
+++ b/attr.c
@@ -469,7 +469,7 @@ static void debug_set(const char *what, const char *match,
struct git_attr *attr
#define debu
Signed-off-by: Junio C Hamano
---
attr.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/attr.c b/attr.c
index a19946a..a7f2c3f 100644
--- a/attr.c
+++ b/attr.c
@@ -407,8 +407,8 @@ static struct attr_stack *read_attr_from_index(const char
*path, int macro_ok)
for
Signed-off-by: Junio C Hamano
---
commit.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/commit.c b/commit.c
index 3f4f371..1f9ee8a 100644
--- a/commit.c
+++ b/commit.c
@@ -415,8 +415,7 @@ int find_commit_subject(const char *commit_buffer, const
char **subject)
tbo...@web.de writes:
> -static int has_cr_in_index(const char *path)
> +static int has_cr_in_index(const char *path, const unsigned char *sha1)
> {
> unsigned long sz;
> void *data;
> int has_cr;
> -
> - data = read_blob_data_from_cache(path, &sz);
> - if (!data)
> +
On Sun, May 15, 2016 at 04:29:36PM -0400, Chris B wrote:
> Try it by making some changes to files and committing them, and then push.
> It works fine for me when there is nothing to actually push, but not
> so when there are commits to push.
In my example there were commits to push.
As you noted
Hello Git community,
We're a group of french students from Grenoble INP - Ensimag.
As part of an academic project, mentored by Matthieu Moy,
we chose to spend the four next weeks contributing to Git.
We're now picking ideas in order to help the community the most
effective way and we're eager to
Hello Git community,
We're a group of french students from Grenoble INP - Ensimag.
As part of an academic project, mentored by Matthieu Moy,
we chose to spend the four next weeks contributing to Git.
We're now picking ideas in order to help the community the most
effective way and we're eager to
On 05/15/2016 09:43 PM, Junio C Hamano wrote:
I think the paragraph is shared among the "diff" family of
commands both plumbing and Porcelain, so I'd say "patches welcome"
at this point ;-).
I think I've done my part here. It's not like this is a feature request.
The script was an illustrati
By the way, I also notice by your prompt you seem to be testing this
in Linux. I did indicate I'm using the Windows version. That might
make a difference.
On Sun, May 15, 2016 at 4:29 PM, Chris B wrote:
> Try it by making some changes to files and committing them, and then push.
> It works fine
Try it by making some changes to files and committing them, and then push.
It works fine for me when there is nothing to actually push, but not
so when there are commits to push.
It always outputs the progress to STDERR even when I add --quiet.
On Fri, May 13, 2016 at 6:33 PM, Jeff King wrote:
Junio C Hamano writes:
> Duy Nguyen writes:
>
>> Instead of putting everything in under the same attribute name
>> "label", make one attribute per label? Would this work?
>>
>> *.[ch] c-group code-group
>
> The attribute subsystem expects that there will not be unbounded
> large number of attrib
Hey Junio,
On Mon, May 16, 2016 at 12:41 AM, Junio C Hamano wrote:
> Pranit Bauva writes:
>
>>is available for testing on the pu branch. I am encouraging people to
>>test it and provide useful comments.
>
> Do not encourage people to "TEST". In general, do not put too much
> weight on t
Matthieu Moy writes:
> Pranit Bauva writes:
>
>> = SUMMARY ==
>> My micro project on adding config variable to git-commit for verbose options
>> is going to be merged with the master branch soon and will be available for
>> git 2.8.
Pranit Bauva writes:
>is available for testing on the pu branch. I am encouraging people to
>test it and provide useful comments.
Do not encourage people to "TEST". In general, do not put too much
weight on testing. The result would only measure a small portion of
what you wrote in the
Torsten Bögershausen writes:
> Nja, (Or Nyes in English), the old handling tried to be "nice" to the user:
> $ git add text # gave warning
> #User forgets, does other things, git reset HEAD
> $ git commit # Gave the warning one more time, to remind the user,
> # what he did, and
Dmitry Gutov writes:
> OK, that makes sense. You might want to fix the man page, though, it
> says, like the 'git diff' one, "For instance, if you configured
> diff.algorithm variable to a non-default value and want to use the
> default one, then you have to use --diff-algorithm=default option.".
Christian Couder writes:
> On Sat, May 14, 2016 at 8:31 PM, Junio C Hamano wrote:
>>
>> I however do not see a reason why you need to expose that feature to
>> the users of "git apply". So I am not sure if any of us care deeply
>> the choice among --silent, --quiet and -q -q.
>
> About that I w
Duy Nguyen writes:
> Instead of putting everything in under the same attribute name
> "label", make one attribute per label? Would this work?
>
> *.[ch] c-group code-group
The attribute subsystem expects that there will not be unbounded
large number of attributes, so this is not a good direction
Pranit Bauva writes:
> = SUMMARY ==
> My micro project on adding config variable to git-commit for verbose options
> is going to be merged with the master branch soon and will be available for
> git 2.8.3 .
Nit: being merged to mast
= SUMMARY ==
My micro project on adding config variable to git-commit for verbose options
is going to be merged with the master branch soon and will be available for
git 2.8.3 . I also rewrote a few shell functions in C.
My public git
With a certain topology involving an octopus merge, git log --graph
--oneline --all --color=never produces output which includes some ANSI
escape code coloring. Attached is a script to reproduce the problem
(creates a git repository in subdir log-format-test), along with
sample graph and valgrind o
From: Torsten Bögershausen
Factor out the retrieval of the sha1 for a given path in
read_blob_data_from_index() into the function get_sha1_from_index().
This will be used in the next commit, when convert.c can do the
analyze for "text=auto" without slurping the whole blob into memory
at once.
A
From: Torsten Bögershausen
To compare a file in working tree with the index, convert_to_git() is used,
the the result is hashed and the hash value compared with ce->sha1.
Deep down would_convert_crlf_at_commit() is invoked, to check if CRLF
are converted or not: When a CRLF had been in the index
From: Torsten Bögershausen
t6038 uses different code, dependig if NATIVE_CRLF is set ot not.
When the native line endings are LF, merge.renormalize is not tested very well.
Change the test to always use CRLF by setting core.eol=crlf.
---
t/t6038-merge-text-auto.sh | 37 +++---
From: Torsten Bögershausen
Changes since v1:
- Re-order the patches
- t6038; use crlf on all platforms
This did actually not break anything (without old 7/10)
Adapt the commit message
- ce_compare_data():
Simplify the logic around free() in has_cr_in_index(),
Thanks Eric Sun
Implement the '--format' option provided by 'ref-filter'. This lets the
user list branches as per desired format similar to the implementation
in 'git for-each-ref'.
Add tests and documentation for the same.
Mentored-by: Christian Couder
Mentored-by: Matthieu Moy
Signed-off-by: Karthik Nayak
-
Port branch.c to use ref-filter APIs for printing. This clears out
most of the code used in branch.c for printing and replaces them with
calls made to the ref-filter library.
Introduce build_format() which gets the format required for printing
of refs. Make amendments to print_ref_list() to reflec
Add the options `:dir` and `:base` to all ref printing ('%(refname)',
'%(symref)', '%(push)' and '%(upstream)') atoms. The `:dir` option gives
the directory (the part after $GIT_DIR/) of the ref without the
refname. The `:base` option gives the base directory of the given
ref (i.e. the directory fo
Since there are multiple atoms which print refs ('%(refname)',
'%(symref)', '%(push)', '%upstream'), it makes sense to have a common
ground for parsing them. This would allow us to share implementations of
the atom modifiers between these atoms.
Introduce refname_atom_parser_internal() to act as a
Introduce setup_ref_filter_porcelain_msg() so that the messages used in
the atom %(upstream:track) can be translated if needed. This is needed
as we port branch.c to use ref-filter's printing API's.
Written-by: Matthieu Moy
Mentored-by: Christian Couder
Mentored-by: Matthieu Moy
Signed-off-by:
Use the recently introduced refname_atom_parser_internal() within
remote_ref_atom_parser(), this provides a common base for all the ref
printing atoms, allowing %(upstream) and %(push) to also use the
':strip' option.
The atoms '%(push)' and '%(upstream)' will retain the ':track' and
':trackshort'
The "%(symref)" atom doesn't work when used with the ':short' modifier
because we strictly match only 'symref' for setting the 'need_symref'
indicator. Fix this by using comparing with valid_atom rather than used_atom.
Add tests for %(symref) and %(symref:short) while we're here.
Helped-by: Junio
Call ref-filter's setup_ref_filter_porcelain_msg() to enable
translated messages for the %(upstream:tack) atom. Although branch.c
doesn't currently use ref-filter's printing API's, this will ensure
that when it does in the future patches, we do not need to worry about
translation.
Written-by: Matt
Using refname_atom_parser_internal(), introduce symref_atom_parser() and
refname_atom_parser() which will parse the atoms %(symref) and
%(refname) respectively. Store the parsed information into the
'used_atom' structure based on the modifiers used along with the atoms.
Now the '%(symref)' atom su
To allow column display, we will need to first render the output in a
string list to allow print_columns() to compute the proper size of
each column before starting the actual output. Introduce the function
format_ref_array_item() that does the formatting of a ref_array_item
to an strbuf.
show_ref
Add support for %(upstream:track,nobracket) which will print the
tracking information without the brackets (i.e. "ahead N, behind M").
This is needed when we port branch.c to use ref-filter's printing APIs.
Add test and documentation for the same.
Mentored-by: Christian Couder
Mentored-by: Matth
Ensure that each 'atom_value' has a reference to its corresponding
'used_atom'. This let's us use values within 'used_atom' in the
'handler' function.
Hence we can get the %(align) atom's parameters directly from the
'used_atom' therefore removing the necessity of passing %(align) atom's
parameter
Implement %(if), %(then) and %(else) atoms. Used as
%(if)...%(then)...%(end) or %(if)...%(then)...%(else)...%(end). If the
format string between %(if) and %(then) expands to an empty string, or
to only whitespaces, then the whole %(if)...%(end) expands to the string
following %(then). Otherwise, it
Implement %(if:equals=) wherein the if condition is only
satisfied if the value obtained between the %(if:...) and %(then) atom
is the same as the given ''.
Similarly, implement (if:notequals=) wherein the if condition
is only satisfied if the value obtained between the %(if:...) and
%(then) atom
Move the implementation of get_head_description() from branch.c to
ref-filter. This gives a description of the HEAD ref if called. This
is used as the refname for the HEAD ref whenever the
FILTER_REFS_DETACHED_HEAD option is used. Make it public because we
need it to calculate the length of the HE
Borrowing from branch.c's implementation print "[gone]" whenever an
unknown upstream ref is encountered instead of just ignoring it.
This makes sure that when branch.c is ported over to using ref-filter
APIs for printing, this feature is not lost.
Make changes to t/t6300-for-each-ref.sh and
Docum
Add support for %(objectname:short=) which would print the
abbreviated unique objectname of given length. When no length is
specified, the length is 'DEFAULT_ABBREV'. The minimum length is
'MINIMUM_ABBREV'. The length may be exceeded to ensure that the provided
object name is unique.
Add tests and
This is part of unification of the commands 'git tag -l, git branch -l
and git for-each-ref'. This ports over branch.c to use ref-filter's
printing options.
Initially posted here: $(gmane/279226). It was decided that this series
would follow up after refactoring ref-filter parsing mechanism, which
Hi Junio,
On 05/14/2016 09:40 PM, Junio C Hamano wrote:
The variable belongs to UI config, meant for Porcelain "git diff",
together with things like "diff.color", "diff.context", etc.
OK, that makes sense. You might want to fix the man page, though, it
says, like the 'git diff' one, "For ins
On Fri, May 13, 2016 at 7:19 AM, Stefan Beller wrote:
> After some fruitful discussion[1] in which Junio suggested trying a very
> different route[2] that is more general and not submodule related, I
> considered
> doing a mock for this.
>
> This lets you label arbitrary pathspecs, e.g. in git.gi
On Fri, May 13, 2016 at 3:20 AM, David Turner wrote:
> Add a config option to populate the untracked cache.
>
> For installations that have centrally-managed configuration, it's
> easier to set a config once than to run update-index on every
> repository.
This sounds like the job for core.untrack
80 matches
Mail list logo