Created
August 13, 2015 13:04
-
-
Save AdamNaj/90d2491735bd4aa5f633 to your computer and use it in GitHub Desktop.
Package Download
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
Import-Module -Name SPE | |
function Retrieve-SitecorePackage($session, $instance, $PackageName, $Destination){ | |
Invoke-WebRequest "$instance/-/script/file/package/?path=$PackageName&user=$($session.Username)&password=$($session.Password)" -OutFile $Destination -WebSession $webSession | |
} | |
$instance = "http://sitecore8" | |
$session = New-ScriptSession -Username admin -Password b -ConnectionUri $instance | |
$packageName = "package.zip" | |
Retrieve-SitecorePackage $session $instance $packageName "$($home)\Downloads\$packageName" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment