Open garuma opened 7 years ago
Why not just use MonoDevelop.Addins? That way you can use the full richness of MSBuild, and we don't need to add this to Mono.Addins. You can do this today in your addin csproj:
<AddinFile Import="Foo/*" />
And the files will be copied to the output directory and added to the manifest.
Also, if this were the approach we were taking, IMO the pack phase should update the manifest to use the expanded glob, so that that basic addin integrity checks still work.
@Therzok what nuspec? :)
I'm not opposed to having this feature, in addition to MonoDevelop.Addins. It may be useful for other apps that can't use the extension.
30 new files to just implement a globbing algorithm is overkill. We can just use msbuild-like globbing, which is probably less complete but good enough. We have an implementation here: https://github.com/mono/monodevelop/blob/5893e486d074ecd8f40bcebe65cd6fe112248245/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.MSBuild/DefaultMSBuildEngine.cs#L823.
Also, if this were the approach we were taking, IMO the pack phase should update the manifest to > use the expanded glob, so that that basic addin integrity checks still work.
That would be nice, although it is not a critical issue. The problem is that files may be imported using attributes or in embedded manifests which we can't easily update when packing.
This uses NuGet file globbing library so should support the same set of feature as .nuspec parsing.