Is the latest CodeSmith Generator version compatible with MP?

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
7/1/2014 11:03:28 AM
Gravatar
Total Posts 11

Is the latest CodeSmith Generator version compatible with MP?

Hello Forum:

The video tutorials are starting to make more sense, so I thought I should look at this CodeSmith thingee.

I found the templates in the MojoPortal tree. Then I installed the latest CodeSmith 7.0.1.

When I open the mp_Table_ToGridView.cst in the CodeSmith Generator Studio, I get a whole bunch of errors (before even doing a "generate") like:

';' expected in File qirnu3m1.cs

I cannot find this file anywhere.

This causes me to ask the Subject question:

Is the latest CodeSmith Generator version compatible with MP?

Thanks in advance.

Regards..

7/1/2014 11:19:43 AM
Gravatar
Total Posts 18439

Re: Is the latest CodeSmith Generator version compatible with MP?

It sounds like the latest version of Codesmith is not compatible with our codesmith templates which were created using an older version of codesmith. I do not know what it would take to make them compatible but I do not currently plan to upgrade to a newer version of codesmith to solve that. I currently have codesmith studio 4.1.1 and have felt no need to upgrade.

I would suggest ask the codesmith people about compatibility with older templates. Maybe they have configuration options for working with older templates.

It isn't really a question of compatibility with mojoPortal, just compatibility with templates created in older versions of their own product,so I would raise the issue with them.

If you do figure out a solution by modifying any of our templates, you could send those to me and I will include them in a different folder.

7/2/2014 3:03:23 PM
Gravatar
Total Posts 11

Re: Is the latest CodeSmith Generator version compatible with MP?

OK Joe:

I contacted CodeSmith support and I sent them that template. They debugged it and returned to me an updated template with the following response:

-----------------------

I've attached an updated template. The reason you were seeing this behavior is because lines 130-138 were doing this: <% ResourceFileNameSpace %> instead of <%= ResourceFileNameSpace %>. The <% means that the template will treat it as a code block and not an expression the <%= is a write block and treats the content as an expression.

Please let us know if you have any questions or feedback.

-----------------------

I cannot find a way to send this to you (using the forums or the contact link).

Also I can imagine that you can fix this behavior directly. Let me know if you want me to send the template they modified.

I loaded it into the CodeSmith studio thingee, and it loads correctly and generates with no errors.

Also I loaded almost all of the other templates (save for the postgresql_* and Firebird_* ones) and they seem to load OK.

Regards..

7/3/2014 11:03:02 AM
Gravatar
Total Posts 18439

Re: Is the latest CodeSmith Generator version compatible with MP?

If I had known that the problem was only happening with one of our templates and not others I would not have blamed it on the newer codesmith version. I will update the template as suggested.

Thanks,

Joe

You must sign in to post in the forums. This thread is closed to new posts.