Article
How to Duplicating a repository?

Rukon Uddin
over 1 year ago
1 min read10
Technical deep diveAugust 25, 2024javascript
1git clone
This creates a local copy of the repository on your machine.
2. Change Directory into the Cloned Repository:
javascript
1cd
3. (Optional) Rename the Remote (if you want to push changes to a new repository):
javascript
1git remote rename origin upstream
4. Create a New Repository (Optional):
- If you want to create a new repository on GitHub or another Git hosting service, create an empty repository.
- If you’re using a different service, follow its instructions for creating a new repository.
5. Add a New Remote (if you created a new repository):
javascript
1git remote add origin
6. Push to the New Repository (if you created a new repository):
javascript
1git push -u origin master
Enjoyed the article?
Drop a love to let me know
Comments (0)
No comments yet
Be the first to comment!
Please login to join the conversation.
Read more deep dives
Notes from the trenches — architecture decisions, debugging stories, and the small wins that compound.
Browse all articles