Merge branch 'master' into next

* master:
  add: introduce add.ignoreerrors synonym for add.ignore-errors
  commit.c: Remove backward goto in read_craft_line()
  bash: Match lightweight tags in prompt
  git-commit.txt: (synopsis): move -i and -o before "--"

Conflicts:
	Documentation/git-commit.txt
This commit is contained in:
Junio C Hamano
2010-12-01 16:42:22 -08:00
5 changed files with 16 additions and 10 deletions

View File

@@ -563,9 +563,13 @@ core.sparseCheckout::
linkgit:git-read-tree[1] for more information.
add.ignore-errors::
add.ignoreErrors::
Tells 'git add' to continue adding files when some files cannot be
added due to indexing errors. Equivalent to the '--ignore-errors'
option of linkgit:git-add[1].
option of linkgit:git-add[1]. Older versions of git accept only
`add.ignore-errors`, which does not follow the usual naming
convention for configuration variables. Newer versions of git
honor `add.ignoreErrors` as well.
alias.*::
Command aliases for the linkgit:git[1] command wrapper - e.g.

View File

@@ -12,7 +12,7 @@ SYNOPSIS
[(-c | -C | --fixup | --squash) <commit>] [-F <file> | -m <msg>]
[--reset-author] [--allow-empty] [--allow-empty-message] [--no-verify]
[-e] [--author=<author>] [--date=<date>] [--cleanup=<mode>]
[--status | --no-status] [--] [[-i | -o ]<file>...]
[--status | --no-status] [-i | -o] [--] [<file>...]
DESCRIPTION
-----------

View File

@@ -331,7 +331,8 @@ static struct option builtin_add_options[] = {
static int add_config(const char *var, const char *value, void *cb)
{
if (!strcasecmp(var, "add.ignore-errors")) {
if (!strcasecmp(var, "add.ignoreerrors") ||
!strcasecmp(var, "add.ignore-errors")) {
ignore_add_errors = git_config_bool(var, value);
return 0;
}

View File

@@ -150,12 +150,8 @@ struct commit_graft *read_graft_line(char *buf, int len)
buf[--len] = '\0';
if (buf[0] == '#' || buf[0] == '\0')
return NULL;
if ((len + 1) % 41) {
bad_graft_data:
error("bad graft data: %s", buf);
free(graft);
return NULL;
}
if ((len + 1) % 41)
goto bad_graft_data;
i = (len + 1) / 41 - 1;
graft = xmalloc(sizeof(*graft) + 20 * i);
graft->nr_parent = i;
@@ -168,6 +164,11 @@ struct commit_graft *read_graft_line(char *buf, int len)
goto bad_graft_data;
}
return graft;
bad_graft_data:
error("bad graft data: %s", buf);
free(graft);
return NULL;
}
static int read_graft_file(const char *graft_file)

View File

@@ -261,7 +261,7 @@ __git_ps1 ()
(describe)
git describe HEAD ;;
(* | default)
git describe --exact-match HEAD ;;
git describe --tags --exact-match HEAD ;;
esac 2>/dev/null)" ||
b="$(cut -c1-7 "$g/HEAD" 2>/dev/null)..." ||