Merge branch 'development'
Merge branch 'development'
Fix GIT_MERGE_OPTS_INIT on MSVC.
Tree accessor tests with hard path names
Further tree building tests with hard paths
Reset helpers: use revparse instead
Add reflog parameters to git_reset
Fix warning
Add reset tests for reflog
Replace pqueue with code from hashsig heap

I accidentally wrote a separate priority queue implementation when
I was working on file rename detection as part of the file hash
signature calculation code.  To simplify licensing terms, I just
adapted that to a general purpose priority queue and replace the
old priority queue implementation that was borrowed from elsewhere.

This also removes parts of the COPYING document that no longer
apply to libgit2.
Add some priority queue tests

I forgot that I wrote some tests for the new priority queue code.
Merge pull request #2096 from ethomson/merge

Corrections for merge working directory validation
Convert pqueue to just be a git_vector

This updates the git_pqueue to simply be a set of specialized
init/insert/pop functions on a git_vector.

To preserve the pqueue feature of having a fixed size heap, I
converted the "sorted" field in git_vectors to a more general
"flags" field so that pqueue could mix in it's own flag.  This
had a bunch of ramifications because a number of places were
directly looking at the vector "sorted" field - I added a couple
new git_vector helpers (is_sorted, set_sorted) so the specific
representation of this information could be abstracted.
Fix typo setting sorted flag when reloading index

This fixes a typo I made for setting the sorted flag on the index
after a reload.  That typo didn't actually cause any test failures
so I'm also adding a test that explicitly checks that the index is
correctly sorted after a reload when ignoring case and when not.
Fix reflog message when creating commits
Avoid extra copying in pqueue operations

This tweaks the pqueue_up and pqueue_down routines so that they
will not do full element swaps but instead carry over the state
of the previous loop iteration and only assign elements for which
we know the final position.  This will avoid a little bit of data
assignment which should improve performance in theory.

Also got rid of some vector helpers that I'm no longer using.
Add reflog parameters to git_push_update_tips
Add reflog parameters to remote apis

Also added a test for git_remote_fetch.
Add reflog params to git_repository_detach_head
refs: conditional ref updates

Allow updating references if the old value matches the given one.