code
stringlengths
2
1.05M
repo_name
stringlengths
5
101
path
stringlengths
4
991
language
stringclasses
3 values
license
stringclasses
5 values
size
int64
2
1.05M
$ErrorActionPreference = 'Stop' $packageArgs = @{ packageName = 'aptana-studio' fileType = 'exe' softwareName = 'Aptana Studio' checksum = '5b3640243d3451514f2a6e869ea574a704590bbb8dfdd352bfd6c3d5993b173e' checksumType = 'sha256' url = 'https://github.com/aptana/studio3/rele...
jberezanski/chocolatey-coreteampackages
automatic/aptana-studio/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
486
# ---------------------------------------------------------------------------------- # # Copyright Microsoft Corporation # 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...
devigned/azure-powershell
src/ResourceManager/Dns/Commands.Dns.Test/ScenarioTests/ZoneTests.ps1
PowerShell
apache-2.0
13,048
# Include the following modules $Dir = Split-Path $script:MyInvocation.MyCommand.Path . ([System.IO.Path]::Combine($Dir, "utils\write_messages.ps1")) # Windows version 10 and up have support for binary format $check = [System.Environment]::OSVersion.Version.Major -ge 10 $result = @{ result = $check } Write-Output...
taliesins/vagrant
plugins/providers/hyperv/scripts/has_vmcx_support.ps1
PowerShell
mit
355
# Updates the version of project.json function Update-PackageVersion([string]$ProjectPath, [int]$BuildNumber = 0) { if ([String]::IsNullOrWhiteSpace($ProjectPath)) { Write-Host "ProjectPath not provided" -ForegroundColor White -BackgroundColor Red return } if ($BuildNumber -le 0) { Write-Host "Invalid Build...
devkimchi/ASP.NET-Core-DevOps-Sample
src/AspNetCoreDevOpsSample.PsScripts/Update-PackageVersion.ps1
PowerShell
mit
683
param( [string] $Project , [ValidateSet('Rebuild', 'Build', 'Clean')] [string] $build = "Build" , [ValidateSet('Debug', 'Release')] [string] $config = "Release" , [string] $MSBuildVerbosity = "quiet" ) & "$(get-content env:windir)\Microsoft.NET\Framework\v4.0.30319...
rzhw/Squirrel.Windows
script/Build-Solution.ps1
PowerShell
mit
409
<# .Description Installs and loads all the required modules for the build. Derived from scripts written by Warren F. (RamblingCookieMonster) #> [CmdletBinding()] param ( $Task = 'Default' ) Write-Output "Starting build" # Grab nuget bits, install modules, set build variables, start build. Write-Output " ...
sqlwhale/PSRedgate
build.ps1
PowerShell
mit
1,217
################################################################################ ## File: Install-GoogleCloudSDK.ps1 ## Desc: Install Google Cloud SDK ################################################################################ # https://cloud.google.com/sdk/docs/downloads-interactive $googleCloudSDKInstaller ...
mattgwagner/New-Machine
.github-actions/images/win/scripts/Installers/Install-GoogleCloudSDK.ps1
PowerShell
mit
628
<# .SYNOPSIS .DESCRIPTION .PARAMETER Credential #> [CmdletBinding()] Param ( [PSCredential] $Credential ) if (!($Credential)) { $Credential = Get-Credential } Connect-MSOLService -Credential $Credential
JeB94/PoSh
Office365&Exchange/Connect-Office365.ps1
PowerShell
mit
244
<# PRSP - pratom Sniffed Parameter #> Function PRSP ( $entry, $parameter_count ) { assert_caller_is_in_my_directory $properties = ( parameter_properties $entry ) switch ($properties["name"]) { "ForegroundColor" { return "" } "NoNewline" { return "" } defa...
pratom/master
nucleus/neutrons/logging/over_sniffed/PRSP.ps1
PowerShell
mit
2,622
function Get-ActivationID{ $output = cscript C:\Windows\System32\slmgr.vbs /dlv $activationID = $output | Where-Object { $_.Contains("Activation ID") } return $activationID.Replace("Activation ID:", "").Trim() } function Uninstall-ProductKey{ $activationID = Get-ActivationID cscript C:\Windows\Sys...
Conroman16/PowerShellLib
ProductKeyUninstaller.ps1
PowerShell
mit
408
function Get-TargetResource { [CmdletBinding()] [OutputType([System.Collections.Hashtable])] param ( [parameter(Mandatory = $true)] [System.String] $WebAppUrl, [parameter(Mandatory = $true)] [System.String] $SuperUserAlias, [parameter(Mandatory = $true)] [System.String] $Su...
wulfland/xSharePoint
Modules/xSharePoint/DSCResources/MSFT_xSPCacheAccounts/MSFT_xSPCacheAccounts.psm1
PowerShell
mit
7,282
# Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. # IMPORTANT: Do not invoke this file directly. Please instead run eng/common/New-TestResources.ps1 from the repository root. #Requires -Version 6.0 #Requires -PSEdition Core # Use same parameter names as declared in eng/com...
Azure/azure-sdk-for-java
sdk/digitaltwins/test-resources-post.ps1
PowerShell
mit
1,130
#requires -Version 3 function Get-RubrikAvailabilityGroup { <# .SYNOPSIS Retrieves details on one or more Avaialbility Group known to a Rubrik cluster .DESCRIPTION The Get-RubrikAvailabilityGroup cmdlet is used to pull a detailed data set from a Rubrik cluster on any number of Availability ...
rubrikinc/PowerShell-Module
Rubrik/Public/Get-RubrikAvailabilityGroup.ps1
PowerShell
mit
3,431
$packageName = '{{PackageName}}' $packageSearch = 'Nirsoft shexview' $installerType = 'exe' $silentArgs = '/S' $validExitCodes = @(0) try { Get-ItemProperty -Path @( 'HKLM:\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\*', 'HKLM:\Software\Microsoft\Windows\CurrentVersion\...
maharishi/chocolatey-packages
automatic/shexview.install/tools/chocolateyUninstall.ps1
PowerShell
apache-2.0
973
<# .SYNOPSIS Enables the 'unsafe' connection mode for WinRM by enabling basic authentication and unencrypted connections. .DESCRIPTION The Set-UnsafeConnectionModeForWinRm script enables the 'unsafe' connection mode for WinRM by enabling basic authentication and unencrypted connections....
ops-resource/ops-tools-baseimage
src/windows/scripts/Set-UnsafeConnectionModeForWinRm.ps1
PowerShell
apache-2.0
1,173
function Enable-StrongAuthentication { [CmdletBinding()] param ( [Parameter(Mandatory=$false)] [bool]$Net35, [Parameter(Mandatory=$false)] [bool]$Net4or5, [Parameter(Mandatory=$false)] [string]$ComputerName ) try { $ErrorActionPreference = 'Stop'; $Error.Clear(); if ($Net35) { $RegPath = '...
jeffpatton1971/SchannelManagement
SchannelManagement/StrongAuthentication/StrongAuthentication.psm1
PowerShell
apache-2.0
1,159
[xml]$commonProps = Get-Content -Path $PSScriptRoot\Common.props $microsoftCodeCoveragePkgVer = [string]$commonProps.Project.PropertyGroup.MicrosoftCodeCoveragePkgVer # This is collected in the format: "[16.10.0]" $microsoftCodeCoveragePkgVer = $microsoftCodeCoveragePkgVer.Trim(); $microsoftCodeCoveragePkgVer = $micro...
open-telemetry/opentelemetry-dotnet
build/process-codecoverage.ps1
PowerShell
apache-2.0
853
$packageName = 'gtksharp' $installerType = 'msi' $silentArgs = '/quiet /qn /norestart' $url = 'https://dl.xamarin.com/GTKforWindows/Windows/gtk-sharp-2.12.44.msi' $checksum = '1f7d358043a5aa56d805022d4efd0956c64e662f24b564b53e4e9d3849248d3b' $checksumType = 'sha256' $validExitCodes = @(0) Install-ChocolateyPackage -P...
dtgm/chocolatey-packages
automatic/_output/gtksharp/2.12.44/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
664
# 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 writing, software # distributed under ...
episource/my-chocolatey
extensions/conemu-task.extension/extensions/flags.ps1
PowerShell
apache-2.0
6,053
param($installPath, $toolsPath, $package, $project) Import-Module (Join-Path $toolsPath common.psm1) -Force try { # Indicates if current project is a VB project $IsVbProject = ($project.CodeModel.Language -eq [EnvDTE.CodeModelLanguageConstants]::vsCMLanguageVB) if ($IsVbProject) { # Remove ...
shoshannabudzianowski/GatewayForMicrosoftSAPApps
SAP2SharePointSample/packages/AppForSharePoint16WebToolkit.3.0.1/Tools/uninstall.ps1
PowerShell
apache-2.0
13,041
<# .SYNOPSIS Short description .DESCRIPTION Long description .EXAMPLE PS C:\> <example usage> Explanation of what the example does .INPUTS Inputs (if any) .OUTPUTS Output (if any) .NOTES General notes #> function Get-SqlAvailabilityGroup { [CmdLetBinding()] Param( [Paramete...
MarvTheRobot/AutomatedDeploymentEngine
mtr.ADE/Functions/Get-SqlAvailabilityGroup.ps1
PowerShell
apache-2.0
3,531
function New-VSEC2Volume { <# .SYNOPSIS Adds an AWS::EC2::Volume resource to the template. Specifies an Amazon Elastic Block Store (Amazon EBS volume. .DESCRIPTION Adds an AWS::EC2::Volume resource to the template. Specifies an Amazon Elastic Block Store (Amazon EBS volume. When you use AW...
scrthq/Vaporshell
VaporShell/Public/Resource Types/New-VSEC2Volume.ps1
PowerShell
apache-2.0
23,753
[CmdletBinding()] param() Trace-VstsEnteringInvocation $MyInvocation # Get inputs for the task $sourcePath = Get-VstsInput -Name SourcePath -Require $destination = Get-VstsInput -Name Destination -Require $connectedServiceName = Get-VstsInput -Name ConnectedServiceNameARM -Require $storageAccount = Get-VstsInput -Nam...
Microsoft/vso-agent-tasks
Tasks/AzureFileCopyV3/AzureFileCopy.ps1
PowerShell
mit
11,875
convertfrom-stringdata @' AdvtCaption = PLOC: Confirm install AdvtDescription = PLOC: Installing advertised features for product, {0}. AdvtWarning = PLOC: Are you sure you want to install advertised features for product, {0}? '@
SamB/psmsi
test/PowerShell.Test/Data/qps-ploc/Resources.psd1
PowerShell
mit
243
Describe 'NestedModules' -Tags "CI" { Import-Module $PSScriptRoot\..\LanguageTestSupport.psm1 function New-TestModule { param( [string]$Name, [string]$Content, [string[]]$NestedContents ) new-item -type directory -Force "Test...
jsoref/PowerShell
test/powershell/Language/Classes/scripting.Classes.NestedModules.tests.ps1
PowerShell
mit
5,056
# Copyright © 2011 - Present RealDimensions Software, LLC # # 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 applica...
dshaneg/choco
src/chocolatey.resources/helpers/functions/Format-FileSize.ps1
PowerShell
apache-2.0
924
#Enhanced user report Get-ADUser -filter 'enabled -eq $true' -properties passwordlastset, LastLogonTimestamp, sAMAccountName, Title, physicalDeliveryOfficeName, manager -SearchBase "OU=CAH_Users,DC=colonyah,DC=local" | Select-object Name, Title, physicalDeliveryOfficeName, @{Name='Manager';Expression={(get-adu...
EmpressDeIT/PowerShell
ISE_Tabs/AD_PasswordExpiredList.ps1
PowerShell
mit
2,337
$ScriptPath = Split-Path $MyInvocation.MyCommand.Path . "$ScriptPath\..\0-CommonInit.ps1" # Try to figure out the context in which DSC runs # Thanks Lee Holmes for the script psedit "$ScriptPath\Get-ProcessOwner.ps1" psedit "$ScriptPath\ProcessOwner.ps1" # compile and invoke the configuration . "$ScriptPath\ProcessO...
nanalakshmanan/DemosSept2015
RunAs/Demo.ps1
PowerShell
mit
1,016
# Copy resultant exes to the bin folder in my home dir, which is on my path. Copy-Item SetVersion\bin\Release\dnv.exe $ENV:USERPROFILE\bin -Verbose Copy-Item UpdateNuGetDeps\bin\Release\updeps.exe $ENV:USERPROFILE\bin -Verbose
PhilipDaniels/dotnetversioning
install.ps1
PowerShell
mit
232
Import-Module -Name (Join-Path -Path $PSScriptRoot -ChildPath '..\TestHelpers\CommonTestHelper.psm1') # Run only for SQL 2017 integration testing. if (-not (Test-BuildCategory -Type 'Integration' -Category @('Integration_SQL2017'))) { return } $script:dscModuleName = 'SqlServerDsc' $script:dscResourceFriendlyName...
nabrond/xSQLServer
tests/Integration/MSFT_SqlRSSetup.Integration.Tests.ps1
PowerShell
mit
6,661
<# .Synopsis Installs or uninstalls the Clean Software Update Groups console extension for ConfigMgr. .DESCRIPTION Configures settings for and installs a console extension to remove expired and superseded updates from software update groups in ConfigMgr. .PARAMETER SiteServer Specifies the name of the Sit...
cburfordjr/SCCMScripts
CleanSoftwareUpdateGroups/Install-CleanSoftwareUpdateGroups.ps1
PowerShell
mit
28,548
############################################################################ ### ### ### NUGET PACKAGE and PUBLISH ### ### ### #######...
PureKrome/NLog.Bugsnag
NuGet/NuGet Package and Publish.ps1
PowerShell
mit
6,481
Function Test-FileExists { param($Path) If ($Path -eq '') { Return $false } Else { Return Test-Path -Path $Path } } Function Test-Property { #// Function provided by Jeffrey Snover #// Tests if a property is a memory of an object. param ([Paramete...
clinthuffman/PAL
PAL2/PALWizard/bin/Debug/BuildAutoDetectThresholdFile.ps1
PowerShell
mit
12,896
sal msbuild "c:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe" msbuild .\MvcDoodle.build /target:Default
tugberkugurlu/MvcDoodle
build.ps1
PowerShell
mit
113
# # Module manifest for module 'cSQLServerTraceFlag' # # Generated by: Gareth # # Generated on: 8/21/2016 # @{ # Script module or binary module file associated with this manifest. RootModule = 'cSQLServerTraceFlag.psm1' # Version number of this module. ModuleVersion = '1.0.1.0' # ID used to uniquel...
Zuldan/cSQLServerTraceFlag
cSQLServerTraceFlag.psd1
PowerShell
mit
3,336
#Source: https://weblog.west-wind.com/posts/2017/May/25/Automating-IIS-Feature-Installation-with-Powershell #This script installs IIS and the features required to run asp.net applications # * Make sure you run this script from an Admin Prompt! # * Make sure Powershell Execution Policy is bypassed to run these scripts...
mattgwagner/New-Machine
Configure-IIS.ps1
PowerShell
mit
2,619
<# Usage Update-TestPlanAfterMigration -SourceCollectionUri "http://typhoontfs:8080/tfs/defaultcollection" -TargetCollectionUri "http://typhoontfs:8080/tfs/defaultcollection" -SourceTeamProjectName "Scrum TFVC Source" -TargetTeamProjectName "NewProject” #> function Update-TestPlanAfterMigration { ...
rfennell/VSTSPowershell
DOTNET/Update-TestPlanAfterMigration.ps1
PowerShell
mit
9,626
#requires -Modules PowerShellGet $ReleaseNotes =@' ExifDateTime Chris Warwick, @cjwarwickps, August 2013 This version: November 2015 The module contains two functions: Get-ExifDateTaken -Path <filepaths> Takes a file (fileinfo or string) or an array of these Gets the ExifDT val...
ChrisWarwick/ExifDateTime
PublishPsGalleryModule.ps1
PowerShell
mit
5,273
function Format-IISBindings { <# .SYNOPSIS Formats the output of Get-IISBindings.ps1 .EXAMPLE Get-IISBindings | Format-IISBindings.ps1 This script must be dot sourced (i.e., run '. .\Format-UserSessions') #> [CmdletBinding()] param ( [Parameter(Mandatory=$fal...
brsh/BGInfoConfigs
Scripts/PowerShell/Formats/Format-IISBindings.ps1
PowerShell
mit
1,136
param($installPath, $toolsPath, $package, $project) Add-EFDefaultConnectionFactory $project 'System.Data.Entity.Infrastructure.SqlCeConnectionFactory, EntityFramework' -ConstructorArguments 'System.Data.SqlServerCe.4.0' Add-EFProvider $project 'System.Data.SqlServerCe.4.0' 'System.Data.Entity.SqlServerCompact.SqlCePro...
liyanippon/working
data/work/asp.net/WebApplication1/packages/EntityFramework.SqlServerCompact.6.2.0/tools/install.ps1
PowerShell
apache-2.0
10,036
$packageName = 'dolphin' $url = 'https://dl.dolphin-emu.org/builds/dolphin-master-5.0-4956-x64.7z' $checksum = 'b0c4d3e17d26effbdcd5c8ef3f336debf9b92485f0f7b9e0b56a891fb35e3090' $checksumType = 'sha256' $url64 = $url $checksum64 = $checksum $checksumType64 = $checksumType $toolsDir = "$(Split-Path -parent $MyInvocation...
dtgm/chocolatey-packages
automatic/_output/dolphin/5.0.4956/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
788
Import-Module .\TestLibs\RDFELibs.psm1 -Force $result = "" $testResult = "" $resultArr = @() $isDeployed = DeployVMS -setupType $currentTestData.setupType -Distro $Distro -xmlConfig $xmlConfig if ($isDeployed) { $vm1added = $false foreach ($VMdata in $allVMData) { if ($VMdata.RoleName -imatch $currentTestData.set...
FreeBSDonHyper-V/azure-freebsd-automation
remote-scripts/NETWORK-LB-NO-PROBE-PORT-NO-PROBE-MESSAGES.ps1
PowerShell
apache-2.0
6,820
param($installPath, $toolsPath, $package, $project) Import-Module (join-path $toolsPath "upgrade.psm1") -ArgumentList $installPath Import-Module (join-path $toolsPath "ConvertDatabaseToUtc.psm1") # SIG # Begin signature block # MIIZDwYJKoZIhvcNAQcCoIIZADCCGPwCAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB # gjcCAQSgWzBZMDQGCisGAQQB...
episerver/EPiTranslateFlowDemo
src/packages/EPiServer.Framework.9.7.1/tools/init.ps1
PowerShell
apache-2.0
9,217
# The authentication key (API Key). # Get your own by registering at https://app.pdf.co $API_KEY = "***********************************" # Source PDF file url $SourceFileUrl = "https://bytescout-com.s3.amazonaws.com/files/demo-files/cloud-api/document-parser/MultiPageTable.pdf" # Destination JSON file name $Destinati...
bytescout/ByteScout-SDK-SourceCode
PDF.co Web API/Document Parser API/Powershell/Parse From Url/ParseFromUrl.ps1
PowerShell
apache-2.0
1,552
param( [Parameter(Mandatory=$true)] [string] $location ) if($location -like "*china*") { Login-AzureRmAccount -EnvironmentName AzureChinaCloud } else { Login-AzureRmAccount Select-AzureRmSubscription -SubscriptionId 812441bb-dd47-463f-8ded-fcc8c95f9754 } Get-AzureRmResourceGroup |?{$_.ResourceG...
catweisun/ARMDeploymentDemo
MultiLayerApplicationDeployment/cleanup.ps1
PowerShell
apache-2.0
530
# Copyright 2011 - Present RealDimensions Software, LLC & original authors/contributors from https://github.com/chocolatey/chocolatey # # 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 # ...
kouweizhong/choco
src/chocolatey.resources/helpers/functions/Get-CheckSumValid.ps1
PowerShell
apache-2.0
2,790
#cleanup del C:\temp\config\* -Force -Recurse -ea 0 #Make sure HelloProvider module is copied to "$env:ProgramFiles\WindowsPowerShell\Modules" #configuration is like a function defination, you need to invoke main explicitly #Each resource is associated with a schema and imperative provider configuration main { I...
padisetty/Samples
DSC/Resource Provider Sample/HelloProvider.ps1
PowerShell
apache-2.0
1,855
function New-VSEMRInstanceGroupConfig { <# .SYNOPSIS Adds an AWS::EMR::InstanceGroupConfig resource to the template. Use InstanceGroupConfig to define instance groups for an EMR cluster. A cluster can not use both instance groups and instance fleets. For more information, see Create a Cluster with Insta...
scrthq/Vaporshell
VaporShell/Public/Resource Types/New-VSEMRInstanceGroupConfig.ps1
PowerShell
apache-2.0
20,034
function Add-VSWAFByteMatchSetByteMatchTuple { <# .SYNOPSIS Adds an AWS::WAF::ByteMatchSet.ByteMatchTuple resource property to the template. **Note** .DESCRIPTION Adds an AWS::WAF::ByteMatchSet.ByteMatchTuple resource property to the template. **Note** This is **AWS WAF Classic** documenta...
scrthq/Vaporshell
VaporShell/Public/Resource Property Types/Add-VSWAFByteMatchSetByteMatchTuple.ps1
PowerShell
apache-2.0
12,022
$configuration = @{ "Bitbucket Server" = @{ "Executable" = "java -jar -noverify bitbucket-backup-client.jar"; "WorkingDirectory" = "C:\Atlassian\Bitbucket\bitbucket-backup-client-2.0.0"; }; "ServiceName" = "AtlassianBitbucket"; "MaxSecondsWaitingForService" = 300; "SendMailBeforeBackup" = $TRUE; "SendMailA...
armin-pfaeffle/bitbucket-server-backup-client-script
configuration.ps1
PowerShell
mit
761
#region Globals from all three scripts # Service Names $TransportServiceName = "MsExchangeTransport" $MessageTracing = "MSMessageTracingClient" $EdgeSync = "MsExchangeEdgeSync" $Script:OriginalPref = $ErrorActionPreference $Script:ExchangeServer = $null $Script:TransportService = $null...
cowofevil/puppetlabs-dsc
lib/puppet_x/dsc_resources/xExchange/DSCResources/MSFT_xExchMaintenanceMode/TransportMaintenance.psm1
PowerShell
apache-2.0
77,196
# ---------------------------------------------------------------------------------- # # Copyright Microsoft Corporation # 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...
AzureAutomationTeam/azure-powershell
src/ResourceManager/RecoveryServices/Commands.RecoveryServices.Backup.Test/ScenarioTests/AzureFiles/PolicyTests.ps1
PowerShell
apache-2.0
3,651
<# The MIT License (MIT) Copyright (c) 2015 Objectivity Bespoke Software Specialists Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights t...
Invenis/PSCI
PSCI/Private/utils/Get-AllBytes.ps1
PowerShell
mit
1,619
param($installPath, $toolsPath, $package, $project) $sqliteReference = $project.Object.References.Find("SQLite.WP81, version=3.8.7.2") if ($sqliteReference -eq $null) { Write-Host "Unable to find a reference to the extension SDK SQLite for Windows Phone 8.1." Write-Host "Verify that the reference to th...
fabianwilliams/t4s
packages/SQLitePCL.3.8.7.2/tools/wpa81/uninstall.ps1
PowerShell
apache-2.0
543
<# .Synopsis Launches Python with the specified worker on a Microsoft Azure Cloud Service .Description This script is deployed with your worker role and is used to launch the correct version of Python with the worker script. You may freely modify it to customize how your worker is run, though most cust...
DinoV/PTVS
Python/Templates/Web/ProjectTemplates/Python/Web/WorkerRoleProject/LaunchWorker.ps1
PowerShell
apache-2.0
3,712
$CopyJob = { param ( [string]$fqdn, [string]$sourcePath, [string]$targetPath, [object]$credential, [string]$cleanTargetBeforeCopy, [string]$winRMPort, [string]$httpProtocolOption, [string]$skipCACheckOption ) Get-ChildItem $env:AGENT_HOMEDIRECTORY\Agent\Worker\*.dll | % { [void][ref...
robrich/vso-agent-tasks
Tasks/WindowsMachineFileCopy/WindowsMachineFileCopyJob.ps1
PowerShell
mit
1,372
#!powershell # Copyright: (c) 2014, Trond Hindenes <trond@hindenes.com> # Copyright: (c) 2017, Dag Wieers <dag@wieers.com> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # WANT_JSON # POWERSHELL_COMMON $ErrorActionPreference = 'Stop' # As of chocolatey 0.9.10, non-zero ...
e-gob/plataforma-kioscos-autoatencion
scripts/ansible-play/.venv/lib/python2.7/site-packages/ansible/modules/windows/win_chocolatey.ps1
PowerShell
bsd-3-clause
15,363
@{ RootModule = 'vTrainingLab.schema.psm1'; ModuleVersion = '1.0'; GUID = '99942d22-ba5b-47f8-ab7a-06c31bbe2a36'; Author = 'Iain Brighton'; CompanyName = 'Virtual Engine'; Copyright = '(c) 2016 Virtual Engine Limited. All rights reserved.'; Description = 'Complete Virtual Engine train...
VirtualEngine/VirtualEngineTrainingLab
DSCResources/vTrainingLab/vTrainingLab.psd1
PowerShell
mit
372
function Get-DbaDatabaseSpace { <# .SYNOPSIS Returns database file space information for database files on a SQL instance. .DESCRIPTION This function returns database file space information for a SQL Instance or group of SQL Instances. Information is based on a query against...
SirCaptainMitch/dbatools
functions/Get-DbaDatabaseSpace.ps1
PowerShell
mit
13,007
Write-Host $PSScriptRoot Publish-Module -Path $PSScriptRoot\bin\Release\Cmdlet-AssemblyInfo\ -NuGetApiKey XXXXXXX
emilw/Cmdlet-AssemblyInfo
Cmdlet-AssemblyInfo/PublishToPowershellGet.ps1
PowerShell
mit
117
$CommandName = $MyInvocation.MyCommand.Name.Replace(".Tests.ps1", "") Write-Host -Object "Running $PSCommandPath" -ForegroundColor Cyan . "$PSScriptRoot\constants.ps1" Describe "$CommandName Unit Tests" -Tag 'UnitTests' { Context "Validate parameters" { [object[]]$params = (Get-Command $CommandName).Parame...
dsolodow/dbatools
tests/Get-DbaFile.Tests.ps1
PowerShell
mit
2,010
$script:ResourceRootPath = Split-Path -Path (Split-Path -Path $PSScriptRoot -Parent) # Import the xNetworking Resource Module (to import the common modules) Import-Module -Name (Join-Path -Path $script:ResourceRootPath -ChildPath 'xNetworking.psd1') # Import Localization Strings $localizedData = Get-LocalizedData ` ...
tysonjhayes/xNetworking
Modules/xNetworking/DSCResources/MSFT_xDhcpClient/MSFT_xDhcpClient.psm1
PowerShell
mit
6,316
import-module au . $PSScriptRoot\..\_scripts\all.ps1 $domain = "http://www.nurgo-software.com" $version_url = "$domain/company/news/20-tidytabs" $download_url = "$domain/pricing/tidytabs" if ($MyInvocation.InvocationName -ne '.') { # run the update only if the script is not sourced function global:au_SearchRepla...
EntranceJew/chocolatey-packages
tidytabs.portable/update.ps1
PowerShell
mit
1,266
param( [parameter(Mandatory=$true)] [string]$buildConfiguration ) $workingPath = (new-object system.io.directoryinfo $PSScriptRoot).parent.fullname $outpath = $workingPath $project = $workingPath | split-path -leaf if([string]::IsNullOrWhitespace($buildConfiguration)) { $buildConfiguration = "debug" } Write-H...
SogetiUSA/PasswordManager
scripts/coverage.ps1
PowerShell
mit
2,743
#region HEADER $script:DSCModuleName = 'xExchange' $script:DSCResourceName = 'MSFT_xExchImapSettings' # Unit Test Template Version: 1.2.4 $script:moduleRoot = Split-Path -Parent (Split-Path -Parent $PSScriptRoot) if ( (-not (Test-Path -Path (Join-Path -Path $script:moduleRoot -ChildPath 'DSCResource.Tests'))) -or ` ...
IngoGege/xExchange
Tests/Unit/MSFT_xExchImapSettings.tests.ps1
PowerShell
mit
8,253
. ..\utils\make-exercise-repo.ps1 Set-Content -Value "hello æøå`r`n" -Path file1.txt git checkout -b master
praqma-training/gitkatas
git-attributes/setup.ps1
PowerShell
mit
113
#requires -Version 2 -Modules posh-git Set-PSReadlineOption -AddToHistoryHandler { $script:LastCommandStart = get-date; Update-ZLocation $pwd $true } # this is copy-paste-adapted from the `paradox` theme function Write-Theme { param( [bool] $lastCommandFailed, [string] ...
scottbilas/dotfiles
config/posh/_old/themes/Scodark.psm1
PowerShell
mit
9,716
# Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. param( [switch] $NoRestore ) $here = Split-Path -Parent $MyInvocation.MyCommand.Path dotnet --version if ($NoRestore) { Write-Output "*** Skipping pa...
stuartleeks/nether
build.ps1
PowerShell
mit
1,761
Restart-Computer
openstack-hyper-v/puppet-windowsClustering
files/RestartComputer.ps1
PowerShell
apache-2.0
16
$fn = $MyInvocation.MyCommand.Name; Set-Variable gotoSuccess -Option 'Constant' -Value 'biz.dfch.System.Exception.gotoSuccess'; Set-Variable gotoError -Option 'Constant' -Value 'biz.dfch.System.Exception.gotoError'; Set-Variable gotoFailure -Option 'Constant' -Value 'biz.dfch.System.Exception.gotoFailure'; Set-Variabl...
dfch/biz.dfch.PS.Ipam.Infoblox.Api
biz.dfch.PS.Ipam.Infoblox.Api.psm1
PowerShell
apache-2.0
6,673
$here = Split-Path -Parent $MyInvocation.MyCommand.Path $sut = (Split-Path -Leaf $MyInvocation.MyCommand.Path).Replace(".Tests.", ".") function Stop-Pester() { [Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseShouldProcessForStateChangingFunctions", "")] PARAM ( $message = "EMERGENCY: Script cannot conti...
dfensgmbh/biz.dfch.PS.Appclusive.Client
src/Get-User.Tests.ps1
PowerShell
apache-2.0
12,561
$packageName = '{{PackageName}}' $fileType = 'exe' $silentArgs = '/S' $validExitCodes = @(0) $unPath = "HKCU:SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" $unString=(Get-ItemProperty "$unpath\$packageName*" UninstallString).UninstallString) try { Uninstall-ChocolateyPackage "$packageName" "$fileType" "$silentA...
maharishi/chocolatey-packages
automatic/riecoin/tools/chocolateyUninstall.ps1
PowerShell
apache-2.0
402
function Add-VSCognitoUserPoolLambdaConfig { <# .SYNOPSIS Adds an AWS::Cognito::UserPool.LambdaConfig resource property to the template. Specifies the configuration for AWS Lambda triggers. .DESCRIPTION Adds an AWS::Cognito::UserPool.LambdaConfig resource property to the template. Specifies...
scrthq/Vaporshell
VaporShell/Public/Resource Property Types/Add-VSCognitoUserPoolLambdaConfig.ps1
PowerShell
apache-2.0
11,093
function global:Reset-Directory([string] $directoryPath) { if (Test-Path $directoryPath) { Remove-Item $directoryPath -Recurse -ErrorAction SilentlyContinue } New-Item -ItemType directory -Path $directoryPath } function global:Initialize-Directory([string] $directoryPath) { if (-not (Test-Path $directoryPath)) {...
mhinze/ZBuildLights
tools/scripts/modules/file_utilities.psm1
PowerShell
mit
497
<# .SYNOPSIS A CloudStack/CloudPlatform Virtual Machine destruction Scriptlet. .DESCRIPTION Destroy a CloudStack Virtual Machine .PARAMETER instanceid The instance ID of the VM. #> # Writen by Jeff Moody (fifthecho@gmail.com) # # 2013/7/19 v1.0 created Param( [Parameter(Mandatory=$true)] [String] $instan...
exoscale/CloudStack-PowerShell
CloudStackDestroyVM.ps1
PowerShell
apache-2.0
7,135
# Localized resources for DscResourceDesigner ConvertFrom-StringData @' ###PSLOC ModuleParsingError=There was an error parsing the module file {0} SchemaEncodingNotSupportedPrompt=The encoding for the schema file is not supported. Convert to Unicode? SchemaEncodingNotSupportedError=The encoding for the schema fi...
pshdo/Carbon
Tools/xDSCResourceDesigner/xDSCResourceDesigner.strings.psd1
PowerShell
apache-2.0
8,022
# Powershell Install script # Useful function from https://stackoverflow.com/questions/50093582/powershell-not-recognizing-conda-as-cmdlet-function-or-operable-program function Invoke-CmdScript { param( [String] $scriptName ) $cmdLine = """$scriptName"" $args & set" & $Env:SystemRoot\system32\cmd.exe /c $c...
FrancoisRheaultUS/dipy
ci/azure/script.ps1
PowerShell
bsd-3-clause
1,083
<# .SYNOPSIS Creates a new Sitecore role. .DESCRIPTION The New-Role command creates a new Sitecore role. .PARAMETER Identity Role name including domain. If no domain is specified - 'sitecore' will be used as the default value .PARAMETER PassThru Passes the processed ob...
ostat/Console
Documentation/New-Role.ps1
PowerShell
mit
645
Param( [Parameter(Mandatory = $true, HelpMessage="Name of the resource group to which the KeyVault belongs to. A new resource group with this name will be created if one doesn't exist")] [ValidateNotNullOrEmpty()] [string]$resourceGroupName, [Parameter(Mandatory = $true)] [ValidateNotNullOr...
hungmai-msft/azure-powershell
src/ResourceManager/Compute/Commands.Compute/Extension/AzureDiskEncryption/Scripts/ClearKek.ps1
PowerShell
apache-2.0
1,540
Describe "ComparisonOperator" -tag "CI" { It "Should be $true for 1 -lt 2" { 1 -lt 2 | Should Be $true } It "Should be $false for 1 -gt 2" { 1 -gt 2 | Should Be $false } It "Should be $true for 1 -le 2" { 1 -le 2 | Should Be $true } It "Should be $true for 1 -le 1" { 1 -le 1...
bingbing8/PowerShell
test/powershell/Language/Operators/ComparisonOperator.Tests.ps1
PowerShell
mit
2,324
function Assert-AreEqual { [CmdletBinding()] param([object]$Expected, [object]$Actual, [string]$Message) Write-Verbose "Asserting are equal. Expected: '$Expected' ; Actual: '$Actual'." if (!(Test-AreEqual $Expected $Actual)) { throw ("Assert are equal failed. Expected: '$Expected' ; Actual: '$A...
Microsoft/vsts-task-lib
powershell/Tests/lib/TestHelpersModule/PublicFunctions.ps1
PowerShell
mit
10,940
<# .SYNOPSIS Run a suite of Azure Key Vault tests via the PowerShell cmdlets. .PARAMETER TestRunNameSpace Used as a namespace for each test run. It is used as a substring for key and vault names during tests, so be sure to keep it short. .PARAMETER TestMode The test mode (optional). Must be either 'ControlPlane', 'D...
nemanja88/azure-powershell
src/ResourceManager/KeyVault/Commands.KeyVault.Test/Scripts/RunKeyVaultTests.ps1
PowerShell
apache-2.0
28,443
function Get-PrivateIPNetworkBlocks { if ($null -eq ([System.AppDomain]::CurrentDomain.GetAssemblies() | ? FullName -eq "LukeSkywalker.IPNetwork, Version=1.3.2.0, Culture=neutral, PublicKeyToken=764160545cf0d618")) { [System.Reflection.Assembly]::LoadFile((Join-Path $ProfileConfig.Module.InstallPath "Li...
paulmarsy/Console
Custom Consoles/PowerShell/Exports/Functions/Networking/Get-PrivateIPNetworkBlocks.ps1
PowerShell
mit
834
################ # SYSKIT # www.syskit.com <# Displays ApplicationPool recycle action settings for all ApplicationPools on the selected Computer. Run on any Computer. #> ################ <#Get-WebConfigurationProperty /system.applicationhost/applicationpools -name * | select -expand collection |select name -expand recy...
Acceleratio/SysKitPowerShellScripts
PowerShell Scripts/IIS/AplicationPools/Computer_ApplicationPoolRecycleSettings.ps1
PowerShell
mit
3,654
# To run these tests, we have to fake login credentials [Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingConvertToSecureStringWithPlainText', '')] param () # Unit Test Template Version: 1.1.0 $script:moduleName = 'xSQLServerHelper' [String] $script:moduleRoot = Split-Path -Parent (Split-Path -Parent $...
ChrisLGardner/xSQLServer
Tests/Unit/xSQLServerHelper.Tests.ps1
PowerShell
mit
78,990
function Find-DbaOrphanedFile { <# .SYNOPSIS Find-DbaOrphanedFile finds orphaned database files. Orphaned database files are files not associated with any attached database. .DESCRIPTION This command searches all directories associated with SQL database files for database files that are not...
alevyinroc/dbatools
functions/Find-DbaOrphanedFile.ps1
PowerShell
mit
11,584
Function Get-MVPContributionArea { <# .SYNOPSIS Invoke the GetContributionAreas REST API to retrieve your contribution areas .DESCRIPTION Gets a list of Contribution areas grouped by Award Names .PARAMETER Other It gets the list of Other Award Categories .PARAMETER All ...
p0w3rsh3ll/MVP
MVP/Public/Get-MVPContributionArea.ps1
PowerShell
mit
2,151
<# .SYNOPSIS Activates an intrusion output. .DESCRIPTION Activates an intrusion output. If the result returns null, try the parameter "-Verbose" to get more details. .EXAMPLE Invoke-ActivateIntrusionOutput .LINK https://github.com/erwindevreugd/PSDataConduIT ....
erwindevreugd/PSDataConduIT
PSDataConduIT/Public/Invoke-ActivateIntrusionOutput.ps1
PowerShell
mit
2,349
# http://powershell.org/wp/2013/09/16/powershell-performance-the-operator-and-when-to-avoid-it/ <# http://powershell.org/wp/2013/10/21/why-get-content-aint-yer-friend/ # get the whole file (faster than below) #[IO.File]::ReadAllText("c:\myfile.txt") # read each line $file = New-Object System.IO.StreamReader -Arg "tes...
gangstanthony/PowerShell
faster string vs stringbuilder.ps1
PowerShell
mit
1,706
#requires -Version 3.0 param( [Collections.IDictionary] [Alias('Options')] $Option = @{ } ) $start = [DateTime]::Now if (($PSVersionTable.PSVersion.Major -lt 6) -or ($PSVersionTable.Platform -and $PSVersionTable.Platform -eq 'Win32NT')) { $script:isWindows = $true } else { $script:isWi...
alevyinroc/dbatools
dbatools.psm1
PowerShell
mit
32,824
# Taken with love from @juneb_get_help (https://raw.githubusercontent.com/juneb/PesterTDD/master/Module.Help.Tests.ps1) # Get module commands # Remove all versions of the module from the session. Pester can't handle multiple versions. Get-Module $env:BHProjectName | Remove-Module Import-Module $env:BHPSModulePath -Ver...
devblackops/pshealthz
Tests/Help.tests.ps1
PowerShell
mit
5,377
function Write-Log { <# .Synopsis Write-Log / Log Logs text to the console and/or to a file. .DESCRIPTION A comprehensive helper function for structured logging. Writes one or more messages to the different available outputchannels of the powershell and to one or more logfiles....
AndiBellstedt/PoShPRTG
PoShPRTG/internal/functions/Write-Log.ps1
PowerShell
mit
9,090
######################################## # Public functions. ######################################## function Invoke-BuildTools { [CmdletBinding()] param( [switch]$NuGetRestore, [string[]]$SolutionFiles, [string]$MSBuildLocation, # TODO: Switch MSBuildLocation to mandatory. Both callers...
Microsoft/vsts-tasks
Tasks/Common/MSBuildHelpers/InvokeFunctions.ps1
PowerShell
mit
7,537
cinst visualstudio2017community cinst vswhere
jafz/boxProvisioning
boxStarterVs2017community.ps1
PowerShell
mit
45
param ( [Parameter(Mandatory=$true)][string]$version, [bool]$skipUpload=$false ) $cache_dir = "publish_cache" if( (Test-Path -Path $cache_dir)) { Remove-Item -Recurse -Force $cache_dir } New-Item $cache_dir -type directory $nuspecs = Get-Childitem "." -Recurse | where {$_.extension -eq ".nuspec"} foreach ($...
sceeter89/LightShell
Core/NuGet/publish_packages.ps1
PowerShell
mit
624
<# .SYNOPSIS enable ssh server port 22 for vscode remote .LINK to run with no arguments: iwr "https://raw.githubusercontent.com/jagilber/powershellScripts/master/enable-ssh-server.ps1" -UseBasicParsing|iex #> write-host "checking ssh config" $hasSSHClient = (Get-WindowsCapability -Online | where-object Name -match '...
jagilber/powershellScripts
enable-ssh-server.ps1
PowerShell
mit
1,357
<# .SYNOPSIS This script will verify that there's no UTF-8 BOM in the files inside of the project. #> param ( # Path to the repository root. All text files under the root will be checked for UTF-8 BOM. $SourceRoot = "$PSScriptRoot/..", # Makes the script to perform file modifications to bring them to t...
ForNeVeR/wpf-math
scripts/verify-encoding.ps1
PowerShell
mit
2,045
.\nuget --% pack -properties configuration=release;flavor= .\nuget --% pack -properties configuration=signedrelease;flavor=.Signed
mfidemraizer/trackerdog
NuGet/create-packages.ps1
PowerShell
apache-2.0
130
#iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')) (new-object net.webclient).DownloadFile('https://chocolatey.org/install.ps1', 'C:\Windows\Temp\install.ps1') for($try = 0; $try -lt 5; $try++) { & C:/Windows/Temp/install.ps1 if ($?) { exit 0 } if (Test-Path C:\ProgramData\ch...
TheBigBear/packer-windows-gildas
scripts/install-chocolatey.ps1
PowerShell
apache-2.0
503
##9.3 - custom script - display folders with more than XXX MB total in them #- input - path and look only first child folders # - size in MB to look for #- ouput - directories with more then $SIZE in them function DisplayFolderBySize($rootDir, $minimumSizeInMB){ } $global:dir2SizeMap = @{} function Calcul...
leni-kirilov/scripts
powershell/DisplayFolderSize.ps1
PowerShell
apache-2.0
998