Creating a NuGet package for backoffice extension.
I have developed a package and have created an Umbraco Package just fine. I have also created a nuget package that copies my files & dll correctly. The issue I am running into is adding entries to the application.config and dashboard.config. With the umbraco package, it was as easy as adding the package actions. With nuget, I don't even know where to begin. If anyone could give me push in the right direction that would be awesome.
Thanks for the sample. However, I am not having a problem creating a nuget package, I can do that fine. What I am having trouble with is getting Nuget to write to the dashboard.config and the application.config. Unless I missed it, I didn't see in your package where that is happening.
Awesome! Thanks for the resources Dave. I got it working using the XDT transforms for the XML files. Just one thing to note for future developers trying to do the same thing. It wasn't obvious to me that in order to run your XDT transform on installation all that you have to do is put the .xdt file in the folder that contains the target config file.
Creating a NuGet package for backoffice extension.
I have developed a package and have created an Umbraco Package just fine. I have also created a nuget package that copies my files & dll correctly. The issue I am running into is adding entries to the application.config and dashboard.config. With the umbraco package, it was as easy as adding the package actions. With nuget, I don't even know where to begin. If anyone could give me push in the right direction that would be awesome.
Thanks!
Hi Logan,
Here you can see the code that I use to create a Umbraco Package and Nuget package.
https://bitbucket.org/dawoe/embed-property-editor/src/1720f8b0e81b0723241f25f4def3e7451ad244bd/Packaging/?at=master
Dave
Hi Dave,
Thanks for the sample. However, I am not having a problem creating a nuget package, I can do that fine. What I am having trouble with is getting Nuget to write to the dashboard.config and the application.config. Unless I missed it, I didn't see in your package where that is happening.
Thanks
Hi Logan,
Haven't tried changing config files yet with a nuget package.
Maybe this can help you out ? https://docs.nuget.org/create/configuration-file-and-source-code-transformations
Haven't tried it but let me know if you can use it.
Dave
I see for example that this package also uses this approach https://www.nuget.org/packages/UmbracoCms.UmbracoExamine.PDF/
Source code : https://github.com/umbraco/UmbracoExamine.PDF/tree/master/build/nuget-transforms
Dave
Awesome! Thanks for the resources Dave. I got it working using the XDT transforms for the XML files. Just one thing to note for future developers trying to do the same thing. It wasn't obvious to me that in order to run your XDT transform on installation all that you have to do is put the .xdt file in the folder that contains the target config file.
Thanks again!
is working on a reply...