I am in the process of setting up version control and automated builds using Git and ANT and eventually we might setup Jenkins for continuous integration.
My plan is to utilize Git branches by developers for each feature development and test it in their own sandbox and merge it back to Master branch and from there, we would use ANT for deploying to other environments.
However one question that stuck me is, How to build package.xml? One developer might have modified just an Apex class and other might have modfied a just a visualforce page. Should I manually build the package.xml? I think manual approach is tedious and error prone. I have been reading through several articles on this topic and somebody suggested using a script to generate paackage.xml based on modified files. Not sure that is a good idea. Anyway I wanted to get your thoghts on this.
Would really appreciate your feedback and Thanks.
If you are using jenkins you can write a Shell script .
The below is starter blog that i have found success with Jenkins multiple times when setting the flow for the client .
If you have cummulus set up with your git flow you can use below from salesforce foundation
Also you can also use ANT as highlighted in the below article