question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Classes from Nuget package

See original GitHub issue

Hi,

First of Thanks for a awesome tool! Absolutly love it!

But I have an problem I can’t resolve… I a class library as a nuget package, from a service solution, that I reference in my Asp.Net5 Client.

What I want is to template all classes in the nuget package, Already have a template thats working for the project in the same solution. But when I add the nuget reference it cant be found…

17:35:40.319 WARNING: Cannot find project named ‘Backend.Queries’

How can I do this or is it not supported? If not I guess I could move the Dtos, Commands and Queries project to the client solution and make the backend consume the nuget packages.

But stil it would be nice for packages you don’t have control over.

Thanks!

$Classes(c => AcceptableClass(c.Name))[   
    // Generated.
    // Do NOT edit this file manually.
    $Imports
    $Properties[$Type[$CreatePropertyImport]]

    export class $ClassName $Inheritance {
        constructor($Properties[public $name: $Type[$TypeScriptName]][,]) {
        }
    }
]
    bool AcceptableClass(string className)
    {
        if(className.EndsWith("Dto") ||
          className.EndsWith("Query") || 
          className.EndsWith("Command"))
          {
            return true;
          }
        return false;
    }
    Template(Settings settings)
    {
        settings.IncludeProject("Pixie.Backend"); //Project in the same solution
        settings.IncludeProject("Backend.Queries"); //Nuget package references in project.json
        settings.IncludeReferencedProjects();
        settings.OutputExtension = ".ts";
    }

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:2
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
Kavorka79commented, Mar 29, 2016

Thanks for the quick reply! Ok guess we have a decision to make then… =)

External reference support would be extremly good to have for larger projects, I know you have lots to do but I hope to see it in the future.

Thanks!

1reaction
agustinbcu01commented, Jul 16, 2018

Managed Extensibility Framework https://en.m.wikipedia.org/wiki/Managed_Extensibility_Framework

On Jul 15, 2018, at 9:54 PM, andrewb273 notifications@github.com wrote:

@agustinbcu01 what is MEF?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to see public classes/methods for installed nuget dll
In the installed nuget folder C:\Users\myUserName\.nuget\packages\some.nuget\1.2.3 is just some nuget metadata and the dll file. I know the ...
Read more >
Create and publish a NuGet package using Visual Studio ...
With Microsoft Visual Studio, you can create a NuGet package from a .NET class library, and then publish it to nuget.org using a...
Read more >
Using a NuGet in a class library? : r/csharp
A better practice is to make the library a NuGet package itself. The package will contain the dependencies to different NuGet packages.
Read more >
Visual Studio: Creating a nuget package from a class library
The configuration. First thing you need is...something to publish. For this tutorial I'm using a sample .NET 6 class library containing some ...
Read more >
Shared class library vs. internal NuGet package vs copying
Hi. We have a number of different applications that share more and more of a common functionality. So far we've just copied the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found