/// <summary>
		/// If the package version is already installed then there is no need to install the 
		/// NuGet package.
		/// </summary>
		bool ShouldRemoveExistingPackageReference (PackageReference packageReference, PackageIdentity packageIdentity)
		{
			var existingPackageReference = packageReference.ToNuGetPackageReference ();
			return !VersionComparer.Default.Equals (existingPackageReference.PackageIdentity.Version, packageIdentity.Version);
		}
Пример #2
0
        /// <summary>
        /// If the package version is already installed then there is no need to install the
        /// NuGet package.
        /// </summary>
        bool ShouldRemoveExistingPackageReference(PackageReference packageReference, PackageIdentity packageIdentity)
        {
            var existingPackageReference = packageReference.ToNuGetPackageReference();

            return(!VersionComparer.Default.Equals(existingPackageReference.PackageIdentity.Version, packageIdentity.Version));
        }