K
K
Kirill Gusarev2021-07-28 16:43:17
git
Kirill Gusarev, 2021-07-28 16:43:17

Is it right to keep projects in one Git repository?

Hello. For a long time and everywhere I searched for the answer to this question - I did not find anything close.
In general, I write small console (mostly) applications for the OpenComputers platform (a modification that adds programming to Minecraft) in the Lua language. In addition to Lua, I can use, for example, Python to take the application logic out of the game to the hosting, when necessary.
Each project takes from 30 to 1000 lines of code. I can assume that on average the project takes ~ ~ 300 lines.
And so, I need to put all my projects on GitHub, but it seems to me that it is not practical to create separate repositories for such small projects. I have an idea that you can create one large, common repository specifically for the OpenComputers platform, and in it each folder will already correspond to some separate, independent project.
Doesn't this violate some idea of ​​Git/GitHub? Or maybe there will be problems with such a repository in the future?
I am writing alone. Git and GitHub never used, I hope for your advice!

UPD: I have projects not only for OpenComputers, so I will definitely fill in the rest in separate turnips.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
V
Vasily Bannikov, 2021-07-28
@kaka888

What you want to do is called a monorepository.
Problems with it can arise when several independent teams work on it at once, and when it grows to wild proportions. And different projects will need to be released independently.
In your case, this is unlikely to happen, so feel free to do so.

M
Maxim Siomin, 2021-07-28
@MaxSiominDev

Is it right to keep projects in one Git repository?

Not

V
Vladimir Korotenko, 2021-07-28
@firedragon

it all depends on the logical structure
related to the project is stored in one repository
something common is taken out to others and created by npm nuget ... and others

K
KoreanGuy, 2021-07-29
@KoreanGuy

Look towards submodules. A separate repo for each project, plus one big "collective" repo with a bunch of modules. Thus, each project will be independent, but at the same time, if you suddenly need to, for example, clone all projects at once, this can be done with one command.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question