[PATCH v6 1/2] add: add --ignore-submodules[=when] parameter

2014-04-24 Thread Ronald Weiss
sites are updated to pass NULL. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Git add currently doesn't honor ignore setting from .gitmodules or .git/config, which is related functionality, however I'd like to change that in another patch, coming soon. Patch changelog: v6 * corrected wording

[PATCH v6 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-24 Thread Ronald Weiss
of ignore config. Without it, commit -m --ignore-submodules would not work and tests introduced here would fail. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Patch changelog: v6 * corrected wording and formatting errors (as pointed out by Eric Sunshine) v5 * fixed file mode of added test

[PATCH v5 1/2] add: add --ignore-submodules[=when] parameter

2014-04-22 Thread Ronald Weiss
sites are updated to pass NULL. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Git add currently doesn't honor ignore setting from .gitmodules or .git/config, which is related functionality, however I'd like to change that in another patch, coming soon. Changes against v4 of this patch

[PATCH v5 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-22 Thread Ronald Weiss
of ignore config. Without it, commit -m --ignore-submodules would not work and tests introduced here would fail. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Changes against v4 of this patch: * fixed file mode of added test script (644 - 755) * replaced test_might_fail

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-04-22 Thread Ronald Weiss
On 18. 4. 2014 14:28, Jens Lehmann wrote: Am 13.04.2014 01:41, schrieb Ronald Weiss: Second, there are some differences between adding standard ignored files, and ignored submodules: 1) Already tracked files are never ignored, regardless of .gitignore. However, tracked submodules should

Re: [PATCH v4 1/2] add: add --ignore-submodules[=when] parameter

2014-04-21 Thread Ronald Weiss
On 18. 4. 2014 13:53, Jens Lehmann wrote: Am 13.04.2014 00:45, schrieb Ronald Weiss: Allow ignoring submodules (or not) by command line switch, like diff and status do. Git add currently doesn't honor ignore from .gitmodules or .git/config, which is related functionality, however I'd like

Re: [PATCH v4 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-21 Thread Ronald Weiss
On 18. 4. 2014 14:09, Jens Lehmann wrote: Am 13.04.2014 00:49, schrieb Ronald Weiss: Allow ignoring submodules (or not) by command line switch, like diff and status do. Git commit honors the 'ignore' setting from .gitmodules or .git/config, but didn't allow to override it from command line

Re: [PATCH v3 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-14 Thread Ronald Weiss
On 14. 4. 2014 20:30, Junio C Hamano wrote: Ronald Weiss weiss.ron...@gmail.com writes: On 8. 4. 2014 20:43, Jens Lehmann wrote: Useful when values for commit are 'all' (default) or 'none'. The others ('dirty' and 'untracked') have same effect as 'none', as commit is only interested

Re: [PATCH v3 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-12 Thread Ronald Weiss
On 8. 4. 2014 20:43, Jens Lehmann wrote: Useful when values for commit are 'all' (default) or 'none'. The others ('dirty' and 'untracked') have same effect as 'none', as commit is only interested in whether the submodule's HEAD differs from what is commited in the superproject. Unless it

[PATCH v4 1/2] add: add --ignore-submodules[=when] parameter

2014-04-12 Thread Ronald Weiss
for the next one in series, which adds the --ignore-submodules switch to git commit. That's why signature of function add_files_to_cache was changed. That also requires compilo fixes in checkout.c and commit.c Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Documentation/git-add.txt| 7

[PATCH v4 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-12 Thread Ronald Weiss
of ignore config. Without it, commit -m --ignore-submodules would not work and tests introduced here would fail. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- Documentation/git-commit.txt| 7 builtin/commit.c| 8 +++- t/t7513-commit-ignore-submodules.sh

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-04-12 Thread Ronald Weiss
On 8. 4. 2014 20:26, Jens Lehmann wrote: Am 07.04.2014 23:46, schrieb Ronald Weiss: Then, on top of that, I'll prepare patches for add to honor ignore from .gitmodules, and -f implying --ignore-submodules. That might need more discussion, let's see. Makes sense. I thought more about

Re: [PATCH v3 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-08 Thread Ronald Weiss
On 8. 4. 2014 20:43, Jens Lehmann wrote: Am 08.04.2014 01:03, schrieb Ronald Weiss: Git commit honors the 'ignore' setting from .gitmodules or .git/config, but didn't allow to override it from command line, like other commands do. Useful when values for commit are 'all' (default) or 'none

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-04-07 Thread Ronald Weiss
On 6. 4. 2014 18:28, Jens Lehmann wrote: Am 02.04.2014 21:56, schrieb Ronald Weiss: On 2. 4. 2014 20:53, Jens Lehmann wrote: Am 01.04.2014 23:59, schrieb Ronald Weiss: On 1. 4. 2014 22:23, Jens Lehmann wrote: Am 01.04.2014 01:35, schrieb Ronald Weiss: On 1. 4. 2014 0:50, Ronald Weiss wrote

[PATCH v3 1/2] add: add --ignore-submodules[=when] parameter

2014-04-07 Thread Ronald Weiss
, in particular, coming in subsequent commit). This requires compilo fixes in checkout.c and commit.c Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- I have changed order of commits, from what Jens proposed, to avoid the patch for commit (coming right after this one) having to mess too much

[PATCH v3 2/2] commit: add --ignore-submodules[=when] parameter

2014-04-07 Thread Ronald Weiss
-off-by: Ronald Weiss weiss.ron...@gmail.com --- Documentation/git-commit.txt| 6 ++ builtin/commit.c| 8 ++- t/t7513-commit-ignore-submodules.sh | 42 + 3 files changed, 55 insertions(+), 1 deletion(-) create mode 100644 t

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-04-02 Thread Ronald Weiss
On 2. 4. 2014 20:53, Jens Lehmann wrote: Am 01.04.2014 23:59, schrieb Ronald Weiss: On 1. 4. 2014 22:23, Jens Lehmann wrote: Am 01.04.2014 01:35, schrieb Ronald Weiss: On 1. 4. 2014 0:50, Ronald Weiss wrote: On 31. 3. 2014 23:47, Ronald Weiss wrote: On Mon, Mar 31, 2014 at 8:58 PM, Jens

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-04-01 Thread Ronald Weiss
On 1. 4. 2014 22:23, Jens Lehmann wrote: Am 01.04.2014 01:35, schrieb Ronald Weiss: On 1. 4. 2014 0:50, Ronald Weiss wrote: On 31. 3. 2014 23:47, Ronald Weiss wrote: On Mon, Mar 31, 2014 at 8:58 PM, Jens Lehmann jens.lehm...@web.de wrote: As Junio mentioned it would be great if you could

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-03-31 Thread Ronald Weiss
On Mon, Mar 31, 2014 at 8:58 PM, Jens Lehmann jens.lehm...@web.de wrote: As Junio mentioned it would be great if you could teach the add command also honor the --ignore-submodule command line option in a companion patch. In the course of doing so you'll easily see if I was right or not, then

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-03-31 Thread Ronald Weiss
On 31. 3. 2014 23:47, Ronald Weiss wrote: On Mon, Mar 31, 2014 at 8:58 PM, Jens Lehmann jens.lehm...@web.de wrote: As Junio mentioned it would be great if you could teach the add command also honor the --ignore-submodule command line option in a companion patch. In the course of doing so

Re: [PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-03-31 Thread Ronald Weiss
On 1. 4. 2014 0:50, Ronald Weiss wrote: On 31. 3. 2014 23:47, Ronald Weiss wrote: On Mon, Mar 31, 2014 at 8:58 PM, Jens Lehmann jens.lehm...@web.de wrote: As Junio mentioned it would be great if you could teach the add command also honor the --ignore-submodule command line option

[PATCH v2] commit: add --ignore-submodules[=when] parameter

2014-03-30 Thread Ronald Weiss
interested in whether the submodule's HEAD differs from what is commited in the superproject. Changes in add.c and cache.h (and related compilo fix in checkout.c) are needed to make it work for commit -a too. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- On 30. 3. 2014 21:48, Jens Lehmann wrote

[PATCH v2.1] commit: add --ignore-submodules[=when] parameter

2014-03-30 Thread Ronald Weiss
interested in whether the submodule's HEAD differs from what is commited in the superproject. Changes in add.c and cache.h (and related compilo fix in checkout.c) are needed to make it work for commit -a too. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- The previous patch version (v2

Re: git commit vs. ignore-submodules

2014-03-29 Thread Ronald Weiss
On Fri, Mar 28, 2014 at 5:47 PM, Jens Lehmann jens.lehm...@web.de wrote: Such a patch would be very much appreciated. You might want to look into other commands that already have the --ignore-submodules option to get an idea how to do that. cmd_status() in builtin/commit.c should be a good

[PATCH 2/2] status: don't ignore submodules added to index

2014-03-29 Thread Ronald Weiss
are commited. Unless the changed submodules are the only changes in the index, in such case commit fails immediately with no changes, which is even worse. Signed-off-by: Ronald Weiss weiss.ron...@gmail.com --- wt-status.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git

Re: [PATCH 2/2] status: don't ignore submodules added to index

2014-03-29 Thread Ronald Weiss
On 30. 3. 2014 0:40, Ronald Weiss wrote: That change was really too aggresive, the one below seems better, all tests pass with it, and it still works. Oops, some tests still fail, sorry for my blindness. Nevermind, I'm looking forward to Your fix. -- To unsubscribe from this list: send

git commit vs. ignore-submodules

2014-03-27 Thread Ronald Weiss
, then I'd really appreciate some hints on how to do it. And also, I'd like to know git folks' opinion on whether it's OK that git commit with ignore=all in .gitmodules ignores submodules even when they are explicitely staged with git add. Thanks in advance for any reply, Ronald Weiss