add simple and MSI-based installers, add support for using F# CodeDom through CreateProvider, and more#6
add simple and MSI-based installers, add support for using F# CodeDom through CreateProvider, and more#6dsyme merged 6 commits intofsprojects:masterfrom drvink:master
Conversation
|
Hi @drvink That's a lot of work! Could you elaborate on the scenarios where the machine-wide install is needed? I understand that many original uses of CodeDom do rely on a machine-wide install - I'm curious as to which particular use was driving you in this direction. There's a pretty strong trend away from machine-wide install of components, MSI installers etc. towards nuget packages and I'd like to understand what the future looks like for this. I'll take a closer look at the code too. thanks |
|
Hi Don, CodeDom is designed such that programs making use of it need not, and ideally should not, hard-code a list of acceptable target languages, i.e. it should be enough that a CodeDom provider is installed for a given language because programs should simply call I did this work because I wanted to allow for better support of F# within Visual Studio in general. One thing that will work right now if you install the provider is that you can embed F# instead of C# for MSBuild inline tasks. Installing the provider could also potentially enable F# support for T4 (the text template/macro system) or better integration of F# with WPF (the WPF build system uses CodeDom in places), though unfortunately right now both of those hard-code support for only the C# and VB CodeDom providers. Cheers, |
|
OK, I see. I think this is the first new MSI installer I've seen for a very, very long time. It's a shame you can't "install" the CodeDom into a solution via a nuget package or VS addin - the machine-wide model is really problematic these days. What if the MSBuild stuff gets used on a build server like AppVeyor, for example? You'd have to install the MSI there too. I don't really know what the solution is. However, because the MSI installer is somehow "old-school" (even if it's the only way to do things) I wonder if the MSI installer should be in a separate repo. Also we should consider where/how/who would publish the MSI installer. |
|
You reminded me of an important issue: since the provider gets installed to the GAC, it has to go through the usual strong name dance (i.e. signing), which means there needs to be some sort of procedure for publishing the MSI installer. We could just punt on this and let people make their own key + build their own installer unless there's sufficient demand, though having a more polished product seems preferable if possible. |
|
Once you're able to get it installed, you can try this to confirm it works: https://gist.github.com/drvink/37782838e3611b5b7a83 |
There was a problem hiding this comment.
It looks a little odd to use "static let" though is valid - I think just make them "let"
|
I'm happy to integrate this - can you follow up with the minor changes mentioned above? For building and publishing the MSI I recommend using GitHub releases pages in this project for now? I don't use those but @forki or the interwebs should provide the info you need |
add simple and MSI-based installers, add support for using F# CodeDom through CreateProvider, and more
|
Great work BTW |
|
For strong name signing, I suggest just signing with https://github.com/fsharp/fsharp/blob/master/src/fsharp/test.snk or the standard mono.snk for now. |
|
Should I just copy the key from that repo and add it to this one? |
|
Yes, sure |
There are a lot of changes; here is a summary of what's included:
CodeDomProvider.CreateProvider("f#")--in fact this is the correct way to use CodeDom but it seems most people get this wrong and hard-code choices of only C# and VB; even Microsoft gets it wrong in the WPF build system and the T4 template engine!)