Recently at work we had to create a lot of microservices where we required to copy-paste lot of files from one sample solution to the specific service implementations. The necessity of this approach comes from the many small differences between each service.
Of course the common code was extracted to shared libraries but this was just a partial solution. Now that we can grasp their usefulness, let’s see how to create visual studio templates!
Different options for creating templates
There are three ways to create a project template:
- Exporting a template from an existing project
- Creating a template project
- Exporting an existing project then copying its content to a template project
In this tutorial we will explore the first option.