push: cleanup push rules comment

Rewrite to remove inter-dependencies amongst the rules.

Signed-off-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
push: rename config variable for more general use

The 'pushNonFastForward' advice config can be used to squelch several
instances of push-related advice.  Rename it to 'pushUpdateRejected' to
cover other reject scenarios that are unrelated to fast-forwarding.
Retain the old name for compatibility.

Signed-off-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
push: allow already-exists advice to be disabled

Add 'advice.pushAlreadyExists' option to disable the advice shown when
an update is rejected for a reference that is not allowed to update at
all (verses those that are allowed to fast-forward.)

Signed-off-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Merge branch 'jc/apply-trailing-blank-removal' into jch

Fix to update_pre_post_images() that did not take into account the
possibility that whitespace fix could shrink the preimage and
change the number of lines in it.

Will cook in 'next'.

* jc/apply-trailing-blank-removal:
  apply.c:update_pre_post_images(): the preimage can be truncated
Merge branch 'mh/ceiling' into jch

Elements of GIT_CEILING_DIRECTORIES list may not match the real
pathname we obtain from getcwd(), leading the GIT_DIR discovery
logic to escape the ceilings the user thought to have specified.

Resurrected from Stalled; the earlier performance fear was
unwarranted.

Will cook in 'next'.

* mh/ceiling:
  string_list_longest_prefix(): remove function
  setup_git_directory_gently_1(): resolve symlinks in ceiling paths
  longest_ancestor_length(): require prefix list entries to be normalized
  longest_ancestor_length(): take a string_list argument for prefixes
  longest_ancestor_length(): use string_list_split()
  Introduce new function real_path_if_valid()
  real_path_internal(): add comment explaining use of cwd
  Introduce new static function real_path_internal()

Conflicts:
	Documentation/technical/api-string-list.txt
	string-list.c
	string-list.h
Merge branch 'nd/wildmatch' into jch

Allows pathname patterns in .gitignore and .gitattributes files
with double-asterisks "foo/**/bar" to match any number of directory
hierarchies.

I suspect that this needs to be plugged to pathspec matching code;
otherwise "git log -- 'Docum*/**/*.txt'" would not show the log for
commits that touch Documentation/git.txt, which would be confusing
to the users.

Will cook in 'next'.

* nd/wildmatch:
  test-wildmatch: avoid Windows path mangling
  Support "**" wildcard in .gitignore and .gitattributes
  wildmatch: make /**/ match zero or more directories
  wildmatch: adjust "**" behavior
  wildmatch: fix case-insensitive matching
  wildmatch: remove static variable force_lower_case
  wildmatch: make wildmatch's return value compatible with fnmatch
  t3070: disable unreliable fnmatch tests
  Integrate wildmatch to git
  wildmatch: follow Git's coding convention
  wildmatch: remove unnecessary functions
  Import wildmatch from rsync
  ctype: support iscntrl, ispunct, isxdigit and isprint
  ctype: make sane_ctype[] const array

Conflicts:
	Makefile
Merge branch 'rc/maint-complete-git-p4' into jch

Comment from Pete will need to be addressed in a follow-up patch.

* rc/maint-complete-git-p4:
  Teach git-completion about git p4
Merge branch 'mh/pthreads-autoconf' into jch

Will cook in 'next'.

* mh/pthreads-autoconf:
  configure.ac: fix pthreads detection on Mac OS X
Merge branch 'jk/fsck-dot-in-trees' into jch

Will cook in 'next'.

* jk/fsck-dot-in-trees:
  fsck: warn about ".git" in trees
  fsck: warn about '.' and '..' in trees
Merge branch 'jn/warn-on-inaccessible-loosen' into jch

An RFC to deal with a situation where .config/git is a file and we
notice .config/git/config is not readable due to ENOTDIR, not
ENOENT.

Will cook in 'next'.

* jn/warn-on-inaccessible-loosen:
  config: exit on error accessing any config file
  doc: advertise GIT_CONFIG_NOSYSTEM
  config: treat user and xdg config permission problems as errors
  config, gitignore: failure to access with ENOTDIR is ok
Merge branch 'nd/pathspec-wildcard' into jch

Will merge to 'next'.

* nd/pathspec-wildcard:
  tree_entry_interesting: do basedir compare on wildcard patterns when possible
  pathspec: apply "*.c" optimization from exclude
  pathspec: do exact comparison on the leading non-wildcard part
  pathspec: save the non-wildcard length part
Merge branch 'mh/unify-xml-in-imap-send-and-http-push' into jch

Will merge to 'next'.

* mh/unify-xml-in-imap-send-and-http-push:
  wrap_in_html(): process message in bulk rather than line-by-line
  wrap_in_html(): use strbuf_addstr_xml_quoted()
  imap-send: change msg_data from storing (ptr, len) to storing strbuf
  imap-send: correctly report errors reading from stdin
  imap-send: store all_msgs as a strbuf
  lf_to_crlf(): NUL-terminate msg_data::data
  xml_entities(): use function strbuf_addstr_xml_quoted()
  Add new function strbuf_add_xml_quoted()
Merge branch 'fc/fast-export-fixes' into jch

Will merge to (and cook in) 'next'.

* fc/fast-export-fixes:
  fast-export: make sure updated refs get updated
  fast-export: don't handle uninteresting refs
  fast-export: fix comparison in tests
  fast-export: trivial cleanup
  remote-testgit: implement the "done" feature manually
  remote-testgit: report success after an import
  remote-testgit: exercise more features
  remote-testgit: cleanup tests
  remote-testgit: remove irrelevant test
  remote-testgit: remove non-local functionality
  Add new simplified git-remote-testgit
  Rename git-remote-testgit to git-remote-testpy
  remote-helpers: fix failure message
  remote-testgit: fix direction of marks
  fast-export: avoid importing blob marks
Merge branch 'bc/append-signed-off-by' into jch

Expecting a re-roll after a review.

* bc/append-signed-off-by:
  Unify appending signoff in format-patch, commit and sequencer
  format-patch: update append_signoff prototype
  format-patch: stricter S-o-b detection
  t4014: more tests about appending s-o-b lines
  sequencer.c: teach append_signoff to avoid adding a duplicate newline
  sequencer.c: teach append_signoff how to detect duplicate s-o-b
  sequencer.c: always separate "(cherry picked from" from commit body
  sequencer.c: recognize "(cherry picked from ..." as part of s-o-b footer
  t/t3511: add some tests of 'cherry-pick -s' functionality
  t/test-lib-functions.sh: allow to specify the tag name to test_commit
  sequencer.c: remove broken support for rfc2822 continuation in footer
Merge branch 'mh/doc-remote-helpers' into jch

Need comment and Ack from people who have worked on remote-helpers
before this goes forward.

* mh/doc-remote-helpers:
  git-remote-helpers.txt: clarify options & ref list attributes
  git-remote-helpers.txt: clarify command <-> capability correspondences
  git-remote-helpers.txt: rearrange description of capabilities
  git-remote-helpers.txt: minor grammar fix
  git-remote-helpers.txt: document missing capabilities
  git-remote-helpers.txt: document invocation before input format
Merge branch 'aw/rebase-am-failure-detection' into jch

I am unhappy a bit about the possible performance implications of
having to store the output in a temporary file only for a rare case
of format-patch aborting.

* aw/rebase-am-failure-detection:
  rebase: Handle cases where format-patch fails
Merge branch 'cr/push-force-tag-update' into jch

Require "-f" for push to update a tag, even if it is a fast-forward.

With a minor tweak, I think this is getting ready for 'next'.
Expecting a re-roll.

* cr/push-force-tag-update:
  push: allow already-exists advice to be disabled
  push: rename config variable for more general use
  push: cleanup push rules comment
  push: clarify rejection of update to non-commit-ish
  push: require force for annotated tags
  push: require force for refs under refs/tags/
  push: flag updates that require force
  push: keep track of "update" state separately
  push: add advice for rejected tag reference
  push: return reject reasons as a bitset
Merge branch 'rr/t4041-cleanup' into jch

As a clean-up, it still misses some.
Expecting a re-roll.

* rr/t4041-cleanup:
  t4041 (diff-submodule-option): modernize style
  t4041 (diff-submodule-option): rewrite add_file() routine
  t4041 (diff-submodule-option): parse digests sensibly
  t4041 (diff-submodule-option): don't hardcode SHA-1 in expected outputs
Merge branch 'pf/editor-ignore-sigint' into jch

Avoid confusing cases where the user hits Ctrl-C while in the editor
session, not realizing git will receive the signal. Since most editors
will take over the terminal and will block SIGINT, this is not likely
to confuse anyone.

Some people raised issues with emacsclient, which are addressed by this
re-roll. It should probably also handle SIGQUIT, and there were a
handful of other review comments.

Expecting a re-roll.

* pf/editor-ignore-sigint:
  launch_editor: propagate signals from editor to git
  run-command: do not warn about child death from terminal
  launch_editor: ignore terminal signals while editor has control
  launch_editor: refactor to use start/finish_command
  run-command: drop silent_exec_failure arg from wait_or_whine
Merge branch 'mk/maint-graph-infinity-loop' into pu

The --graph code fell into infinite loop when asked to do what the
code did not expect ;-)

Anybody who worked on "--graph" wants to comment?
Stalled mostly due to lack of responses.

* mk/maint-graph-infinity-loop:
  graph.c: infinite loop in git whatchanged --graph -m