I am wondering if it is possible to say have a main repo with everything I need, config, application code, etc. (This is a MVC environment) and create branches from a main GIT repo with just certain models,controllers,and views.
So I would have a main repo with
applications/*
assets/*
system/*
And I would have a branch with
applications/controllers/controller_name.php
applications/model/model_name.php
applications/views/view_name.php
assets/modules/controller_name/*
Then I could merge that branch into the main repo for each new "MVC setup"
Does this make sense? And can it be done?
Git does not branch on a per-file basis, it branches on a repository basis.
That said, just because you make a branch with the entire repo doesn't mean you have to have all of the same files in each branch.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With