We really like what you have built here and would like to make a Wish List request which is to add support for XSLT files to automatically create their associated Macro's when they are copied from the solution into a site.
I.e. If we create a new XSLT file in Visual Studio and copy it across to our site in the post build script, next time we open the Umbraco back end, your wizzy code could detect if there is a Macro associated with the XSLT and if not, it could create it.
The problem with automatic Macro creation for xslt files is fact that Macro has number of properties like Name, UseInEditor, Render content in editor... as well as macro parameters which could be tricky to specify along with Xslt file. Xslt would need some metadata that will describe macro. Do you have suggestions?
Not directly related to uSiteBuilder, but I did some quick investigation on macros and macro properties a while back.
In theory you would just need a SQL script to sync the cmsMacro and cmsMacroProperty tables, I don't think the database ID's get used anywhere (even if they did they could be recreated).
Obviously you'd still have to create the macros manually in your master umbraco install but then it shouldn't be hard to create an sql update script in the post build tasks.
The generated .sql files could then be part of source control system at least.
Not ideal, I'm guessing inline razor would solve this in a nicer way?
Wish List Item - Add support for XSLT files
Hi Guys,
We really like what you have built here and would like to make a Wish List request which is to add support for XSLT files to automatically create their associated Macro's when they are copied from the solution into a site.
I.e. If we create a new XSLT file in Visual Studio and copy it across to our site in the post build script, next time we open the Umbraco back end, your wizzy code could detect if there is a Macro associated with the XSLT and if not, it could create it.
Cheers,
Chris
Hi Chris,
The problem with automatic Macro creation for xslt files is fact that Macro has number of properties like Name, UseInEditor, Render content in editor... as well as macro parameters which could be tricky to specify along with Xslt file. Xslt would need some metadata that will describe macro. Do you have suggestions?
Hey Chris, Vladan (awesome package btw),
Not directly related to uSiteBuilder, but I did some quick investigation on macros and macro properties a while back.
In theory you would just need a SQL script to sync the cmsMacro and cmsMacroProperty tables, I don't think the database ID's get used anywhere (even if they did they could be recreated).
Obviously you'd still have to create the macros manually in your master umbraco install but then it shouldn't be hard to create an sql update script in the post build tasks.
The generated .sql files could then be part of source control system at least.
Not ideal, I'm guessing inline razor would solve this in a nicer way?
Rich
is working on a reply...