I have a code repository in TFS (Microsoft Team Foundation Server). I can use git-tfs to convert this to a git repository.
But what I want to do is set up one central git repo that pushes to TFS, and have all developers clone that git repo and not be able to push to TFS. As far as anyone "downstream" from the central repo., I don't want any indication there's a TFS repo at all.
Since the TFS server information is included in the repo produced by git-tfs, how can I do this?
There's several problems need to be solved for this to work. Most prominent is mapping from git users to TFS credentials that will be used when checking in changes back to TFS.
And other troublesome thing is possible conflict with other TFS users (i.e. if someone decides to push things to TFS directly).
That is why it wasn't developed as part of git-tfs I believe (at least that is why I didn't added this feature several months ago).
If you're ok with having TFS login/password pairs in plain text file, and you can ensure conflict-free workflow (e.g. to prohibit checkins to TFS in any other way except through your git central repository) - you can implement what you need with commit hooks or even with simple scheduler (so pushing will be not immediate, but deferred and asynchronous, thus speeding up pushing to git central repository significantly).
Actual script should be pretty straightforward, but nobody bothered to write one yet (at least I don't know of such thing).