I was thinking of having a versioning system for our projects folder (visual effects facility). We work on shots, and each should lets say has one file I would like to version. Here's the thing. If I have one repository per shot (folder) is it bad? If I have one repository and move all those files in one folder and version that entire folder it would be really difficult to get just that version of ONE file. Any advices? Or git/mercurial is just not the way to go and best is to have copies in a version subfolder etc etc.
The 开发者_开发技巧directory structure would be something like this
-projects
--project1
---shot1
----compositing
-----shot1.comp
---shot2
----compositing
-----shot2.comp
I would need some form of versioning for each .comp
file.
If all you need is local versioning, you might want to look at RCS. It creates a file,v
for each file
(conventionally, but not necessarily, inside a folder called RCS) which contains the commit messages and diffs.
You can use Tag name on Git to retrieve the desired version you want on a particular in a single repository.
In your repo, type
git checkout <tag name or your version no.> -- <filename>
i.e.
git checkout version1 -- shot2.comp
the file shot2.comp will be checkout with version1.
you can do different checkout on your single repo to retrieve the desired file you want.
#if you think this is too clumsy to always type git checkout to retrieve version of files.
you can make multiple repos on different folders.
folder1 with all the version 1 files
in folder 1
git checkout version1
in folder 2
git checkout version2
All the files will be at version1 and version2 on folder1 and 2 respectively.
Hope this helps.
A (Git or Mercurial) repo is a coherent set of files managed as a all (i.e. branched or labelled as a all).
You don't usually make a repo for just one file (that model wouldn't scale easily should you need all of those repos at the same time), but in your case, that could be an option.
However, you could also use one repo with one branch per shot.
You would still clone everything, but checkout only one branch (and seeing only one file).
精彩评论