2010: for githolite 2 (possibly for githolite 3)
No (means that it is necessary to create a dedicated branch with the desired content).
As the author of the githolite himself laid it :
I am the author of a project called gitolite that does a great job of branch-level access control for several git repositories on a central server. My target "market" is for sure corporate users of git.
So far I have not seen a situation where read access should be limited to ortions of repo (git cannot do this).
[well a rare check may help, but it's still not easy)
Recording access often needs to be limited, and gitolit may allow you to limit:
- as by the name of the branch (for example, only the QA wire can push a series of fixations into the "QA-done" branch).
- or by file name (for example, only a command can make changes to the Makefile and files in
src/very-important-and-critical-module ).
See the “ Security, Access Control, and Auditing ” section, and here is an example of write access:
conf/example.conf file contains all the detailed syntax:
repo foo RW+ = lead_dev
each file affected by marked commits is checked for compliance with these rules.
- Lead_dev can make changes to any files,
- dev1 / 2 can make changes to files in "
doc/ " and " src/ " (but not at the top level of README ), - and dev3 / 4 can only make changes to files in "
src/ ".
Speaking about this, the tough question remains, how does the OP do it:
how can I create a new branch for only some selected files and delete previous commits so that the graphic designer cannot access them and see only the selected ones after cloning?
General principle:
create the 'graph_designer' branch at the point in history where these files were not present .
From there are two options:
- or reorganize your current commits (
git rebase --interactive ) to have a file with only dir2 files first (and then it affects any other directory) - or if the first choice is too much work (or this is not possible because these commits have already been pushed and pulled in other repositories), just copy and add the appropriate files to this new branch.
This means that there was no past history for these files, but they may not need this story from the very beginning.
That ' graph_designer ' will be the only branch allowed for cloning and will not contain a history with unauthorized files.