buffer: Unify `git_fbuffer` and `git_buf`

This makes so much sense that I can't believe it hasn't been done
before. Kill the old `git_fbuffer` and read files straight into
`git_buf` objects.

Also: In order to fully support 4GB files in 32-bit systems, the
`git_buf` implementation has been changed from using `ssize_t` for
storage and storing negative values on allocation failure, to using
`size_t` and changing the buffer pointer to a magical pointer on
allocation failure.

Hopefully this won't break anything.
filter: Apply filters before writing a file to the ODB

Initial implementation. The relevant code is in `blob.c`: the blob write
function has been split into smaller functions.

	- Directly write a file to the ODB in streaming mode

	- Directly write a symlink to the ODB in direct mode

	- Apply a filter, and write a file to the ODB in direct mode

When trying to write a file, we first call `git_filter__load_for_file`,
which populates a filters array with the required filters based on the
filename.

If no filters are resolved to the filename, we can write to the ODB in
streaming mode straight from disk. Otherwise, we load the whole file in
memory and use double-buffering to apply the filter chain. We finish
by writing the file as a whole to the ODB.
buffer: Null terminate on rtrim
Move revwalk test to clar
revwalk: introduce pushing and hiding by glob

git_revwalk_{push,hide}_glob() lets you push the OIDs of references
that match the specified glob. This is the basics for what git.git
does with the rev-list options --branches, --tags, --remotes and
--glob.
Add revwalk glob test
revwalk: add convenience function to push/hide HEAD

It's not unusual to want the walker to act on HEAD, so add a
convencience function for the case that the user doesn't already have
a resolved HEAD reference.
Simple test for pushing HEAD and hiding a branch
Merge pull request #576 from carlosmn/revwalk

Friendlier revision walking
filter: Load attributes for file
filter: Add write-to CRLF filter
implement support for username@host:path URLs in transport_find_fn()
config: Refactor & add `git_config_get_mapped`

Sane API for real-world usage.
filter: Precache the filter config options on load
filter: Properly cache filter settings
fix up previous SSH path parsing commit based on @carlosmn feedback
introduced new function: git_remote_supported_url() <-- returns true if this version of libgit2 supports the correct transport mechanism for a URL or path
filter: Beautiful refactoring

Comments soothe my soul.
attr: Change the attribute check macros

The point of having `GIT_ATTR_TRUE` and `GIT_ATTR_FALSE` macros is to be
able to change the way that true and false values are stored inside of
the returned gitattributes value pointer.

However, if these macros are implemented as a simple rename for the
`git_attr__true` pointer, they will always be used with the `==`
operator, and hence we cannot really change the implementation to any
other way that doesn't imply using special pointer values and comparing
them!

We need to do the same thing that core Git does, which is using a
function macro. With `GIT_ATTR_TRUE(attr)`, we can change
internally the way that these values are stored to anything we want.

This commit does that, and rewrites a large chunk of the attributes test
suite to remove duplicated code for expected attributes, and to
properly test the function macro behavior instead of comparing
pointers.
config: Implement a proper cvar cache