I have a project "MyfirstProject" in github. Now I am making another project "SecondProject" by cloning "MyfirstProject" since core codes will be the same.
Whenever I updates in "MYfirstProject" I just pull for updates.
Now I want to make a repository for this "SecondProject" in github since I have to work in different computers and it will have different codes from "MYfirstProject".
I don't think branching out is right thing to do since I will never merge them.
How can I do?
Do I need to push to a new repository? Won't it affect pulls from "MyfirstProject"?
What do you do?
Thanks in advance.
Usage. git clone is primarily used to point to an existing repo and make a clone or copy of that repo at in a new directory, at another location. The original repository can be located on the local filesystem or on remote machine accessible supported protocols. The git clone command copies an existing Git repository.
There's probably several ways to do this, including a smarter one, but this is how I would do this:
SecondProject
.MyfirstProject
, either from disk or from Github.
Then use git pull on the branches you need to move to the second repo.git remote set-url origin [email protected]:yourname/SecondProject.git
Note that the clone retains a shared history with MyfirstProject
, which is useful if you change your mind about the "never merge" bit.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With