0

Suppose I want to redirect all fetch upon url https://github.com/CocoaPods/Specs.git to a local repo ~/.Specs, and push also updated to the origin url, how to do?

This question seems partly solve my problem, but this config affect both fetch and push.

Karl
  • 665
  • 4
  • 19

1 Answers1

0
git remote set-url --push origin user@example.com:repo.git

https://stackoverflow.com/a/4523625/1254812

Community
  • 1
  • 1
dcow
  • 7,765
  • 3
  • 45
  • 65
  • Thanks, but this is mostly a question for `git`. I know how to use a private mirrored specs repo. – Karl Jan 12 '17 at 08:14
  • Oh. [Here](https://www.kernel.org/pub/software/scm/git/docs/git-push.html#_named_remote_in_configuration_file). – dcow Jan 12 '17 at 08:19