Mirror Repos
Some projects could be a student’s heart and soul. We do not want to take this away from them, instead we just want to store a copy of the current version on bathcs.com.
So the solution to this is to have a mirror repo.
There are multiple ways to solve this:
GitLab Mirror
In GitLab go to “Settings > Repository > Mirroring Repositories”, you can see there is an option to “push” to another repo.
This means that if the student has their own GitLab instance where they store their own version, they can setup this pushing feature to push to a repo on the GitLab.
However, due to security restrictions, this only works when the other server is connected to the University Intranet, so it is not feasible.
Just do it manually
When doing it manually, you can just push to two separate repositories when making changes locally, by going:
git pushgit push bath
If you were wanting to have a specialised branch which has some extra features, you can do something like:
git checkout branch-namegit push bath HEAD:main