Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dotnet add reference #4

Open
marcialwushu opened this issue Jan 19, 2021 · 0 comments
Open

dotnet add reference #4

marcialwushu opened this issue Jan 19, 2021 · 0 comments
Labels
documentation Improvements or additions to documentation help wanted Extra attention is needed

Comments

@marcialwushu
Copy link
Owner

Este artigo aplica-se a: ✔️ SDK do .NET Core 2. x e versões posteriores

Nome

dotnet add reference – Adiciona as referências P2P (projeto a projeto).

Sinopse

CLI do .NET Core

dotnet add [<PROJECT>] reference [-f|--framework <FRAMEWORK>]
     [--interactive] <PROJECT_REFERENCES>

dotnet add reference -h|--help

Descrição

O comando dotnet add reference fornece uma opção conveniente para adicionar referências de projeto a um projeto. Depois de executar o comando, os elementos <ProjectReference> são adicionados ao arquivo de projeto.

XML

<ItemGroup>
  <ProjectReference Include="app.csproj" />
  <ProjectReference Include="..\lib2\lib2.csproj" />
  <ProjectReference Include="..\lib1\lib1.csproj" />
</ItemGroup>

Argumentos

  • PROJECT

Especifica o arquivo do projeto. Se não for especificado, o comando pesquisará um no diretório atual.

  • PROJECT_REFERENCES

Referências P2P (projeto a projeto) a serem adicionadas. Especifique um ou mais projetos. Os padrões Glob são compatíveis com sistemas baseados em Unix/Linux.

Exemplos

Adicionar referência de projeto:

CLI do .NET Core

dotnet add app/app.csproj reference lib/lib.csproj

https://docs.microsoft.com/pt-br/dotnet/core/tools/dotnet-add-reference

@marcialwushu marcialwushu added documentation Improvements or additions to documentation help wanted Extra attention is needed labels Jan 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant