2014-02-18 10 views

Antwort

6

Sie das alles als eine Zeile in dem Package Manager-Konsole einfügen können:

$updates = @{}; Get-Package -Updates | foreach { $updates.Add($_.Id, $_.Version) }; Get-Package | foreach { New-Object Object | Add-Member NoteProperty Name $_.Id -PassThru | Add-Member NoteProperty 'Installed Version' $_.Version -PassThru | Add-Member NoteProperty 'Latest Version' $updates.Get_Item($_.Id) -PassThru }

Dies wird Ihnen Ergebnisse wie geben:

Name          Installed Version Latest Version 
----          ----------------- -------------- 
Antlr          3.4.1.9004   3.5.0.2  
Autofac         3.2.0    3.3.0   
Autofac.Mvc5        3.2.0        
bootstrap         3.0.0    3.1.0   
EntityFramework       6.0.0    6.0.2   
jQuery          1.10.2    2.1.0   
jQuery.Validation       1.11.1       
Microsoft.AspNet.Identity.Core    1.0.0        
Microsoft.AspNet.Identity.EntityFramework 1.0.0        
Microsoft.AspNet.Identity.Owin    1.0.0        
Microsoft.AspNet.Mvc      5.1.0    5.1.1   
Microsoft.AspNet.Razor      3.1.0    3.1.1   
Microsoft.AspNet.Web.Optimization   1.1.1    1.1.2   
Microsoft.AspNet.WebApi     5.0.0    5.1.1   
Microsoft.AspNet.WebApi.Client    5.0.0    5.1.1   
Microsoft.AspNet.WebApi.Core    5.0.0    5.1.1   
Microsoft.AspNet.WebApi.WebHost   5.0.0    5.1.1   
Microsoft.AspNet.WebPages     3.1.0    3.1.1   
Microsoft.jQuery.Unobtrusive.Validation 3.0.0    3.1.1   
Microsoft.Owin        2.0.0    2.1.0   
Microsoft.Owin.Host.SystemWeb    2.0.0    2.1.0   
Microsoft.Owin.Security     2.0.0    2.1.0   
Microsoft.Owin.Security.Cookies   2.0.0    2.1.0   
Microsoft.Owin.Security.Facebook   2.0.0    2.1.0   
Microsoft.Owin.Security.Google    2.0.0    2.1.0   
Microsoft.Owin.Security.MicrosoftAccount 2.0.0    2.1.0   
Microsoft.Owin.Security.OAuth    2.0.0    2.1.0   
Microsoft.Owin.Security.Twitter   2.0.0    2.1.0   
Microsoft.Web.Infrastructure    1.0.0.0       
Modernizr         2.6.2    2.7.1   
Newtonsoft.Json       5.0.6    6.0.1   
Owin          1.0        
RavenDB.Client        2.5.2750       
Respond         1.2.0    1.3.0   
WebGrease         1.5.2    1.6.0   
+0

Wirklich schön, danke! –

+0

Gute Arbeit ........... Manchmal mag ich Nuget, manchmal sehne ich mich nach Apache Ivy (Standalone). – granadaCoder

0

ich das Drehbuch leicht modifiziert, um die Ergebnisse zu speichern in eine Textdatei im Lösungsordner namens [Lösungsdateiname] .nuget.txt. Hier ist das Skript:

$updates = @{}; Get-Package -Updates | foreach { $updates.Add($_.Id, $_.Version) }; $toReview = Get-Package | foreach { New-Object Object | Add-Member NoteProperty Name $_.Id -PassThru | Add-Member NoteProperty 'Installed Version' $_.Version -PassThru | Add-Member NoteProperty 'Latest Version' $updates.Get_Item($_.Id) -PassThru } | sort -Property 'Name' -Unique | Out-File "$($dte.Solution.FileName).nuget.txt" 
Verwandte Themen