Registered a new Git repositoy via web interface at Trac, but it can't sync.
Issuing the suggested trac-admin
command for resyncing says that the repository does not appear to be a Git repository.
Check if the repository path has an space at the end of it. This was causing the problem for me.
For example, the repository path was "C:/foo/bar.git"
and I've accidentaly typed it with a space at the end: "C:/foo/bar.git "
. So Trac couldn't retrieve the git repository.
Removed the space and it worked fine.