I am doing my best to wade through O'Reilly's "Version Control with Git" but I'm still a bit short of the git awakening. I have a particular issue I need to sort out ASAP.
In particular, I have a website built on Joomla with a lot of modifications and I have a separate daemon-type project, both written in PHP. I'd like to store a snapshot of the Joomla source as it currently exists and call this snapshot V2. When I say "snapshot" I mean to say a frozen-in-time collection of files that will never change and I can always go back to it.
We have taken this code and published it to our V3 server where we expect to continue making changes to it. I am unsure whether to:
A) simply create a new repository for V3 on github
simply create another directory inside the same repo that stores the V2 code like so:
repo-directory
--V2
----[source code for V2 here]
--V3
----[source code for V3 (mostly identical to V2) here]
C) Use git branch to branch the code in the repo for development of our V3 codebase. I'm still struggling with the concept of branching a bit and kind of half-understand that two branches of a code project may result in radically different directory structures or something.
I would then need to repeat the same question for how to deal with our V4 code. The V4 design will involve us migrating away from Joomla to an entirely different framework (which is being discussed in a thread elsewhere) so V4 development will likely be quite different than our V3 code but there will be a lot of file assets, etc. that are actually shared between the two versions.
If anyone could suggest a good approach to start this off, I would be greatly appreciative.