Created
November 27, 2013 10:14
-
-
Save antonydenyer/7673469 to your computer and use it in GitHub Desktop.
Update all packages in a solution from nuget
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ChildItem -path '.' -Recurse -Include 'packages.config' | | |
Select-Xml -xpath '//package/@id' | | |
Select-Object -ExpandProperty Node | | |
Select-Object -ExpandProperty value | | |
Sort-Object -Unique | | |
ForEach-Object { | |
foreach($arg in $MyInvocation.UnboundArguments) | |
{ | |
if($_ -like $arg) | |
{ | |
update-package $_ | |
} | |
} | |
} | |
[System.Windows.Forms.SendKeys]::SendWait("{F6}") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment