1
I’m tasked with deploying a versioning system here at the company. However I am in doubt between SVN and Git.
My question is whether git has something that does the same as git lock
of the SVN, that is, that blocks the commit
of some certain files for certain branch
.
what I would have is '3 branchs' fixed:
- Master: where the main application is.
- Homologation: where it waits for the client to test and homologate.
- Testing: where is a "final" version of the program version, for intensive testing by teams.
then there are the developments.
However in these 3 branchs, they have some settings files (such as database, FTP, etc) that should not pass to each other branch
.
So I’d like, to avoid human error, to block the merge
/commit
of those files among the branchs and would like to know if git has how to do(or would have some other that allows).
I don’t know if it’s the best solution, but you can use a file called . gitignore that prevents files or folders from being sent to Git
– leofontes
the problem is that then these files would not go to the server/repositorio...
– HagaHood
Look, the SVN lock, it’s not quite what you need. SVN lock is per user. You "Locka" the file, to prevent someone else from committing before you, that’s all. What you need is to work with the permissions file, and that has both Git and SVN. If you can choose, it goes from Git.
– Victor Tadashi
I’m not sure I understand your use case. See, if you block the merge/commit of a versioned file, how will you send it to the server when it actually needs to be changed? Manually. Now, will you always copy in your hand, so that you can copy along with everything else, especially when it comes to sensitive data? Easier to keep ignored.
– Ricardo Moraleida
Victor Tadashi, how do we do it? There are the steps?
– HagaHood
Ricardo, first of all for the main reason of Versionar: to have versions/history of the file. Second would only be some users who could alter these files because of responsibility and not run the risk of commits mistake
– HagaHood