Skip to content
This repository has been archived by the owner on Sep 4, 2019. It is now read-only.

Commit

Permalink
Merge pull request #716 from jhorsman/patch-2
Browse files Browse the repository at this point in the history
Update Reinstalling-and-Updating-Packages.md
  • Loading branch information
Kraig Brockschmidt committed Jan 5, 2017
2 parents 5dde426 + d656410 commit db9463e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ In NuGet 3.x with projects using `project.json` to list dependencies, installing

In projects using `packages.config`, the same behavior applies unless you specifically constrain the version range. For example, if you know that your application will work only with version 1.x of a package but not 2.0 and above, perhaps due to a major change in the package API, then you'd want to constrain upgrades to 1.x versions. This prevents accidental updates that would break the application.

To set a constraint, open `packages.config` in a text editor, locate the dependency in question, and add the `allowedVersions` attribute with a version range. For example, to constrain updates to version 1.x, set `allowedVersions` to `[1,2]`:
To set a constraint, open `packages.config` in a text editor, locate the dependency in question, and add the `allowedVersions` attribute with a version range. For example, to constrain updates to version 1.x, set `allowedVersions` to `[1,2)`:

<?xml version="1.0" encoding="utf-8"?>
<packages>
Expand All @@ -66,4 +66,4 @@ To set a constraint, open `packages.config` in a text editor, locate the depende

In all cases, use the notation described in [Dependency versions](/ndocs/create-packages/dependency-versions).



0 comments on commit db9463e

Please sign in to comment.