diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-05-16 16:47:10 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-05-16 16:47:10 -0700 |
commit | 7a77754cf6fde7b513da1283fe76179ffa930ecc (patch) | |
tree | 3923485c3d4f775b41c1907dca4cd9bbc4ab3c52 /builtin/add.c | |
parent | 018443526875456d335fef2dfbc78bc4de2d340d (diff) | |
parent | 02a481fc6aef5d8a52f900448657d1cbe7c963ef (diff) | |
download | git-7a77754cf6fde7b513da1283fe76179ffa930ecc.tar.gz git-7a77754cf6fde7b513da1283fe76179ffa930ecc.tar.xz |
Merge branch 'ci/commit--interactive-atomic'
* ci/commit--interactive-atomic:
Test atomic git-commit --interactive
Add commit to list of config.singlekey commands
Add support for -p/--patch to git-commit
Allow git commit --interactive with paths
t7501.8: feed a meaningful command
Use a temporary index for git commit --interactive
Diffstat (limited to 'builtin/add.c')
-rw-r--r-- | builtin/add.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/builtin/add.c b/builtin/add.c index e57abddf5..c59b0c98f 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -242,7 +242,7 @@ int run_add_interactive(const char *revision, const char *patch_mode, return status; } -int interactive_add(int argc, const char **argv, const char *prefix) +int interactive_add(int argc, const char **argv, const char *prefix, int patch) { const char **pathspec = NULL; @@ -253,7 +253,7 @@ int interactive_add(int argc, const char **argv, const char *prefix) } return run_add_interactive(NULL, - patch_interactive ? "--patch" : NULL, + patch ? "--patch" : NULL, pathspec); } @@ -378,7 +378,7 @@ int cmd_add(int argc, const char **argv, const char *prefix) if (patch_interactive) add_interactive = 1; if (add_interactive) - exit(interactive_add(argc - 1, argv + 1, prefix)); + exit(interactive_add(argc - 1, argv + 1, prefix, patch_interactive)); if (edit_interactive) return(edit_patch(argc, argv, prefix)); |