I am looking for best practices for deploying frequent custom code changes to SharePoint 2010 server, my changes include all kind of changes like web parts, content types, workflows, feature receivers, pages images and scripts in layouts folder etc. So far what I have found in documentation is that WSP packages are recommended for deployments for SharePoint. I have few questions regarding frequent code changes using WSP packages
Ill try to answer your questions:
yes and no. if you are deploying assembly code changes then you can retract the solution without deactivating any features. This will update the assemblies in the GAC. If you need to update resources in the features like content types etc, you will need to deactivate / activate feature.
What I have started to do to mitigate this problem is all my wsp provision all my content trough code, no xml for content types, list instances, etc. Then what I do Is I keep track of the current version of my feature (using web.Properties bag or something). Anytime I activate the feature I check the current version and run the appropriate code for that version. So in feature activated I have something like:
var version = //get version here from property bag or list etc
if (version < 1.2){
provisioFinanceContentType();
createFinanceList();
}
else if (version <1.3)
{
//etc.
}
version = 1.3
//persist version to storage
Do not create new WSPs use the revision system described above