completion: handle path completion and colon for tcsh script

Recent enhancements to git-completion.bash provide intelligent path
completion for git commands.  Such completions do not provide the
'/' at the end of directories for recent versions of bash; instead,
bash itself will add the trailing slash to directories to the result
provided by git-completion.bash.  However, the completion for tcsh
uses the result of the bash completion script directly, so it either
needs to add the necessary slash itself, or needs to ask the bash
script to keep the trailing slash.

Adding the slash itself is difficult because we have to check the
each path in the output of the bash script to see if it is meant to
be a directory or something else.  For example, assuming there is a
directory named 'commit' in the current directory, then, when
completing

  git add commit<tab>

we would need to add a slash, but for

  git help commit<tab>

we should not.

Figuring out such differences would require adding much intelligence
to the tcsh completion script.  Instead, it is simpler to ask the
bash script to keep the trailing slash.  This patch does this.

Also, tcsh does not handle the colon as a completion separator so we
remove it from the list of separators.

Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com>
Merge branch 'jc/remove-treesame-parent-in-simplify-merges' into jch

The --simplify-merges logic did not cull irrelevant parents from a
merge that is otherwise not interesting with respect to the paths
we are following.

This touches a fairly core part of the revision traversal
infrastructure; even though I think this change is correct, please
report immediately if you find any unintended side effect.

* jc/remove-treesame-parent-in-simplify-merges:
  simplify-merges: drop merge from irrelevant side branch

Conflicts:
	revision.c
Merge branch 'ft/transport-report-segv' into jch

A failure to push due to non-ff while on an unborn branch
dereferenced a NULL pointer when showing an error message.

Will merge to 'master'.

* ft/transport-report-segv:
  push: fix segfault when HEAD points nowhere

Conflicts:
	transport.c
Merge branch 'ab/gitweb-use-same-scheme' into jch

Avoid mixed contents on a page coming via http and https when
gitweb is hosted on a https server.

Will merge to 'master'.

* ab/gitweb-use-same-scheme:
  gitweb: refer to picon/gravatar images over the same scheme
Merge branch 'sb/gpg-plug-fd-leak' into jch

We forgot to close the file descriptor reading from "gpg" output,
killing "git log --show-signature" on a long history.

Will merge to 'master'.

* sb/gpg-plug-fd-leak:
  gpg: close stderr once finished with it in verify_signed_buffer()
Merge branch 'sb/gpg-i18n' into jch

Will merge to 'master'.

* sb/gpg-i18n:
  gpg: allow translation of more error messages
Merge branch 'sb/run-command-fd-error-reporting' into jch

Will merge to 'master'.

* sb/run-command-fd-error-reporting:
  run-command: be more informative about what failed
Merge branch 'sp/smart-http-content-type-check' into jch

The smart HTTP clients forgot to verify the content-type that comes
back from the server side to make sure that the request is being
handled properly.

Will merge to 'next'.

* sp/smart-http-content-type-check:
  Verify Content-Type from smart HTTP servers
Merge branch 'jc/fake-ancestor-with-non-blobs' into jch

Rebasing the history of superproject with change in the submodule
has been broken since v1.7.12.

Will merge to 'master'.

* jc/fake-ancestor-with-non-blobs:
  apply: diagnose incomplete submodule object name better
  apply: simplify build_fake_ancestor()
  git-am: record full index line in the patch used while rebasing
Merge branch 'nd/branch-error-cases' into jch

Fix various error messages and conditions in "git branch", e.g. we
advertised "branch -d/-D" to remove one or more branches but actually
implemented removal of zero or more branches---request to remove no
branches was not rejected.

Will merge to 'master'.

* nd/branch-error-cases:
  branch: let branch filters imply --list
  docs: clarify git-branch --list behavior
  branch: mark more strings for translation
  branch: give a more helpful message on redundant arguments
  branch: reject -D/-d without branch name
Merge branch 'jk/doc-makefile-cleanup' into jch

Will merge to 'master'.

* jk/doc-makefile-cleanup:
  Documentation/Makefile: clean up MAN*_TXT lists
Merge branch 'jk/mergetool' into jch

Cleans up mergetool/difftool combo.

Will merge to 'master'.

* jk/mergetool:
  mergetools: simplify how we handle "vim" and "defaults"
  mergetool--lib: don't call "exit" in setup_tool
  mergetool--lib: improve show_tool_help() output
  mergetools/vim: remove redundant diff command
  git-difftool: use git-mergetool--lib for "--tool-help"
  git-mergetool: don't hardcode 'mergetool' in show_tool_help
  git-mergetool: remove redundant assignment
  git-mergetool: move show_tool_help to mergetool--lib
Merge branch 'da/mergetool-docs' into jch

Build on top of the clean-up done by jk/mergetool and automatically
generate the list of mergetool and difftool backends the build
supports to be included in the documentation.

Will merge to 'master'.

* da/mergetool-docs:
  doc: generate a list of valid merge tools
  mergetool--lib: list user configured tools in '--tool-help'
  mergetool--lib: add functions for finding available tools
  mergetool--lib: improve the help text in guess_merge_tool()
  mergetool--lib: simplify command expressions

Conflicts:
	Documentation/Makefile
Merge branch 'ss/mergetools-tortoise' into jch

Update mergetools to work better with newer merge helper tortoise ships.

Will merge to 'master'.

* ss/mergetools-tortoise:
  mergetools: teach tortoisemerge to handle filenames with SP correctly
  mergetools: support TortoiseGitMerge
Merge branch 'jk/python-styles' into jch

Will merge to 'master'.

* jk/python-styles:
  CodingGuidelines: add Python coding guidelines
Merge branch 'jk/remote-helpers-doc' into jch

"git help remote-helpers" did not work; 'remote-helpers' is not
a subcommand name but a concept, so its documentation should have
been in gitremote-helpers, not git-remote-helpers.

Will merge to 'master'.

* jk/remote-helpers-doc:
  Rename {git- => git}remote-helpers.txt

Conflicts:
	Documentation/Makefile
Merge branch 'ta/doc-no-small-caps' into jch

Update documentation to change "GIT" which was a poor-man's small
caps to "Git".  The latter was the intended spelling.

Also change "git" spelled in all-lowercase to "Git" when it refers
to the system as the whole or the concept it embodies, as opposed to
the command the end users would type.

Will merge to 'master'.

* ta/doc-no-small-caps:
  Documentation: StGit is the right spelling, not StGIT
  Documentation: describe the "repository" in repository-layout
  Documentation: add a description for 'gitfile' to glossary
  Documentation: do not use undefined terms git-dir and git-file
  Documentation: the name of the system is 'Git', not 'git'
  Documentation: avoid poor-man's small caps GIT

Conflicts:
	Documentation/git-cvsimport.txt
	Documentation/howto/maintain-git.txt
Merge branch 'jn/auto-depend-workaround-buggy-ccache' into jch

An age-old workaround to prevent buggy versions of ccache from
breaking the auto-generation of dependencies, which unfortunately
is still relevant because some people use ancient distros.

Will merge to 'master'.

* jn/auto-depend-workaround-buggy-ccache:
  Makefile: explicitly set target name for autogenerated dependencies
### hold in next
Merge branch 'mp/complete-paths' into jch

The completion script used to let the default completer to suggest
pathnames, which gave too many irrelevant choices (e.g. "git add"
would not want to add an unmodified path).  Teach it to use a more
git-aware logic to enumerate only relevant ones.

This is logically the right thing to do, and we would really love
to see people who have been involved in completion code to review
and comment on the implementation.

Will cook in 'next' to see if anybody screams.

* mp/complete-paths:
  git-completion.bash: add support for path completion