l10n: Fix a couple of typos in the Swedish translation

Thanks-to: Anders Jonsson <anders.jonsson@norsjovallen.se>
Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
remote-hg: add more tests

Inspired by the tests in gitifyhg.

One test is failing, but that's because of a limitation of
remote-helpers.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t: remote-hg: add file operation tests

Inspired by gitifyhg.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t: remote-hg: trivial cleanups and fixes

There was a broken && chain, and cat is simpler than echo in a subshell.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
remote-hg: add support for hg v3.0

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Merge branch 'km/avoid-cp-a' into maint

Some tests used shell constructs that did not work well on FreeBSD

* km/avoid-cp-a:
  test: fix t7001 cp to use POSIX options
Merge branch 'km/avoid-bs-in-shell-glob' into maint

Some tests used shell constructs that did not work well on FreeBSD

* km/avoid-bs-in-shell-glob:
  test: fix t5560 on FreeBSD
Merge branch 'tb/unicode-6.3-zero-width' into maint

Some more Unicode codepoints defined in Unicode 6.3 as having zero
width have been taught to our display column counting logic.

* tb/unicode-6.3-zero-width:
  utf8.c: partially update to version 6.3
Merge branch 'km/avoid-non-function-return-in-rebase' into maint

"git rebase" used a POSIX shell construct FreeBSD /bin/sh does not
work well with.

* km/avoid-non-function-return-in-rebase:
  Revert "rebase: fix run_specific_rebase's use of "return" on FreeBSD"
  rebase: avoid non-function use of "return" on FreeBSD
Merge branch 'rh/prompt-pcmode-avoid-eval-on-refname' into maint

The shell prompt script (in contrib/), when using the PROMPT_COMMAND
interface, used an unsafe construct when showing the branch name in
$PS1.

* rh/prompt-pcmode-avoid-eval-on-refname:
  git-prompt.sh: don't put unsanitized branch names in $PS1
Merge branch 'cl/p4-use-diff-tree' into maint

"git p4" dealing with changes in binary files were broken by a
change in 1.9 release.

* cl/p4-use-diff-tree:
  git-p4: format-patch to diff-tree change breaks binary patches
Start preparing for 1.9.3

Signed-off-by: Junio C Hamano <gitster@pobox.com>
Merge git://github.com/git-l10n/git-po

* 'master' of git://github.com/git-l10n/git-po:
  l10n: Fix a couple of typos in the Swedish translation
shell doc: remove stray "+" in example

The git-shell(1) manpage says

	EXAMPLE
	       To disable interactive logins, displaying a greeting
		instead:

		+

		   $ chsh -s /usr/bin/git-shell
		   $ mkdir $HOME/git-shell-commands
[...]

The stray "+" has been there ever since the example was added in
v1.8.3-rc0~210^2 (shell: new no-interactive-login command to print a
custom message, 2013-03-09).  The "+" sign between paragraphs is
needed in asciidoc to attach extra paragraphs to a list item but here
it is not needed and ends up rendered as a literal "+".  Remove it.

A quick search with "grep -e '<p>+' /usr/share/doc/git/html/*.html"
doesn't find any other instances of this problem.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Sync with maint

* maint:
  shell doc: remove stray "+" in example
  Start preparing for 1.9.3
[DONTMERGE-not signed-off] remote-hg: work with older versions of mercurial

68d4f4f3 (remote-hg: custom method to write tags, 2013-04-22) tried
to catch ManifestLookupError (which is a subclass of LookupError) in
the new method write_tag() to detect and deal with an error.

However, older versions of mercurial have this specific type of error
and throws LookupError instead.  By catching the more generic type
of error, cover both old and new versions.
refs.c: add new functions reflog_exists and delete_reflog

Add two new functions, reflog_exists and delete_reflog, to hide the internal
reflog implementation (that they are files under .git/logs/...) from callers.
Update checkout.c to use these functions in update_refs_for_switch instead of
building pathnames and calling out to file access functions. Update reflog.c
to use these to check if the reflog exists. Now there are still many places
in reflog.c where we are still leaking the reflog storage implementation but
this at least reduces the number of such dependencies by one. Finally
change two places in refs.c itself to use the new function to check if a ref
exists or not isntead of build-path-and-stat(). Now, this is strictly not all
that important since these are in parts of refs that are implementing the
actual file storage backend but on the other hand it will not hurt either.

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
Acked-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
checkout.c: use ref_exists instead of file_exist

Change checkout.c to check if a ref exists instead of checking if a loose ref
file exists when deciding if to delete an orphaned log file. Otherwise, if a
ref only exists as a packed ref without a corresponding loose ref for the
currently checked out branch, we risk that the reflog will be deleted when we
switch to a different branch.

Update the reflog tests to check for this bug.

The following reproduces the bug:
$ git init-db
$ git config core.logallrefupdates true
$ git commit -m Initial --allow-empty
    [master (root-commit) bb11abe] Initial
$ git reflog master
    [8561dcb master@{0}: commit (initial): Initial]
$ find .git/{refs,logs} -type f | grep master
    [.git/refs/heads/master]
    [.git/logs/refs/heads/master]
$ git branch foo
$ git pack-refs --all
$ find .git/{refs,logs} -type f | grep master
    [.git/logs/refs/heads/master]
$ git checkout foo
$ find .git/{refs,logs} -type f | grep master
    ... reflog file is missing ...
$ git reflog master
    ... nothing ...

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
Acked-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
mv: allow renaming to fix case on case insensitive filesystems

"git mv hello.txt Hello.txt" on a case insensitive filesystem
always triggers "destination already exists" error, because these
two names refer to the same path from the filesystem's point of
view, and requires the user to give "--force" when correcting the
case of the path recorded in the index and in the next commit.

Detect this case and allow it without requiring "--force".

Signed-off-by: David Turner <dturner@twitter.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Merge branch 'sk/tag-contains-wo-recursion' into jch

* sk/tag-contains-wo-recursion:
  git tag --contains: avoid stack overflow