Re-initialize libgit2 filter when re-initializing git

Closed username-removed-138980 requested to merge re-init-cgit into master

Re-initialize libgit2 filter when re-initializing git

Re-initialize libgit2 settings only if CGit instance is default