1dotnet-add reference command - .dNoEtTn.eCNtoE-rTaedCdCoLrrIee(f1e)rence command - .NET Core CLI(1)
2
3
4

dotnet-add reference

NAME

7       dotnet add reference - Adds project-to-project (P2P) references.
8

SYNOPSIS

10       dotnet add [<PROJECT>] reference [-f|--framework] <PROJECT_REFER‐
11       ENCES> [-h|--help]
12

DESCRIPTION

14       The dotnet add reference command provides a convenient  option  to  add
15       project  references to a project.  After running the command, the <Pro‐
16       jectReference> elements are added to the project file.
17
18              <ItemGroup>
19                <ProjectReference Include="app.csproj" />
20                <ProjectReference Include="..\lib2\lib2.csproj" />
21                <ProjectReference Include="..\lib1\lib1.csproj" />
22              </ItemGroup>
23
24   Arguments
25       PROJECT
26
27       Specifies the project file.  If not specified, the command searches the
28       current directory for one.
29
30       PROJECT_REFERENCES
31
32       Project-to-project  (P2P)  references  to  add.   Specify  one  or more
33       projects.  Glob patterns are supported on Unix/Linux-based systems.
34

OPTIONS

36       -h|--help
37
38       Prints out a short help for the command.
39
40       -f|--framework <FRAMEWORK>
41
42       Adds project references only when targeting a specific framework.
43

EXAMPLES

45       Add a project reference:
46
47       dotnet add app/app.csproj reference lib/lib.csproj
48
49       Add multiple project references to the project in the current  directo‐
50       ry:
51
52       dotnet add reference lib1/lib1.csproj lib2/lib2.csproj
53
54       Add multiple project references using a globbing pattern on Linux/Unix:
55
56       dotnet add app/app.csproj reference **/*.csproj
57

AUTHORS

59       mairaw.
60
61
62
63                               dotnet-add reference command - .NET Core CLI(1)
Impressum