Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

208
Vistas
How to properly share a VS project with references to another computer

I have a project here that compiles fine, but it uses a reference to a DLL that is not from NuGet. I added it using References-Add Reference-Browse.

Unfortunately, the reference appears (from clicking on properties of the reference in Solution explorer) that the DLL location is [project dir\bin\debug] and [project dir\bin\release]. These don't seem appropriate directories to add to source control to share to another computer. It also doesn't seem right that I would add both directories.

So the end result when I transfer to another computer, is of course "are you missing a reference?".

What I want to do: Put the reference in a directory under my solution, add it to source control, and add the reference to Visual Studio using that path.

I can't see how to accomplish this, or anything like it, except to add the DLL in every build configuration directory to source control.

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Direct reference

I think what you're doing is almost correct. You just have to make sure that when you add the reference you point to the right file.

  1. Put the library into a folder, e.g. ThirdPartyLibs.
  2. Add the file to git (e.g. with git add).
  3. Add the reference to project with Add Reference... and point to the file file in the newly created folder. You may want to set it up as Copy Local.

Nuget way

One option is to have a local nuget source:

  1. Package a library as nuget package and put in a local folder inside your git repo, e.g. MyLocalNuget

  2. Add NuGet.config at the solution level. Example:

    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
    <solution>
        <add key="Local NuGet" value="MyLocalNuget"/>
    </solution>
    <packageSources>
        <clear /> 
        <add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
    </packageSources>
    </configuration>
    
  3. Add the library to the projects using normal NuGet way.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda