When making customizations in Studio, where are the customizations written to (ie /custom/Extension/modules or /custom/modules/ )? Are the contents of the file merged or completely overwritten?
It depends on the type of customization in question.
For example, if you create a custom field, the metadata for that field is written to a database table named fields_meta_data. Should you then define a Sugar Logic function for that field, that metadata would be written to ./custom/Extension/modules/<Module>/Ext/Vardefs/
In the above example, it is possible to have multiple files in ./Ext/Vardefs/, each representing different customizations to different components/fields (or the same component/field). Upon performing a Quick Repair and Rebuild, all of those files are aggregated into a file called vardefs.ext.php, located in ./custom/modules/<Module>/Ext/Vardefs/
Thanks for the explanation, this is clearer to me now.
Retrieving data ...