ligershark / side-waffle

A collection of Item- and Project Templates for Visual Studio
Other
657 stars 205 forks source link

Can't refer to ProjectName with itemTemplates when new project is created out of a projectTemplate. #402

Open erik3355 opened 7 years ago

erik3355 commented 7 years ago

I have a solution with 2 projects. One ProjectTemplate-Project and one VSIXProject with a sidewaffle reference to the ProjectTemplate (like the video tutorial by Sayed Hashimi). Then in this VSIX project i also have some item templates which have a parameter to refer to the $rootnamespace$ of the project. Everything builds and works fine. BUT when i create a new project out of the template, and add a new item to it from one of the item templates, the refrence of $rootnamespace$ refers to the name of the ProjectTemplate instead of name of the newly created project. Example I create project with name DemoPlugin, the generated project skeleton classes will have namespace DemoPlugin.commands and the added items will get ProjectTemplate.commands as namespace.

Is this intentional and am i missing the point? or is it not possible to have the itemtemplates refer to the newly created project's name that is created out of the projectTemplate?

I have also used all the other parameters out there and tried fiddling around with custom parameters but nothing seems to work for me.