Hello Atlassian Support Team,
I hope this message finds you well. I am currently using Bitbucket for version control, and I am interested in exploring more granular control over file-level permissions.
Is it possible to set permissions at the file level in Bitbucket? Specifically, I would like to restrict certain users from cloning the entire repository and, instead, provide access to a predefined list of files. For example, User A should only have access to specific files like "file1" and "file2" and not the entire repository.
I have considered using branches, but I am concerned about the potential risk of accidentally removing files from the main branch during merges.
Could you please provide guidance on whether Bitbucket offers a feature or workaround to achieve this level of file-level access control? If not, do you have any recommendations or best practices for managing such scenarios?
I don't think you can protect files one by one. Branches is an option, but as you wrote, it is not the best for your use cases.
Another option that comes to my mind and that you could try is using Git submodules!
For example, if you want some users only to a set of files, then move those files to a separate submodule. (Like you could move the i18n files that your translators work on to a submodule, and integrate those to the final artifact during building the project.)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.