C
C#2mo ago
Rubi

Install dotnet Library from GitHub

hi everyone, I have zero knowledge with dotnet, csharp and family In golang we could do go get github.com/username/repo in python we could do pip3 install git+https://github.com/username/repo.git but how about dotnet? can we do similar without uploading package to nuget? thank you! my project is: https://github.com/lokal-so/lokal-dotnet
GitHub
GitHub - lokal-so/lokal-dotnet: .NET Library for interacting with L...
.NET Library for interacting with Lokal Client REST API - lokal-so/lokal-dotnet
16 Replies
Anton
Anton2mo ago
No, you have to either set up nuget, or add it as a submodule and reference a project from it
Rubi
Rubi2mo ago
I'm sorry, do you have guide for the submodule tutorial?
Anton
Anton2mo ago
I'm talking about git submodules Also look at slngen dealing with solutions is a pain without it if you go the submodule route
Angius
Angius2mo ago
If you don't want to involve the nuget.org registry, you can always release on the Github registry But yeah, it's either a Nuget package or a direct project reference There's no dotnet add <github url>
Anton
Anton2mo ago
You'll still need the submodule thing if you're going to be developing both at the same time
Angius
Angius2mo ago
I just use the gh registry for private packages ¯\_(ツ)_/¯
Anton
Anton2mo ago
Yeah and to be able to test your changes in another project of your nuget, you'd have to push a new version, on every change
Angius
Angius2mo ago
Yeah What of it? Github action builds and publishes it Or I add the directory with locally-packed nuggies as a nuget source
Anton
Anton2mo ago
In how many minutes? You still have to manually bump the version with every change
Pobiega
Pobiega2mo ago
can we do similar without uploading package to nuget?
why are you trying to avoid using nuget? thats how 99.99% of people will install your package.
Anton
Anton2mo ago
Which is crazy terrible dev experience
Angius
Angius2mo ago
Version="*"
Anton
Anton2mo ago
Sure. The only "but" I got left is that you have to rebuild everything in the right order if you got chains of dependencies. And in general, not forget to rebuild the nuget in the first place. and bump the version in the nuget, I mean I was thinking of bringing either the package or the project reference from a submodule with msbuild Which I haven't tried before, but it might be better
Rubi
Rubi2mo ago
no, I don't try to avoid nuget at all, I just don't want to release a broken version of my package into nuget
Pobiega
Pobiega2mo ago
so fix it 😛 you can use it as a local reference while developing and release once you feel that its good enough
Want results from more Discord servers?
Add your server