full_path stringlengths 31 232 | filename stringlengths 4 167 | content stringlengths 0 48.3M |
|---|---|---|
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/GlobalList/Set-TfsGlobalList.ps1 | Set-TfsGlobalList.ps1 | <#
.SYNOPSIS
Changes the name or the contents of a Global List.
.PARAMETER Collection
${HelpParam_Collection}
.INPUTS
System.String
#>
Function Set-TfsGlobalList
{
Param
(
[Parameter(Mandatory=$true, ValueFromPipelineByPropertyName='Name')]
[string]
$Name... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Dismount-TfsTeamProjectCollection.ps1 | Dismount-TfsTeamProjectCollection.ps1 | <#
.SYNOPSIS
Detaches a team project collection database from a Team Foundation Server installation.
.PARAMETER Credential
${HelpParam_Credential}
.PARAMETER Collection
${HelpParam_Collection}
.INPUTS
Microsoft.TeamFoundation.Client.TfsConfigurationServer
System.String
System.Uri
... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Get-TfsTeamProjectCollection.ps1 | Get-TfsTeamProjectCollection.ps1 | <#
.SYNOPSIS
Gets information about one or more team project collections.
.DESCRIPTION
The Get-TfsTeamProjectCollection cmdlets gets one or more Team Project Collection objects (an instance of Microsoft.TeamFoundation.Client.TfsTeamProjectCollection) from a TFS instance.
Team Project Collection objects ca... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Stop-TfsTeamProjectCollection.ps1 | Stop-TfsTeamProjectCollection.ps1 | <#
.PARAMETER Credential
${HelpParam_Credential}
.INPUTS
Microsoft.TeamFoundation.Client.TfsTeamProjectCollection
System.String
System.Uri
#>
Function Stop-TfsTeamProjectCollection
{
Param
(
[Parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
[object]
$Collection,... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Start-TfsTeamProjectCollection.ps1 | Start-TfsTeamProjectCollection.ps1 | <#
.PARAMETER Credential
${HelpParam_Credential}
.INPUTS
Microsoft.TeamFoundation.Client.TfsTeamProjectCollection
System.String
System.Uri
#>
Function Start-TfsTeamProjectCollection
{
Param
(
[Parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
[object]
$Collection,
... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Remove-TfsTeamProjectCollection.ps1 | Remove-TfsTeamProjectCollection.ps1 | <#
.SYNOPSIS
Deletes a team project collection
.PARAMETER Credential
${HelpParam_Credential}
.INPUTS
Microsoft.TeamFoundation.Client.TfsTeamProjectCollection
System.String
System.Uri
#>
Function Remove-TfsTeamProjectCollection
{
[CmdletBinding(ConfirmImpact="High", SupportsShouldProc... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/New-TfsTeamProjectCollection.ps1 | New-TfsTeamProjectCollection.ps1 | <#
.SYNOPSIS
Creates a new team project collection.
.PARAMETER Credential
${HelpParam_Credential}
.INPUTS
System.String
#>
Function New-TfsTeamProjectCollection
{
Param
(
[Parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
[string]
$Name,
[Parameter()]
[stri... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Get-TfsRegisteredTeamProjectCollection.ps1 | Get-TfsRegisteredTeamProjectCollection.ps1 | <#
.SYNOPSIS
Gets one or more Team Project Collection addresses registered in the current computer.
.PARAMETER Name
Specifies the name of a registered collection. When omitted, all registered collections are returned. Wildcards are permitted.
.INPUTS
System.String
#>
Function Get-TfsRegisteredTe... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/TeamProjectCollection/Mount-TfsTeamProjectCollection.ps1 | Mount-TfsTeamProjectCollection.ps1 | <#
.SYNOPSIS
Attaches a team project collection database to a Team Foundation Server installation.
.PARAMETER Credential
${HelpParam_Credential}
.INPUTS
Microsoft.TeamFoundation.Client.TfsConfigurationServer
System.String
System.Uri
#>
Function Mount-TfsTeamProjectCollection
{
Param
... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/Admin/Get-TfsInstallationPath.ps1 | Get-TfsInstallationPath.ps1 | <#
.SYNOPSIS
Gets the installation path of a given Team Foundation Server component.
.PARAMETER Computer
The machine name of the server where the TFS component is installed. It must be properly configured for PowerShell Remoting in case it's a remote machine. If omitted, defaults to the local machine wher... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/Admin/_RegistryHelpers.ps1 | _RegistryHelpers.ps1 | Function Test-RegistryValue
{
Param
(
[Parameter(Mandatory=$true)]
[ValidateNotNullOrEmpty()]
$Path,
[Parameter(Mandatory=$true)]
[ValidateNotNullOrEmpty()]
$Value
)
Process
{
try
{
Get-RegistryValue -Path $Path -Value $Value | Out-Null
return $true
}
catch {}
r... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/Admin/_RemotingHelpers.ps1 | _RemotingHelpers.ps1 | Function New-ScriptBlock($EntryPoint, [string[]]$Dependency)
{
$entryPoint = (Get-Item "function:$EntryPoint").Definition.Trim()
$paramSection = $entryPoint.Substring(0, $entryPoint.IndexOf("`n"))
$bodySection = $entryPoint.Substring($paramSection.Length) + "`n`n"
$body = $paramSection
foreach($depFn in... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/PS/Admin/_AdminHelpers.ps1 | _AdminHelpers.ps1 | |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/Tests/GlobalList.Tests.ps1 | GlobalList.Tests.ps1 | . "$(Split-Path -Parent $MyInvocation.MyCommand.Path)\_TestSetup.ps1"
InModuleScope TfsCmdlets {
Describe "New-TfsGlobalList" {
Mock Import-TfsGlobalLists { } -ModuleName GlobalList
Mock Export-TfsGlobalLists {
return [xml]'<GLOBALLISTS>
<GLOBALLIST name="List1">
<LISTITEM val... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/Tests/Correctness.Tests.ps1 | Correctness.Tests.ps1 | . "$(Split-Path -Parent $MyInvocation.MyCommand.Path)\_TestSetup.ps1"
InModuleScope TfsCmdlets {
Describe "Correctness Tests: Parameters" {
Context "Parameters with wildcards" {
It "Has SupportsWildcards attribute" {
}
}
}
Describe "Correctness Tes... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/Tests/ConfigServer.Tests.ps1 | ConfigServer.Tests.ps1 | . "$(Split-Path -Parent $MyInvocation.MyCommand.Path)\_TestSetup.ps1"
InModuleScope TfsCmdlets {
Describe "Connect-TfsConfigurationServer" {
Mock _NewConfigServer {
@{
Url = $Url;
Credential = $Cred
}
} -ModuleName Connection
Context "When passing URL w/o creds" {
$expectedUr... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/Tests/Connection.Tests.ps1 | Connection.Tests.ps1 | . "$(Split-Path -Parent $MyInvocation.MyCommand.Path)\_TestSetup.ps1"
InModuleScope TfsCmdlets {
Describe "Connect-TfsConfigurationServer" {
Mock _NewConfigServer {
@{
Url = $Url;
Credential = $Cred
}
} -ModuleName Connection
Context "When passing URL w/o creds" {
$expectedUr... |
PowerShellCorpus/Github/igoravl_tfscmdlets/src/Tests/_TestSetup.ps1 | _TestSetup.ps1 | $outputDir = Join-Path (Split-Path $MyInvocation.MyCommand.Path -Parent) '..\out' -Resolve
$modulePath = Join-Path $projectDir 'Module\TfsCmdlets.psd1'
$hasBuild = Test-Path $modulePath
if (-not $hasBuild)
{
throw "Module TfsCmdlets not found at $modulePath. Build project TfsCmdlets.Build prior to running te... |
PowerShellCorpus/Github/mgreenegit_xRemoteAccess/Examples/xDscResourceDesigner_CreateScript.ps1 | xDscResourceDesigner_CreateScript.ps1 | $modules = 'C:\Program Files\WindowsPowerShell\Modules\'
$modulename = 'xRemoteAccess'
$Description = 'This module is used to configure RRAS settings, with focus on Azure site to site VPN.'
if (!(test-path (join-path $modules $modulename))) {
$modulefolder = mkdir (join-path $modules $modulename)
$exam... |
PowerShellCorpus/Github/mgreenegit_xRemoteAccess/Examples/AzureS2S.ps1 | AzureS2S.ps1 | #NOTE: Values below are examples and will not actually work. Replace with real values from Azure network for your subscription.
Configuration AzureS2S
{
Import-DscResource -ModuleName 'xRemoteAccess','PSDesiredStateConfiguration'
Node $AllNodes.where{$_.Role -eq 'LocalNetworkS2SGateway'}.NodeName
{... |
PowerShellCorpus/Github/Montigomo_PowerToys/Init.ps1 | Init.ps1 |
# to do
[System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
function msgBox($x){
[System.Windows.Forms.MessageBox]::Show($x, 'Done!:PowerShell',
[Windows.Forms.MessageBoxButtons]::OK,
[Windows.Forms.MessageBoxIcon]::Information, [Windows.Forms.MessageBoxDefaultButton]::Button1,
... |
PowerShellCorpus/Github/Montigomo_PowerToys/profiles/profile.ps1 | profile.ps1 |
# Agitech 2015.08.11
function PromptBad
{
#(Get-Host).UI.RawUI.WindowTitle="PS $(Get-Location)"
#"PS > "
(Get-Host).UI.RawUI.WindowTitle="PS $(Get-Location)"
Write-Host ("PS " + $(get-location) +">") -nonewline -foregroundcolor Magenta
return " "
}
$impModules = @("agt*", "Pscx", "Pos... |
PowerShellCorpus/Github/Montigomo_PowerToys/profiles/Microsoft.PowerShell_profile.ps1 | Microsoft.PowerShell_profile.ps1 | |
PowerShellCorpus/Github/Montigomo_PowerToys/profiles/Microsoft.PowerShellISE_profile.ps1 | Microsoft.PowerShellISE_profile.ps1 | |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Set-TimeZone.ps1 | Set-TimeZone.ps1 | # ==============================================================================================
#
# NAME: Set-TimeZone.ps1
#
# AUTHOR: Ben Baird
#
# Description:
# Sets the current time zone based on the standard name
# of the time zone ("Mountain Standard Time", "Pacific
# Standard Time", etc.).
#
# A ... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Add-Tasks.ps1 | Add-Tasks.ps1 |
$taskCommand = [system.io.path]::Combine($PSScriptRoot, $ccfolder, "ccminer.exe")
$taskArgument = " -a x11 -o stratum+tcp://eu.p2pool.pl:7903 -u XyA45YJvpxvs1CemBvMwHMA643zsNN8Mrf -p x --cpu-priority 3"
if((Test-Path variable:global:TASK_TRIGGER_EVENT) -eq $false)
{
# typedef enum {
New-Variable -Name TASK_... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Get-Telnet.ps1 | Get-Telnet.ps1 | <#
.SYNOPSIS
Simple script to connect to a server using Telnet, issue commands and
capture all of the output.
.DESCRIPTION
I wrote this script to connect to my Extreme Network switches and download
their configuration. I've also gotten it to work on Dell switches, though
I had to adjust the ... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Set-DriveLetters.ps1 | Set-DriveLetters.ps1 |
# this script assign to all cd drives on the PC letterrs from ((char)Z - cddrives.Count) to Z
# before : cddrive1 - G: cddrive2 - H: cddrive3 - I:
# after : cddrive1 - X: cddrive2 - Y: cddrive3 - Z:
# GLYBS [Good Luck to You & Best Scripts]
$cddrives = Get-WMIObject -Class Win32_CDROMDrive -ComputerNam... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Install-Fonts.ps1 | Install-Fonts.ps1 |
function Install-Fonts
{
[CmdletBinding()]
param(
[Parameter(Mandatory=$true, Position=0)]
[Alias('From')]
[string]$FromPath
)
Begin{}
Process
{
$FONTS = 0x14
$objShell = New-Object -ComObject Shell.Application
$objFolder = $objS... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Get-NetTools.ps1 | Get-NetTools.ps1 |
Add-Type -AssemblyName PresentationFramework
#Build the GUI
[xml]$xaml = @"
<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
x:Name="Window" Title="Putty helper" WindowStartupLocation = "CenterScreen" ResizeMode="NoRe... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Get-Hosts.ps1 | Get-Hosts.ps1 | # Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding ... |
PowerShellCorpus/Github/Montigomo_PowerToys/Scripts/Work-WithSettings.ps1 | Work-WithSettings.ps1 |
[void] [System.Reflection.Assembly]::LoadWithPartialName("System.Drawing")
[void] [System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
$settingFolder = (Get-KnownFolderPath -KnownFolder OneDriveFolder) + '\Powershell\Scripts\settings'
#if((Test-Path variable:global:SETTING_OPTIONS) -eq ... |
PowerShellCorpus/Github/mattmcnabb_Canvas/tests/Canvas.tests.ps1 | Canvas.tests.ps1 | $ProjectPath = Split-Path $PSScriptRoot
if ($env:APPVEYOR)
{
$ModuleName = $env:Appveyor_Project_Name
$Version = $env:APPVEYOR_BUILD_VERSION
}
else
{
$ModuleName = Split-Path $ProjectPath -Leaf
$Version = "0.1.0"
}
$ModulePath = Join-Path $ProjectPath $ModuleName
Import-Module $ModulePat... |
PowerShellCorpus/Github/mattmcnabb_Canvas/tests/common.tests.ps1 | common.tests.ps1 | $ProjectPath = Split-Path $PSScriptRoot
if ($env:APPVEYOR)
{
$ModuleName = $env:Appveyor_Project_Name
$Version = $env:APPVEYOR_BUILD_VERSION
}
else
{
$ModuleName = Split-Path $ProjectPath -Leaf
$Version = "0.1.0"
}
$ModulePath = Join-Path $ProjectPath $ModuleName
$ManifestPath = Join-Pat... |
PowerShellCorpus/Github/mattmcnabb_Canvas/build/deploy.ps1 | deploy.ps1 | if ($env:APPVEYOR_REPO_COMMIT_MESSAGE -match "^!Deploy")
{
$ModulePath = Join-Path $env:APPVEYOR_BUILD_FOLDER $env:APPVEYOR_PROJECT_NAME
Import-Module PowerShellGet -Force
Publish-Module -Path $ModulePath -NuGetApiKey ($env:PSGallery_Api_Key) -Confirm:$false
}
|
PowerShellCorpus/Github/mattmcnabb_Canvas/build/build.ps1 | build.ps1 | $ProjectPath = Split-Path $PSScriptRoot
if ($env:APPVEYOR)
{
$ModuleName = $env:APPVEYOR_PROJECT_NAME
$Version = $env:APPVEYOR_BUILD_VERSION
$TestExit = $true
}
else
{
$ModuleName = Split-Path $ProjectPath -Leaf
$Version = '0.1.0'
$TestExit = $false
}
$ModulePath = Join-Path... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/helpers/Set-CanvasDefaultCredential.ps1 | Set-CanvasDefaultCredential.ps1 | function Set-CanvasDefaultConnection
{
[CmdletBinding(SupportsShouldProcess, ConfirmImpact = "Medium")]
param
(
[Canvas.Connection]
$Connection
)
$ModuleName = $PSCmdlet.MyInvocation.MyCommand.Module.Name
$Module = Get-Module -Name $ModuleName
$global:Commands = $... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/helpers/Get-NextPageNumber.ps1 | Get-NextPageNumber.ps1 | function Get-NextPageNumber
{
[CmdletBinding()]
param
(
[Parameter(Mandatory=$false)]
[string]
$Link
)
$NextPage = ($Link -split "," | Where-Object {$_ -like '* rel="next"'}) -split ";| |<|>" |
Where-Object {$_} | Select-Object -First 1
$null = ... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/helpers/Get-ValidUrl.ps1 | Get-ValidUrl.ps1 | function Get-ValidUrl
{
[CmdletBinding()]
[OutputType([string])]
param
(
[Parameter(Mandatory = $true)]
[ValidateScript({
[System.Uri]::IsWellFormedUriString($_, "Absolute")
})]
[string]
$Url
)
$OutputUrl = switch -Regex ($U... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/helpers/Invoke-CanvasRestMethod.ps1 | Invoke-CanvasRestMethod.ps1 | function Invoke-CanvasRestMethod
{
[CmdletBinding()]
param
(
[string]
$Method,
[Parameter(Mandatory)]
[string]
$Url,
[Parameter(Mandatory)]
[string]
$ApiBase,
[Parameter(Mandatory)]
[string]
... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/functions/Get-CanvasAccount.ps1 | Get-CanvasAccount.ps1 | function Get-CanvasAccount
{
[CmdletBinding()]
param
(
[Parameter(Mandatory)]
[Canvas.Connection]
$Connection,
[int]
$Identity,
[switch]
$Recurse
)
BEGIN
{
$Splat = @{
Method = "Get"
... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/functions/New-CanvasConnection.ps1 | New-CanvasConnection.ps1 | function New-CanvasConnection
{
[CmdletBinding()]
param
(
[Parameter(Mandatory = $true)]
[ValidateScript({
[System.Uri]::IsWellFormedUriString($_, "Absolute")
})]
[System.Uri]
$CanvasUrl,
[Parameter(Mandatory = $true)]
[int]
... |
PowerShellCorpus/Github/mattmcnabb_Canvas/Canvas/functions/Get-CanvasUser.ps1 | Get-CanvasUser.ps1 | function Get-CanvasUser
{
[CmdletBinding(DefaultParameterSetName = "Filter")]
param
(
[Parameter(Mandatory = $true, ParameterSetName = "Identity")]
[Parameter(Mandatory = $true, ParameterSetName = "Filter")]
[Parameter(Mandatory = $true, ParameterSetName = "All")]
[Ca... |
PowerShellCorpus/Github/djceola_ansible/Windows/disable_ieesc.ps1 | disable_ieesc.ps1 | $AdminKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A7-37EF-4b3f-8CFC-4F3A74704073}"
$UserKey = "HKLM:\SOFTWARE\Microsoft\Active Setup\Installed Components\{A509B1A8-37EF-4b3f-8CFC-4F3A74704073}"
Set-ItemProperty -Path $AdminKey -Name "IsInstalled" -Value 0
Set-ItemProperty -Path $UserKey ... |
PowerShellCorpus/Github/kedonov_SkyTest/.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/pastperfect_ProjectFileManagement/Functions/Create-ProjectFolder.ps1 | Create-ProjectFolder.ps1 | function Create-ProjectFolder
{
Param
(
# Project Details
[Parameter(Mandatory=$true,
ValueFromPipelineByPropertyName=$true,
Position=0)]
$ProjectDetails,
# Project Details
[Parameter(Mandatory=$true,
... |
PowerShellCorpus/Github/pastperfect_ProjectFileManagement/Functions/Get-ProjectProperties.ps1 | Get-ProjectProperties.ps1 | function Get-ProjectProperties
{
[CmdletBinding()]
Param
(
# Name of the project
[Parameter(Mandatory=$true,
Position=0)]
$ProjectName,
# Description of the project
[Parameter(Mandatory=$true,
Position=1)]
$D... |
PowerShellCorpus/Github/pastperfect_ProjectFileManagement/Functions/Get-ProjectLocations.ps1 | Get-ProjectLocations.ps1 | function Get-ProjectLocations
{
Param
(
# Private Storage Area
[Parameter(Mandatory=$true,
Position=0)]
$Private,
# Public Storage Area
[Parameter(Mandatory=$true,
Position=1)]
$Public
)
Begin
{
... |
PowerShellCorpus/Github/pastperfect_ProjectFileManagement/Functions/Get-Projects.ps1 | Get-Projects.ps1 | function Get-Projects
{
[CmdletBinding()]
Param
(
# Project Register location
[Parameter(Mandatory=$true,
Position=0)]
$ProjectRegister
)
Begin
{
IF (!( Test-Path $ProjectRegister)) { THROW "Unable to find Project Register" }
... |
PowerShellCorpus/Github/pastperfect_ProjectFileManagement/Functions/Update-ProjectRegister.ps1 | Update-ProjectRegister.ps1 | function Update-ProjectRegister
{
[CmdletBinding()]
Param
(
# Project Register location
[Parameter(Mandatory=$true,
Position=0)]
$ProjectRegister,
# Details for the new project
[Parameter(Mandatory=$true,
Position=1)]... |
PowerShellCorpus/Github/pastperfect_ProjectFileManagement/Functions/Load-Project.ps1 | Load-Project.ps1 | function Load-Project
{
[CmdletBinding()]
Param
(
# Project Register location
[Parameter(Mandatory=$true,
Position=0)]
$ProjectRegister
)
Begin
{
IF (!( Test-Path $ProjectRegister)) { THROW "Unable to find Project Register" }
... |
PowerShellCorpus/Github/jemolina_WCF/MyFirstServiceWCF/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/jemolina_WCF/MyFirstServiceWCF/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/OPSTest_E2E_Provision_1486559141807/.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/serbrech_cRavenDB/bump.ps1 | bump.ps1 | throw "NotImplemented" |
PowerShellCorpus/Github/serbrech_cRavenDB/Publish.ps1 | Publish.ps1 | param(
[string]$apiKey,
[string]$version
)
if(!$version){
throw "set a version carefully"
}
$modulepath = Resolve-Path "$PSScriptRoot/DSCResources/cRavenDB"
if(-not ($Env:PSModulePath.Split(";") -contains $modulepath)){
$Env:PSModulePath = "$modulepath;$Env:PSModulePath"
}
Publish-Module ... |
PowerShellCorpus/Github/serbrech_cRavenDB/Tests/Integration/cRavenDB.Tests.ps1 | cRavenDB.Tests.ps1 | $Global:DSCModuleName = 'cRavenDB'
$Global:DSCResourceName = 'cRavenDB'
#region HEADER
[String] $moduleRoot = Split-Path -Parent (Split-Path -Parent (Split-Path -Parent $Script:MyInvocation.MyCommand.Path))
Write-Debug "ModuleRoot : $moduleRoot"
if ( (-not (Test-Path -Path (Join-Path -Path $moduleRoot -ChildPa... |
PowerShellCorpus/Github/serbrech_cRavenDB/Tests/Integration/cRavenDB.config.ps1 | cRavenDB.config.ps1 | configuration cRavenDB_Config
{
Import-DscResource -ModuleName cRavenDB
cRavenDB installRavenDB
{
Name = "RavenDB-test"
Version = "3.5.35113-Unstable"
#PackagePath = "C:\gitwp\AzureResourceTemplates\src\RavenDb\DSC\cRavenDB\Tests\Integration\packagesource\RavenDB.Server.3.... |
PowerShellCorpus/Github/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/ryanhelms_ryanhelms.com/RepositoryPattern/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/OPS-E2E-PPE_E2E_NewRepo_2017_3_29_20_5_34/.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/POSHChef_pester_cookbook/files/default/POSHChef/Pester/files/default/pester-test-handler.ps1 | pester-test-handler.ps1 |
function Test-Handler {
<#
.SYNOPSIS
Handler to run Pester tests on the server
.DESCRIPTION
This is a test handler that uses Pester to invoke tests.
The default recipe should be include in the run list to ensure that the Pester module is installed and that this
... |
PowerShellCorpus/Github/POSHChef_pester_cookbook/files/default/POSHChef/Pester/recipes/default.ps1 | default.ps1 |
# Recipes in POSHChef are built up using the new 'Configuration' keyword from DSC
# The follwing snippet shows how to build up the Default recipe
Configuration Pester_Default {
<#
.SYNOPSIS
Copies the Test handler to the correct location on disk
#>
[CmdletBinding()]
param... |
PowerShellCorpus/Github/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/packages/Microsoft.ApplicationInsights.WindowsServer.2.2.0/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
if ([System.IO.File]::Exists($project.FullName))
{
function MarkItemASCopyToOutput($item)
{
Try
{
#mark it to copy if newer
$item.Properties.Item("CopyToOutputDirectory").Value = 2
}
Catch
{
write-host $_.Exception.ToString()
}... |
PowerShellCorpus/Github/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/MihA-aa_DBCourseWork/CourseDB/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/aspeninazure_SCENEBAU-001/folderToSync/CreateVM.ps1 | CreateVM.ps1 | Param(
[Parameter (Mandatory = $true)]
[string]$MasterResourceGroup,
[Parameter (Mandatory = $true)]
[string]$MasterNetworkName,
[Parameter (Mandatory = $true)]
[string]$MasterStorageAccountName,
[Parameter (Mandatory = $true)]
[string]$NewResourceGroupName,
[Parameter (Mandatory =... |
PowerShellCorpus/Github/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/packages/Newtonsoft.Json.10.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/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/packages/Microsoft.ApplicationInsights.WindowsServer.2.2.0/Tools/install.ps1 | install.ps1 | param($installPath, $toolsPath, $package, $project)
if ([System.IO.File]::Exists($project.FullName))
{
function MarkItemASCopyToOutput($item)
{
Try
{
#mark it to copy if newer
$item.Properties.Item("CopyToOutputDirectory").Value = 2
}
Catch
{
write-host $_.Exception.ToString()
}... |
PowerShellCorpus/Github/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/packages/Microsoft.Web.Infrastructure.1.0.0.0/tools/Install.ps1 | Install.ps1 | param($installPath, $toolsPath, $package, $project)
if ($project.Type -eq 'Web Site') {
Import-Module (Join-Path $toolsPath VS.psd1)
$srcFiles = Join-Path $installPath "lib\net40\*.dll"
$projectRoot = Get-ProjectRoot $project
if (!$projectRoot) {
return;
}
$destDirec... |
PowerShellCorpus/Github/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/packages/Microsoft.Web.Infrastructure.1.0.0.0/tools/Uninstall.ps1 | Uninstall.ps1 | param($installPath, $toolsPath, $package, $project)
if ($project.Type -eq 'Web Site') {
Import-Module (Join-Path $toolsPath VS.psd1)
$projectRoot = Get-ProjectRoot $project
if (!$projectRoot) {
return;
}
$binDirectory = Join-Path $projectRoot "bin"
$srcDirectory = Join-Path $... |
PowerShellCorpus/Github/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/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/satsnik_RASBERRYVAGAS/AcheiVaga.PI4/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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/sabihami_ThinkTank/ThinkTank/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... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.