Course: Introduction to Software Engineering
ID | Name | Account |
---|---|---|
19127078 | Thanh Truc | nguyendothanhtruc |
19127097 | Phuong Anh | nnpanh |
19127097 | Duc Hieu | duchieuvn |
19127082 | Tat Truong | TruongNguyen0104 |
19127511 | Hong Phuc | phineasla |
- Clone all repositories you want to merge (for example
repo-a
). Then create new repository you want to merge into (let's call itmonorepo
). - Install
git-filter-repo
:- For Windows user: install as python package
pip3 install git-filter-repo
. - For other OS please refer here.
- For Windows user: install as python package
cd path/to/repo-a
git filter-repo --to-subdirectory-filter <subdirectory-name> # your repo-a will now become repo-a/<subdirectory-name>.
cd path/to/monorepo
git remote add repo-a /path/to/repo-a
git fetch repo-a --tags
git merge --allow-unrelated-histories repo-a/main # or whichever branch you want to merge
git remote remove project-a
Reference: How do you merge two Git repositories?