full_path stringlengths 31 232 | filename stringlengths 4 167 | content stringlengths 0 48.3M |
|---|---|---|
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DBCS5200_BloodDonor/packages/Modernizr.2.8.3/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DBCS5200_BloodDonor/packages/Newtonsoft.Json.6.0.4/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/jQuery.1.10.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/jQuery.1.10.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/jQuery.1.10.2/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Modernizr.2.6.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Modernizr.2.6.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Modernizr.2.6.2/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/EntityFramework.6.1.3/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIa4AYJKoZIhvcNAQcCoIIa0TCCGs0CAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/EntityFramework.6.1.3/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Microsoft.Bcl.Build.1.0.14/tools/Install.ps1 | Install.ps1 | param($installPath, $toolsPath, $package, $project)
# This is the MSBuild targets file to add
$targetsFile = [System.IO.Path]::Combine($toolsPath, $package.Id + '.targets')
# Need to load MSBuild assembly if it's not loaded yet.
Add-Type -AssemblyName 'Microsoft.Build, Version=4.0.0.0, Culture=ne... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Microsoft.Bcl.Build.1.0.14/tools/Uninstall.ps1 | Uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
# Need to load MSBuild assembly if it's not loaded yet.
Add-Type -AssemblyName 'Microsoft.Build, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
# Grab the loaded MSBuild project for the project
# Normalize project path before calli... |
PowerShellCorpus/Github/sangeethasrk_Assignment_DB_5200/DB_Final_Project/BloodDonorHub/packages/Newtonsoft.Json.6.0.4/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/OPSTest_E2E_Provision_1485029145268/.openpublishing.build.ps1 | .openpublishing.build.ps1 | param(
[string]$buildCorePowershellUrl = "https://opbuildstoragesandbox2.blob.core.windows.net/opps1container/.openpublishing.buildcore.ps1",
[string]$parameters
)
# Main
$errorActionPreference = 'Stop'
# Step-1: Download buildcore script to local
echo "download build core script to local with source u... |
PowerShellCorpus/Github/funkybaboon_ta-scripts/taconvert.ps1 | taconvert.ps1 | # Get Start Time
$startDTM = (Get-Date)
# Maximum numbers of simultaneous conversions
$MaxThreads = 4
# Get current path, set version and target
$version = "v34"
$path = (Get-Item -Path ".\" -Verbose).FullName + "\"
$target = $path + "%03d.jpg"
# 2 dimensional array. first element map, second element scen... |
PowerShellCorpus/Github/funkybaboon_ta-scripts/taconvert_combined.ps1 | taconvert_combined.ps1 | # Get Start Time
$start = (Get-Date)
$array = @()
$array += { convert.exe -density 200 -quality 80 -scene 1 C:\Users\Benni\Desktop\ta2014_combined\Combined_map_trail_note_resupply_Note_for_Map_1_to_10.pdf C:\Users\Benni\Desktop\ta2014_combined\%03d_c.jpg }
$array += { convert.exe -density 200 -quality 80 -scen... |
PowerShellCorpus/Github/gridmaster_ScreenScraper/ScreenScraper/packages/EntityFramework.6.1.0/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIarwYJKoZIhvcNAQcCoIIaoDCCGpwCAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/gridmaster_ScreenScraper/ScreenScraper/packages/EntityFramework.6.1.0/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/gridmaster_ScreenScraper/ScreenScraper/packages/Newtonsoft.Json.6.0.3/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/jQuery.2.1.1/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/jQuery.2.1.1/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/jQuery.2.1.1/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/Newtonsoft.Json.6.0.6/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/EntityFramework.6.1.1/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIa4AYJKoZIhvcNAQcCoIIa0TCCGs0CAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/EntityFramework.6.1.1/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/Modernizr.2.8.3/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/Modernizr.2.8.3/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/kevintsengtw_PagedList.Mvc.Sample/src/packages/Modernizr.2.8.3/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/6mmario_Proyecto1s_201213283_201114496_201220160/API_PROYECTO/packages/EntityFramework.6.1.1/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIa4AYJKoZIhvcNAQcCoIIa0TCCGs0CAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/6mmario_Proyecto1s_201213283_201114496_201220160/API_PROYECTO/packages/EntityFramework.6.1.1/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/6mmario_Proyecto1s_201213283_201114496_201220160/API_PROYECTO/packages/Newtonsoft.Json.6.0.4/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Microsoft.AspNet.Providers.LocalDB.1.1/tools/Install.ps1 | Install.ps1 | param($installPath, $toolsPath, $package, $project)
try {
# Set up variables
$timestamp = (Get-Date).ToString('yyyyMMddHHmmss')
$projectName = [IO.Path]::GetFileName($project.ProjectName.Trim([IO.PATH]::DirectorySeparatorChar, [IO.PATH]::AltDirectorySeparatorChar))
$catalogName = "aspnet-$project... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Modernizr.2.6.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Modernizr.2.6.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Modernizr.2.6.2/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/EntityFramework.5.0.0/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
$importedModule = Get-Module | ?{ $_.Name -eq 'EntityFramework' }
if ($PSVersionTable.PSVersion -ge (New-Object Version @( 3, 0 )))
{
$thisModuleManifest = 'EntityFramework.PS3.psd1'
}
else
{
$thisModuleManifest = 'EntityFramework.psd1'
}
$thisModule... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/EntityFramework.5.0.0/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
function Invoke-ConnectionFactoryConfigurator($assemblyPath, $project)
{
$appDomain = [AppDomain]::CreateDomain(
'EntityFramework.PowerShell',
$null,
(New-Object System.AppDomainSetup -Property @{ ShadowCopyFiles = 'true' }))
... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Microsoft.Bcl.Build.1.0.14/tools/Install.ps1 | Install.ps1 | param($installPath, $toolsPath, $package, $project)
# This is the MSBuild targets file to add
$targetsFile = [System.IO.Path]::Combine($toolsPath, $package.Id + '.targets')
# Need to load MSBuild assembly if it's not loaded yet.
Add-Type -AssemblyName 'Microsoft.Build, Version=4.0.0.0, Culture=ne... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Microsoft.Bcl.Build.1.0.14/tools/Uninstall.ps1 | Uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
# Need to load MSBuild assembly if it's not loaded yet.
Add-Type -AssemblyName 'Microsoft.Build, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
# Grab the loaded MSBuild project for the project
# Normalize project path before calli... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.UI.Combined.1.8.24/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $juiFileNameRegEx |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.UI.Combined.1.8.24/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $juiFileNameRegEx ... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.UI.Combined.1.8.24/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.1.8.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.1.8.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/jQuery.1.8.2/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.WebService/packages/Newtonsoft.Json.6.0.5/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Newtonsoft.Json.7.0.1/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://www.newtonsoft.com/json/install?version=" + $package.Version
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindo... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/jQuery.1.10.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/jQuery.1.10.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/jQuery.1.10.2/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Modernizr.2.6.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Modernizr.2.6.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Modernizr.2.6.2/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Xamarin.Forms.2.0.0.6487/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
# NOTE: the design assemblies must be in a \Design folder within \lib.
# But if we do that, the IDEs will add a reference to it (supposedly
# to be fixed in VS2015 Update 1, but we need to make it backwards
# compatible). Therefore, we just copy the a... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/EntityFramework.6.1.3/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIa4AYJKoZIhvcNAQcCoIIa0TCCGs0CAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/EntityFramework.6.1.3/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/datadruid_XamarinPushNotifications/Datadruid.PushNotifications/packages/Newtonsoft.Json.6.0.4/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/jQuery.1.10.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/jQuery.1.10.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/jQuery.1.10.2/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/EntityFramework.6.0.0/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIarwYJKoZIhvcNAQcCoIIaoDCCGpwCAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/EntityFramework.6.0.0/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Modernizr.2.6.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Modernizr.2.6.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Modernizr.2.6.2/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/EntityFramework.6.1.3/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
if (Get-Module | ?{ $_.Name -eq 'EntityFramework' })
{
Remove-Module EntityFramework
}
Import-Module (Join-Path $toolsPath EntityFramework.psd1)
# SIG # Begin signature block
# MIIa4AYJKoZIhvcNAQcCoIIa0TCCGs0CAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB
# gjcCAQ... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/EntityFramework.6.1.3/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
Initialize-EFConfiguration $project
Add-EFProvider $project 'System.Data.SqlClient' 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer'
Write-Host
Write-Host "Type 'get-help EntityFramework' to see all available Entity Framework comma... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
$compilerPackageName = 'Microsoft.Net.Compilers'
$roslynSubFolder = 'roslyn'
if ($project -eq $null) {
$project = Get-Project
}
$libDirectory = Join-Path $installPath 'lib\net45'
$packageDirectory = Split-Path $installPath
$compilerPackage = Get-Chil... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0/tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
$roslynSubFolder = 'roslyn'
if ($project -eq $null) {
$project = Get-Project
}
$projectRoot = $project.Properties.Item('FullPath').Value
$binDirectory = Join-Path $projectRoot 'bin'
$targetDirectory = Join-Path $binDirectory $roslynSubFolder
if (Te... |
PowerShellCorpus/Github/pnobbe_Tamagotchi/Tamagotchi/packages/Newtonsoft.Json.6.0.4/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
# open json.net splash page on package install
# don't open if json.net is installed as a dependency
try
{
$url = "http://james.newtonking.com/json"
$dte2 = Get-Interface $dte ([EnvDTE80.DTE2])
if ($dte2.ActiveWindow.Caption -eq "Package Manager Con... |
PowerShellCorpus/Github/CodeHQ_EssentialDiagnostics.EntityFramework/src/EssentialDiagnostics.EntityFramework/_CreateNewNuGetPackage/Config.ps1 | Config.ps1 | #==========================================================
# Edit the variable values below to configure how your .nupkg file is packed (i.e. created) and pushed (i.e. uploaded) to the NuGet gallery.
#
# If you have modified this script:
# - if you uninstall the "Create New NuGet Package From Project After Each Bu... |
PowerShellCorpus/Github/CodeHQ_EssentialDiagnostics.EntityFramework/src/EssentialDiagnostics.EntityFramework/_CreateNewNuGetPackage/DoNotModify/UploadNuGetPackage.ps1 | UploadNuGetPackage.ps1 | #==========================================================
# DO NOT EDIT THIS FILE.
# If you want to configure how your package is uploaded, modify the Config.ps1 file.
# To run this script from inside Visual Studio, right-click on the "RunMeToUploadNuGetPackage.cmd" file and choose "Run".
#=======================... |
PowerShellCorpus/Github/CodeHQ_EssentialDiagnostics.EntityFramework/src/EssentialDiagnostics.EntityFramework/_CreateNewNuGetPackage/DoNotModify/New-NuGetPackage.ps1 | New-NuGetPackage.ps1 | #Requires -Version 2.0
<#
.SYNOPSIS
Creates a NuGet Package (.nupkg) file from the given Project or NuSpec file, and optionally uploads it to a NuGet Gallery.
.DESCRIPTION
Creates a NuGet Package (.nupkg) file from the given Project or NuSpec file.
Additional parameters may be provided to also upload the ... |
PowerShellCorpus/Github/CodeHQ_EssentialDiagnostics.EntityFramework/src/EssentialDiagnostics.EntityFramework/_CreateNewNuGetPackage/DoNotModify/CreateNuGetPackage.ps1 | CreateNuGetPackage.ps1 | #==========================================================
# DO NOT EDIT THIS FILE.
# If you want to configure how your package is created, modify the Config.ps1 file.
#
# This script is ran automatically after every successful build.
# This script creates a NuGet package for the current project, and places the .... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/Modernizr.2.6.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $modernizrFileNameRegEx |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/Modernizr.2.6.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $modernizrFileName... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/Modernizr.2.6.2/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/EntityFramework.5.0.0/tools/init.ps1 | init.ps1 | param($installPath, $toolsPath, $package, $project)
$importedModule = Get-Module | ?{ $_.Name -eq 'EntityFramework' }
if ($PSVersionTable.PSVersion -ge (New-Object Version @( 3, 0 )))
{
$thisModuleManifest = 'EntityFramework.PS3.psd1'
}
else
{
$thisModuleManifest = 'EntityFramework.psd1'
}
$thisModule... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/EntityFramework.5.0.0/tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
function Invoke-ConnectionFactoryConfigurator($assemblyPath, $project)
{
$appDomain = [AppDomain]::CreateDomain(
'EntityFramework.PowerShell',
$null,
(New-Object System.AppDomainSetup -Property @{ ShadowCopyFiles = 'true' }))
... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.UI.Combined.1.8.24/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Update the _references.js file
Remove-Reference $scriptsFolderProjectItem $juiFileNameRegEx |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.UI.Combined.1.8.24/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
if ($scriptsFolderProjectItem -eq $null) {
# No Scripts folder
Write-Host "No Scripts folder found"
exit
}
# Update the _references.js file
AddOrUpdate-Reference $scriptsFolderProjectItem $juiFileNameRegEx ... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.UI.Combined.1.8.24/Tools/common.ps1 | common.ps1 | function AddOrUpdate-Reference($scriptsFolderProjectItem, $fileNamePattern, $newFileName) {
try {
$referencesFileProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("_references.js")
}
catch {
# _references.js file not found
return
}
if ($referencesFileProject... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.1.8.2/Tools/uninstall.ps1 | uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# Determine the file paths
$projectIntelliSenseFilePath = Join-Path $projectScriptsFolderPath $intelliSenseFileName
$origIntelliSenseFilePath = Join-Path $toolsPath $intelliSenseFileName
if (Test-Path $projectIntelliSense... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.1.8.2/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
. (Join-Path $toolsPath common.ps1)
# VS 11 and above supports the new intellisense JS files
$vsVersion = [System.Version]::Parse($dte.Version)
$supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
if (-not $supportsJsIntelliSenseFile) {
$displayVersio... |
PowerShellCorpus/Github/swatib04_Demo/SampleArchitecture/packages/jQuery.1.8.2/Tools/common.ps1 | common.ps1 | function Get-Checksum($file) {
$cryptoProvider = New-Object "System.Security.Cryptography.MD5CryptoServiceProvider"
$fileInfo = Get-Item $file
trap { ;
continue } $stream = $fileInfo.OpenRead()
if ($? -eq $false) {
# Couldn't open file for reading
return $null
}
$bytes = $... |
PowerShellCorpus/Github/lkrn_GameTheoryCourse/4_Voting_ZermeloTree.ps1 | 4_Voting_ZermeloTree.ps1 | #region +INPUT
$p1 = @('A','B','C','D')
$p2 = @('D','B','C','A')
$p3 = @('A','C','B','D')
$players = @($p1,$p2,$p3)
#endregion _INPUT
$initPool = New-Object Collections.Generic.List[string]
$p1 | % { $initPool.Add($_) }
$root = @{
Pool = $initPool
Removed = $null
Prev = $null
Next = Ne... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/SymLinks.ps1 | SymLinks.ps1 | $code = @"
using System;
using System.Text;
using System.Runtime.InteropServices;
using Microsoft.Win32.SafeHandles;
using System.ComponentModel;
namespace SymLinkInterop {
public sealed class SymLinkManager
{
private const int FILE_SHARE_READ = 1;
private const int FILE_SHARE_WRITE = 2;
private ... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/lsawrapper.ps1 | lsawrapper.ps1 | Add-Type @'
using System;
using System.Collections.Generic;
using System.Text;
namespace LsaWrapper
{
using System.Runtime.InteropServices;
using System.Security;
using System.Management;
using System.Runtime.CompilerServices;
using System.ComponentModel;
using LSA_HANDLE = IntPtr... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/PuppetAgent.ps1 | PuppetAgent.ps1 | #ps1_sysnative
$ErrorActionPreference = "Stop"
$puppet_master_server_ip = "192.168.209.135"
$puppet_master_server_name = "puppet"
# For Puppet Enterprise replace the following url with:
# "https://pm.puppetlabs.com/cgi-bin/download.cgi?ver=latest&dist=win"
$puppet_agent_msi_url = "https://downloads.puppetla... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/SetupWinRMCertificateAuth.ps1 | SetupWinRMCertificateAuth.ps1 | $ErrorActionPreference = "Stop"
$username = "Administrator"
$password = "Passw0rd"
$client_cert_path = "$(pwd)\cert.pem"
$client_ca_cert_path = "$(pwd)\ca.pem"
# Enable certificate authentication
& winrm set winrm/config/service/auth `@`{Certificate=`"true`"`}
# Import the client cert's CA cert
$cacert ... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/WimFileInfo.ps1 | WimFileInfo.ps1 | <#
.NOTES
MICROSOFT LIMITED PUBLIC LICENSE version 1.1
This license governs use of code marked as “sample” or “example” available on this web site without a license agreement, as provided under the section above titled “NOTICE SPECIFIC TO SOFTWARE AVAILABLE ON THIS WEB SITE.” If you use such code (the “soft... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/DeployTools.ps1 | DeployTools.ps1 | $toolsdir = "C:\Tools"
mkdir $toolsdir
cd $toolsdir
$filename = "7z922-x64.msi"
Invoke-WebRequest -uri "http://freefr.dl.sourceforge.net/project/sevenzip/7-Zip/9.22/7z922-x64.msi" -outFile $filename
Start-Process -Wait msiexec.exe -ArgumentList "/i $filename /qn"
del $filename
$filename="Win32OpenSSL_Light-1... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/UpdateJenkinsSlave.ps1 | UpdateJenkinsSlave.ps1 | # Schedule with:
# schtasks.exe /create /tn Jenkins-Slave-Update /tr "powershell -NonInteractive -File c:\Tools\UpdateJenkinsSlave.ps1" /sc DAILY /ru Administrator /rp /st 01:00:00
$ErrorActionPreference = "Stop"
$jenkinsBaseUrl = "http://10.73.76.93:8080"
$jenkinsSlaveDir = "c:\Jenkins"
$tmpFile = "$jenkins... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/SetupWinRMAccessSelfSigned.ps1 | SetupWinRMAccessSelfSigned.ps1 | $ErrorActionPreference = "Stop"
Import-Module BitsTransfer
$opensslPath = "$ENV:HOMEDRIVE\OpenSSL-Win32"
if($PSVersionTable.PSVersion.Major -lt 4) {
$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition
. "$scriptPath\GetFileHash.ps1"
}
function VerifyHash($filename, $expectedHash) ... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/RunAsUser.ps1 | RunAsUser.ps1 | <#
Copyright 2014 Cloudbase Solutions Srl
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in ... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/build-ws2012r2-image.ps1 | build-ws2012r2-image.ps1 | $ErrorActionPreference = "Stop"
$vmname = "OpenStack WS 2012 R2 Standard Evaluation"
$vhdpath = "C:\VM\windows-server-2012-r2.vhd"
$isoPath = "C:\ISO\9600.16384.WINBLUE_RTM.130821-1623_X64FRE_SERVER_EVAL_EN-US-IRM_SSS_X64FREE_EN-US_DV5.ISO"
$floppyPath = "C:\tools\Autounattend.vfd"
$vmSwitch = "external2"
$vm... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/ServiceUserManagement.ps1 | ServiceUserManagement.ps1 | <#
Copyright 2012 Aaron Jensen (Carbon C# code)
Copyright 2014 Cloudbase Solutions Srl (PowerShell script)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/UpdateAndSysprep.ps1 | UpdateAndSysprep.ps1 | Param(
[switch]$InstallCloudbaseInit
)
$ErrorActionPreference = "Stop"
$Host.UI.RawUI.WindowTitle = "Installing updates..."
Get-WUInstall -AcceptAll -IgnoreReboot
if (Get-WURebootStatus -Silent)
{
$Host.UI.RawUI.WindowTitle = "Updates installation finished. Rebooting."
shutdown /r /t 0
}
else
... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/SetupWinRMCertificateAuthSelfSigned.ps1 | SetupWinRMCertificateAuthSelfSigned.ps1 | $ErrorActionPreference = "Stop"
$username = "Administrator"
$password = "Passw0rd"
$client_cert_path = "$(pwd)\cert.pem"
# Enable certificate authentication
& winrm set winrm/config/service/auth `@`{Certificate=`"true`"`}
# Import the client cert as a CA cert
$clientcert = New-Object System.Security.Cryp... |
PowerShellCorpus/Github/cloudbase_unattended-setup-scripts/SetupClientWinRMCertificateAuth.ps1 | SetupClientWinRMCertificateAuth.ps1 | $ErrorActionPreference = "Stop"
# Setup the WinRM client in an elevated command prompt
#& winrm set winrm/config/client `@`{TrustedHosts=`"*`"`}
#& winrm set winrm/config/client/auth `@`{Certificate=`"true`"`}
$remote_host = "192.168.209.134"
$host_cacert_path = "$(pwd)\ca_winrm.pem"
$client_cert_pfx = "$(pwd... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.