Answer the question
In order to leave comments, you need to log in
Is it possible to import one git repository into another with history preserved, ideally tags?
Hello everyone,
there is a repository, let's say project1 whose tree is something like this:
.
├── .git
└── folder1
└── folder2
I want to import the following project into it from github ( https://github.com/DefectDojo/django-DefectDojo ) , let's say in the defectdojo
folder
so that in my .git turned out to be all the commits and ideally, the tags that are present in the repository on Github. For example superimposed on top of my history. Is this possible ... or nonsense))
All the best,
Vadim
Answer the question
In order to leave comments, you need to log in
cd my-project-with-git
git remote add remote-repo https://github.com/DefectDojo/django-DefectDojo.git
git fetch remote-repo --tags
git merge --allow-unrelated-histories remote-repo/master
git remote remove remote-repo
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question