Add autogenerated stuff to .gitignore
Ignore only .grive and .grive_state
Reduce number of syscalls while scanning local files
Log XML on parse failure
Add delay before auth token refresh

This is sometimes necessary to prevent too frequent requests.
Fix hang when upload receives HTTP 500

When an uploading PUT request got a HTTP 500 as reponse, grive hanged
forever inside libcurl. This was because the File parameter was not
rewound to 0 position on retry. The XmlResponse had to be cleared as
well.

Rewinding the File and clearing the XmlResponse were not enough to fix
the problem, because when retrying after 500, HTTP 410 Gone or 412
Precondition failed is often received, and CheckHttpResponse would throw
an exception that crashes grive. Therefore, I implemented a retry logic
to Resource::Upload that retries the whole upload transaction if 410 or
412 was received.
Retry upload on XML error instead of crashing

Sometimes the Google Drive API sends malformed XML which crashes grive.
This patch adds a simple try-catch to Resource::Upload that retries the
upload if an XML exception is thrown from AuthAgent::Put.
Merge pull request #1 from vitalif/master

Allow to sync just one directory in the root
Merge pull request #2 from yarogami/stability-fixes

Stability fixes
Merge pull request #3 from yarogami/visa

Visa
Merge branch 'master' of https://github.com/meisterT/grive

Conflicts:
	libgrive/src/drive/State.cc