I need to setup a common code styling pattern which team needs to follow and will give warning or error to the developer while writing/compiling the code or pushing the code on the repository.
I have gone through couple of sites explaining about the EditorConfig file for setting up the styling in Visual Studio.
For spaces after parameters, the control for this is "Insert space after comma". Again, this will be for all commas used throughout your code, not just for parameters:
Lastly, you can control the indentation settings you wish by looking under the Whitespace → Indentation and spacing section:
For formatting on build you have some options. You can download a format on save extension, but that wouldn't format on "a build" technically. However I think because when a build is performed, a save of all files automatically occurs, and this should also format them.