You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+1-2Lines changed: 1 addition & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,8 +31,7 @@ No contribution is too big or too small--
31
31
If you're creating a new topic, keep the following in mind as well:
32
32
33
33
1. Always place the new topic in an appropriate subfolder, and follow the conventions for filenames as you see them used here.
34
-
1. You must include a metadata block as you see on other topics. The fields you should change are the following: title, ms.date, ms.assetid, description, and keywords.
35
-
1. For ms.assetid, always create a new GUID for a new topic.
34
+
1. You must include a metadata block as you see on other topics. The fields you should change are the following: title, ms.date, description, and keywords.
36
35
1. Leave the ms.author and manager fields set as they are, because these are used to manage ownership internally.
37
36
1. Ideally for SEO, the title field and the top-level # heading of the topic are different; see various topics for examples.
38
37
1. In addition to adding your page, edit docs/TOC.md to add a link to that page.
Copy file name to clipboardExpand all lines: docs/archive/project-json-archive.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,19 +19,19 @@ ms.workload:
19
19
20
20
# project.json archive
21
21
22
-
The `project.json`reference format was introduced with NuGet 3.x and used for certain project types. It was deprecated with the introduction of the PackageReference format, in which dependencies are listed directly in a project file.
22
+
The `project.json`management format was introduced with NuGet 3.x and used for certain project types. It was deprecated with the introduction of the PackageReference format, in which dependencies are listed directly in a project file.
23
23
24
24
Also see:
25
25
26
26
-[project.json schema](project-json.md)
27
27
-[project.json impact on package authors](project-json-impact.md)
28
28
-[project.json and UWP](project-json-and-uwp.md)
29
29
30
-
## project.json reference format
30
+
## project.json management format
31
31
32
32
*Originally in [Package restore](../what-is-nuget.md).*
33
33
34
-
In the list of reference formats:
34
+
In the list of management formats:
35
35
36
36
-[`project.json`](project-json.md): *(deprecated)* A JSON file that maintains a list of the project's dependencies with an overall package graph in an associated file, `project.lock.json`. This format is deprecated in favor of PackageReference.
37
37
@@ -137,7 +137,7 @@ When using the `project.json` format, NuGet also supports using a wildcard notat
137
137
138
138
*Originally in [NuGet.Config reference](../reference/nuget-config-file.md).*
139
139
140
-
`globalPackagesFolder` applies only to `project.json`.
140
+
`globalPackagesFolder` applies only to `project.json`. (Added note: also applies to PackageReference.)
141
141
142
142
### nuspec file reference
143
143
@@ -149,7 +149,7 @@ The `<contentFiles>` element is used instead of `<files>` with `project.json`.
149
149
150
150
*Originally in [Package Manager UI reference](../tools/package-manager-ui.md).*
151
151
152
-
Projects using `project.json` reference format show only the **Show preview window** option.
152
+
Projects using `project.json` management format show only the **Show preview window** option.
Copy file name to clipboardExpand all lines: docs/archive/project-json.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ ms.workload:
21
21
22
22
*NuGet 3.x+*
23
23
24
-
The `project.json` file maintains a list of packages used in a project, known as a package reference format. It supersedes `packages.config` but is in turn superseded by [PackageReference](../consume-packages/package-references-in-project-files.md) with NuGet 4.0+.
24
+
The `project.json` file maintains a list of packages used in a project, known as a package management format. It supersedes `packages.config` but is in turn superseded by [PackageReference](../consume-packages/package-references-in-project-files.md) with NuGet 4.0+.
25
25
26
26
The [`project.lock.json`](#projectlockjson) file (described below) is also used in projects employing `project.json`.
27
27
@@ -121,7 +121,7 @@ Lists the frameworks that the project runs on, such as `net45`, `netcoreapp`, `n
121
121
}
122
122
```
123
123
124
-
Only a single entry is allowed in the `frameworks` section. (An exception is `project.json` files for ASP.NET projects that are build with deprecated DNX toolchain, which allows for multiple targets.)
124
+
Only a single entry is allowed in the `frameworks` section. (An exception is `project.json` files for ASP.NET projects that are build with deprecated DNX tool chain, which allows for multiple targets.)
| Project | Current folder (aka Project folder) or any folder up to the drive root.| In a project folder, settings apply only to that project. In parent folders that contain multiple projects subfolders, settings apply to all projects in those subfolders. |
29
-
| User | Windows: `%APPDATA%\NuGet\NuGet.Config`<br/>Mac/Linux: `~/.nuget/NuGet/NuGet.Config`| Settings apply to all operations, but are overridden by any project-level settings. |
29
+
| User | Windows: `%appdata%\NuGet\NuGet.Config`<br/>Mac/Linux: `~/.nuget/NuGet/NuGet.Config`| Settings apply to all operations, but are overridden by any project-level settings. |
30
30
| Computer | Windows: `%ProgramFiles(x86)%\NuGet\Config`<br/>Mac/Linux: `$XDG_DATA_HOME` (typically `~/.local/share`) | Settings apply to all operations on the computer, but are overriden by any user- or project-level settings. |
31
31
32
32
Notes for earlier versions of NuGet:
@@ -136,7 +136,7 @@ Let's say you have the following folder structure on two separate drives:
136
136
137
137
You then have four `NuGet.Config` files in the following locations with the given content. (The computer-level file is not included in this example, but would behave similarly to the user-level file.)
138
138
139
-
File A. User-level file, (`%APPDATA%\NuGet\NuGet.Config` on Windows, `~/.nuget/NuGet/NuGet.Config` on Mac/Linux):
139
+
File A. User-level file, (`%appdata%\NuGet\NuGet.Config` on Windows, `~/.nuget/NuGet/NuGet.Config` on Mac/Linux):
140
140
141
141
```xml
142
142
<?xml version="1.0" encoding="utf-8"?>
@@ -219,7 +219,7 @@ The following table describes where the `NuGetDefaults.Config` file should be st
219
219
220
220
### NuGetDefaults.Config settings
221
221
222
-
-`packageSources`: this collection has the same meaning as `packageSources` in regular config files and specifies the default sources. NuGet uses the sources in order when installing or updating packages in projects using the `packages.config`reference format. For projects using the PackageReference format, NuGet uses local sources first, then sources on network shares, then HTTP sources, regardless of the order in the configuration files. NuGet always ignores the order of sources with restore operations.
222
+
-`packageSources`: this collection has the same meaning as `packageSources` in regular config files and specifies the default sources. NuGet uses the sources in order when installing or updating packages in projects using the `packages.config`management format. For projects using the PackageReference format, NuGet uses local sources first, then sources on network shares, then HTTP sources, regardless of the order in the configuration files. NuGet always ignores the order of sources with restore operations.
223
223
224
224
-`disabledPackageSources`: this collection also has the same meaning as in `NuGet.Config` files, where each affected source is listed by its name and a true/false value indicating whether it's disabled. This allows the source name and URL to remain in `packageSources` without having it turned on by default. Individual developers can then re-enable the source by setting the source's value to false in other `NuGet.Config` files without having to find the correct URL again. This is also useful to supply developers with a full list of internal source URLs for an organization while enabling only an individual team's source by default.
Copy file name to clipboardExpand all lines: docs/consume-packages/Dependency-Resolution.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,7 +23,7 @@ Any time a package is installed or reinstalled, which includes being installed a
23
23
24
24
Those immediate dependencies might then also have dependencies on their own, which can continue to an arbitrary depth. This produces what's called a *dependency graph* that describes the relationships between packages at all levels.
25
25
26
-
When multiple packages have the same dependency, then the same package ID can appear in the graph multiple times, potentially with different version constraints. However, only one version of a given package can be used in a project, so NuGet must choose which version is used. The exact process depends on the package reference format being used.
26
+
When multiple packages have the same dependency, then the same package ID can appear in the graph multiple times, potentially with different version constraints. However, only one version of a given package can be used in a project, so NuGet must choose which version is used. The exact process depends on the package management format being used.
27
27
28
28
## Dependency resolution with PackageReference
29
29
@@ -108,7 +108,7 @@ With `packages.config`, NuGet attempts to resolve dependency conflicts during th
108
108
109
109
By default, NuGet 2.8 looks for the lowest patch version (see [NuGet 2.8 release notes](../release-notes/nuget-2.8.md#patch-resolution-for-dependencies)). You can control this setting through the `DependencyVersion` attribute in `Nuget.Config` and the `-DependencyVersion` switch on the command line.
110
110
111
-
The `packages.config` process for resolving dependencies gets complicated for larger dependency graphs. Each new package installation requires a traversal of the whole graph and raises the chance for version conflicts. When a conflict occurs, installation is stopped, leaving the project in an indeterminate state, especially with potential modifications to the project file itself. This is not an issue when using other package reference formats.
111
+
The `packages.config` process for resolving dependencies gets complicated for larger dependency graphs. Each new package installation requires a traversal of the whole graph and raises the chance for version conflicts. When a conflict occurs, installation is stopped, leaving the project in an indeterminate state, especially with potential modifications to the project file itself. This is not an issue when using other package management formats.
112
112
113
113
## Managing dependency assets
114
114
@@ -120,7 +120,7 @@ When the top-level project is itself a package, you also have control over this
120
120
121
121
There are scenarios in which assemblies with the same name might be referenced more than once in a project, producing design-time and build-time errors. Consider a project that contains a custom version of `C.dll`, and references Package C that also contains `C.dll`. At the same time, the project also depends on Package B which also depends on Package C and `C.dll`. As a result, NuGet can't determine which `C.dll` to use, but you can't just remove the project's dependency on Package C because Package B also depends on it.
122
122
123
-
To resolve this, you must directly reference the `C.dll` you want (or use another package that references the right one), and then add a dependency on Package C that excludes all its assets. This is done as follows depending on the package reference format in use:
123
+
To resolve this, you must directly reference the `C.dll` you want (or use another package that references the right one), and then add a dependency on Package C that excludes all its assets. This is done as follows depending on the package management format in use:
124
124
125
125
-[PackageReference](../consume-packages/package-references-in-project-files.md): add `Exclude="All"` in the dependency:
0 commit comments