UnityNuGet
UnityNuGet copied to clipboard
Feature request: Ability to set import settings for assemblies
Some NuGet assemblies would be useful, but only on certain platforms. NSubsitute, for instance, will only work within the Editor or on Mono-powered builds, as it uses System.Reflection.Emit
; it would need to have all platforms except for the Editor and Standalone excluded, plus it would need to test for whatever the#define
for Mono builds is.
Agreed. That would require a change to the registry to allow to define the constraints and platforms. PR Welcome.
I'll do it. I'll see about mimicking the .meta
file format for managed .dll
's as closely as possible. Specifically, that means the following fields:
-
defineConstraints
-
isPreloaded
-
isOverridable
-
isExplicitlyReferenced
-
validateReferences
-
platformData
Couple of questions before I do:
- ~~How do I run a local copy of this registry? Just use the example, right? What's the command for that again? (It's been a while since I used Docker.)~~ Never mind, the Visual Studio solution already has a task for that.
- Is the refresh interval configurable? I'd like to locally bump it to once a minute to simplify testing.
- The main classes to modify include
UnityPackage
,UnityMeta
andRegistryEntry
, right? Any other places in the code you think I'll need to dig into? - Is there an authoritative reference for
platformData
's structure? Or at least someinternal
class inUnityEditor.dll
that I can peek into?
About question 2.
I made a PR a few weeks ago to make it configurable: https://github.com/xoofx/UnityNuGet/blob/master/src/UnityNuGet.Server/appsettings.json#L8
About question 2.
I made a PR a few weeks ago to make it configurable: https://github.com/xoofx/UnityNuGet/blob/master/src/UnityNuGet.Server/appsettings.json#L8
Ooh, neat, thanks!
@xoofx Now that #59 has knocked out a good chunk of this feature request, do you happen to know anything about this?
- Is there an authoritative reference for
platformData
's structure? Or at least someinternal
class inUnityEditor.dll
that I can peek into?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.
If you think this issue should stay open, please remove the Stale
label or comment on the issue.