I've moved my package repository to VSTS and tend to build packages using NuGet Package Explorer. A lot of my packages have inter-dependencies to others that I've created. My question is how to do I add my package feed into NuGet Package Explorer?
When I browser to it, I get a 401 Unauthorised.
I can get around this by manually editing the metadata, but want to make it easier on myself.
The actual feed has already added Visual Studio, and I can push (via the command line) and pull packages.
VSTS uses an authentication scheme that is not (yet) supported by NuGet Package Explorer. There's a ticket on GitHub regarding the issue: https://github.com/NuGetPackageExplorer/NuGetPackageExplorer/issues/122
The current workaround is indeed doing it using the command line.
Related
I'm having an issue related to team foundation server with Visual Studio 2012.
I've checked in a new solution to the server, however when i get latest version for other machines, most of the references are missing and the .dll files in the bin cannot be located.
Is this because the files are not being pushed when i check in.
Any help is appreciated thanks
In Solution Explorer, right click the DLLs that aren't being included, go to Properties, and be sure that the Build Action is set to "Content".
Check whether you are using MSBuild-Integrated solutions or using Automatic Package Restore. If you use MSBuild-Integrated solutions, migrating MSBuild-Integrated solutions to use Automatic Package Restore.
If you haven't used Nuget to restore package. Check: https://docs.nuget.org/consume/package-restore
Check whether your project link to other projects. Don't reference output assemblies. Make a project reference or create a NuGet package.
I was just reviewing my project's dependencies, and I remembered something I did a while ago.
When I first included the Validation Feature, i browsed servicestack's source, and since it was at ServiceInterface.dll and that wasn't at nuget, I just compiled it manually, and manually included the library. However I want to include it through nuget.
Am I missing something here?
Thanks
(using 3.9.71)
ServiceStack.ServiceInterface.dll has always been included in the ServiceStack v3 NuGet packages, you can inspect the contents of NuGet packages using the NuGet Package Explorer:
Our small, distributed team uses a NuGet package in a project. That package has a bug in the current release. Unfortunately the package does not publish debug symbols and source, so I grabbed & built the latest source, removed the project via NuGet and added a (temporary) reference to the project I just built locally.
Turns out, the issue is fixed in the latest code base.
This particular project only seems to release updates on NuGet every 6 months or so.
Until that next release, our team needs to use the code version where the bug is fixed.
One option certainly is to check the source code into our source code repository and keep the project reference (rather than a NuGet reference), essentially treating it as an internal utility project.
That feels "old school" though.
Is there a better way to manage this situation, using the NuGet infrastructure?
One option is to create your own NuGet package with the updated code. Then add a new Local Package source (just create a file share and place the .nupkg file there). Move the local package source up higher in priority than the official one so NuGet will use your package before looking online.
In fact I recommend copying all NuGet packages to a local repository, especially if you use package restore. This way you are not dependent on nuget.org to be up all the time (there have been several instances of downtime).
The one drawback is that when an updated package is finally published to nuget.org, Update-Package will not pick up the new one unless you specify the package source.
Anyway this will allow you to continue to use NuGet while waiting for your updated package.
I will explain this as best I can!!
I have a large project with a build that kicks off automatically after each checkin. This normally works fine, but this is the first time I have attempted a build that has included code using a library other than those already in the solution.
I have added the Microsoft antixss library (I got it through nuget on my local dev machine). When I checkin, the build fails as nuget on the build server is having trouble getting out to nuget through our proxy.
Obviously the best solution is to get this issue resolved, but it brings up a question of resilience - if our connection to the outside world is mashed, can I not do any builds?
This led me to thinking, is it possible to add libraries such as this antixss to the defaults that always appear in my build servers packages (like jquery etc?). Each build, this packages folder is cleared and replaced by the build process. At the moment, every-time I build the build breaks due to the proxy issue.
I really need to get a release out today, so was wondering if anyone could help me here? It seems silly that I need to go out to Nuget as the library exists on my local!!
Many Many thanks
Install your own nuget server behind the firewall/proxy and point to that as your default NuGet server.
I've used the free version of ProGet in the past as an easy to run a nuget server that also acts as a caching proxy for the main nuget gallery. It also means that if the main nuget server or your internet connection is down you will still have a nuget server that your build can connect to.
Unfortunately, due to issues with Azure's lack of EF 5 spatial support, I need to include the relevant DLL myself: related link
Once I included the SqlServerSpatial.dll I was able to complete successfully deploy by using the Publish tool inside of Visual Studio.
However, when I try to use the Github -> Azure deployment with the relevant DLLs being available in the github repro, the deployment fails with the message:
The process cannot access the file 'C:\DWASFiles\Sites\<my app name>\VirtualDirectory0
\site\wwwroot\bin\SqlServerSpatial.dll' because it is being used by another process.
I'm not really sure how to troubleshoot from here and could use some help. Thanks!
use nuget package manager instead of adding the dll and pushing dlls using git.
PM> Install-Package Microsoft.SqlServer.Types
Ignore the bin folder from git by adding bin/ in .gitignore file
usually adding dlls in source control causing issues and its not a good behavior.