Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $url = 'https://commandcenter.blob.core.windows.net/dos/CommandCenter.latest.zip?sv=2018-03-28&si=dos-1661D6B74D7&sr=b&sig=%2B7CMpQyjCkuNnTAPZHLw%2FgRoZ8oR%2BUKFrZxlTbpHXNo%3D'
- $filename = 'CommandCenter.latest.zip'
- $folder = $filename.replace('.zip','')
- $path = 'c:\install'
- if(!(Test-Path -Path $path)){
- mkdir -Path $path
- }
- Push-Location $path
- Remove-Item ".\$folder" -Recurse -ErrorAction Ignore
- Remove-Item ".\$filename" -ErrorAction Ignore
- Invoke-WebRequest -Uri $url -outfile ".\$filename"
- Expand-Archive -Path ".\$filename" -DestinationPath ".\$folder"
- Import-Module ".\$folder\CommandCenter.psm1" -Force
- Push-Location "$path\CommandCenter.latest\menus"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement