Difference between git branch –set-upstream-to vs git remote add origin

I find it little confusing to know the difference between git branch --set-upstream-to vs git remote add origin.

Basically I have a bare repository created with git init --bare which is shared on network so that other developers could also push to it so that we have our projects versioned locally but not sure which command should I run amonsts above two (or if there is some other) to track that central repo.

Can anyone please enlighten on this?

Leave a Reply

*

Hire Me
Follow Me!
Search
Most Popular Articles & Pages
Because your vote is Important
Sorry, there are no polls available at the moment.
Categories