visual-studiovisual-studio-shellcommon-project-system

"Reference manager" missing in custom project type (in VS IsolatedShell)


I'm working on a VS IsolatedShell 2015 application; my current goal is to enable project references.
However when right-clicking the 'references' node in a project there are basically no options available, most notably for my case the reference manager is missing:

Context menu of the 'references' node

The project itself is based on CPS, so maybe I need to enable this somewhere in there?

The project does contain these capabilities (as documented here):
<ProjectCapability Include="AssemblyReferences;COMReferences;ProjectReferences;SDKReferences" />

I've also added the ReferenceManagerProjects & DependenciesTree capabilities (another link) and made sure that there are rule files for the resolved references (I tested this by manually adding some assembly references to the project and those are displayed correctly).

Within the Shell .pkgundef file the 'web specific packages' are enabled, as hinted in the last answer on this page.
I've also looked through all other pkgdef/pkgundef files, but nothing else looked like it should be responsible for the reference manager.

Are there any other places that could lock the reference manager out?
Or is there some interface that has to be implemented for CPS to enable this?


Solution

  • Turned out one solution to the problem was adding an implementation of the IProjectCapabilitiesProvider and return the capabilites for the reference types I needed there:

     public Task<IEnumerable<string>> GetCapabilitiesAsync()
     {
         return Task.FromResult<IEnumerable<string>>(new[]
         {
             CustomProjUnconfiguredProject.UniqueCapability,
             "AssemblyReferences",
             "ProjectReferences"
         });
     }
    

    The reference manager can still not be accessed using the 'references' node, however using the context menu on a project you can find it in 'Add' > 'Reference'

    Alternate location of the reference manager