1

So basically because of a university course I had to push repositories like this to my GitHub seperately because the professor preferred the oversight:

/Assignment1

/Assignment2

/Assignment3

Etc.

These all have a folder with a project inside, and their own commit history. What I'd like to do is combine these all into one repository like "course name assignments" and then have it be a repository with a root folder containing a folder each for what was previously its own repository. Like:

/CourseAssignments

-/Assignment1

-/Assignment2

-/Assignment3

BUT also keep the commit history of the individual assignments.

Is there any way to do this using Git commands?

Sophie Bushchak
  • 151
  • 2
  • 7
  • 1
    This is probably what you're looking for: https://stackoverflow.com/questions/1425892/how-do-you-merge-two-git-repositories . Another option you may consider is using git submodules not doing a real "merge" but aggregating multiple repositories into a single "master" repository. – terrorrussia-keeps-killing Dec 13 '20 at 17:09
  • Look at this article: [How to merge two or multiple git repositories into one](https://medium.com/altcampus/how-to-merge-two-or-multiple-git-repositories-into-one-9f8a5209913f) – SwissCodeMen Dec 13 '20 at 20:23

0 Answers0