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
$packageName = 'multipar.portable' $url = 'http://multipar.eu//download/archive/dl.php?fn=MultiPar1280.zip' $checksum = '65363F38F17DC4C5D3AD14FF2C52EE842F96D137' $checksumType = 'sha1' $toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" $installFile = Join-Path $toolsDir "MultiPar.exe" Install-Cho...
dtgm/chocolatey-packages
automatic/_output/multipar.portable/1.2.8.0/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
693
$packageName = 'megui' $url = 'http://sourceforge.net/projects/megui/files/megui-stable/2525/MeGUI_2525_x86.zip/download' $checksum = '7a6570c78986cc487e87ee651699829e3ffcbda4' $checksumType = 'sha1' $toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" $installFile = Join-Path $toolsDir "$($packageNam...
dtgm/chocolatey-packages
automatic/_output/megui/1.0.2525/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
784
function doSomething { [OutputType([string])] param ( [string] $test ) return $test } export-moduleMember -function doSomething
sergey-tihon/FSharp.Management
tests/FSharp.Management.Tests/testModule.psm1
PowerShell
apache-2.0
155
<# Copyright 2017 Dominique Broeglin 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, softw...
dbroeglin/NetScaler
NetScaler/Public/Enable-NSHighAvailability.ps1
PowerShell
apache-2.0
5,126
############################################################################# # ## # WildFly Startup Script for starting the standalone server ## # ## ########...
elblancoboss/CI346-Semester-2
target/wildfly-run/wildfly-10.1.0.Final/bin/standalone.ps1
PowerShell
apache-2.0
1,587
param( [string] $publicipfmt, [string] $privateiplist, [string] $vmlist, [string] $lblist, [string] $Passwd ) $targetDir = "." function Log { param( [string] $m ) $Stamp = (Get-Date).toString("yyyy/MM/dd HH:mm:ss") Add-Content ./installsk.log "$stamp [installCluster.ps1] $m" } Log $vmlist Log $publi...
MCKLMT/azure-quickstart-templates
safekit-cluster-mirror/scripts/installCluster.ps1
PowerShell
mit
628
<# .SYNOPSIS Udpates a cardholder. .DESCRIPTION Updates a cardholder. If the result returns null, try the parameter "-Verbose" to get more details. .EXAMPLE .LINK https://github.com/erwindevreugd/PSDataConduIT .EXTERNALHELP PSDataConduIT-help.xml #> function Set-Cardholder { ...
erwindevreugd/PSDataConduIT
PSDataConduIT/Public/Set-Cardholder.ps1
PowerShell
mit
9,808
function Assert { [CmdletBinding()] param( [Parameter(Position=0,Mandatory=1)]$conditionToCheck, [Parameter(Position=1,Mandatory=1)]$failureMessage ) if (!$conditionToCheck) { throw ("Assert: " + $failureMessage) } }
OpenMagic/BuildMagic
source/psake/Assert.ps1
PowerShell
mit
260
$PSScriptRoot = Split-Path $MyInvocation.MyCommand.Path -Parent $PluginId = "ReSharperPlugin.InternalsVisibleTo" $SolutionPath = "$PSScriptRoot\InternalsVisibleTo.sln" $SourceBasePath = "$PSScriptRoot\src\dotnet" $VsWhereOutput = [xml] (& "$PSScriptRoot\tools\vswhere.exe" -format xml) $VisualStudio = $VsWhereOutput.in...
hmemcpy/ReSharper.InternalsVisibleTo
settings.ps1
PowerShell
mit
1,623
<# MIT License Copyright (c) 2018 fvanroie, NetwiZe.be 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 to use, co...
fvanroie/PS_OPNsense
Private/Import-Type.ps1
PowerShell
mit
2,584
## Use this file to start the deployment of your Jenkins Pipeline Build Server ## ## Without modification, this deployment will build: ## ## Windows Server 2012 R2 with: ## ## Visual Studio Community - 2015 Update 3 ## ## Jenkins 2.19.4 ...
TobiahZ/JenkinsUnityBuildPipeline
StartHere.ps1
PowerShell
mit
1,353
######################################## # Public functions. ######################################## function Invoke-BuildTools { [CmdletBinding()] param( [switch]$NuGetRestore, [string[]]$SolutionFiles, [string]$MSBuildLocation, # TODO: Switch MSBuildLocation to mandatory. Both callers...
Microsoft/vso-agent-tasks
Tasks/Common/MSBuildHelpers/InvokeFunctions.ps1
PowerShell
mit
7,505
$projectPath = "$env:APPVEYOR_BUILD_FOLDER\$env:ANDROID_PROJECT_PATH" # Load the bootstrap file [xml] $xam = Get-Content -Path ($projectPath + "\Properties\AndroidManifest.xml") # Get the version from Android Manifest $version = Select-Xml -xml $xam -Xpath "/manifest/@android:versionCode" -namespace @{android="http:...
Noxalus/Xmas-Hell
Scripts/UpdateAndroidVersion.ps1
PowerShell
mit
549
$newKbLayout = New-WinUserLanguageList en-us $newKbLayout.Add("cs-cz") $newKbLayout[1].InputMethodTIPS.Clear() $newKbLayout[1].InputMethodTIPS.Add('0405:00010405') # Czech querty keyboard Set-WinUserLanguageList $newKbLayout -Force
Ianonn21/vm-utils
scripts/set-kb-layout-eng-ces.ps1
PowerShell
mit
231
# # OEML - REST API # This section will provide necessary information about the `CoinAPI OEML REST API` protocol. <br/> This API is also available in the Postman application: <a href=""https://postman.coinapi.io/"" target=""_blank"">https://postman.coinapi.io/</a> <br/><br/> Implemented Standards: * [HTTP1.0](h...
coinapi/coinapi-sdk
oeml-sdk/powershell/src/PSOpenAPITools/Client/Configuration.ps1
PowerShell
mit
13,243
function CleanWindows() { if ($windowGameEdit.Exists()) { $windowGameEdit.Close() } } Describe "Custom Games - Game Creation" { BeforeAll { $windowMain = & (Join-Path $PSScriptRoot "..\Mapping\MainWindow.ps1") $windowGameEdit = & (Join-Path $PSScriptRoot "..\Mapping\G...
JosefNemec/Playnite
tests/UI/CustomGames.Tests.ps1
PowerShell
mit
1,877
$msuData = @{ '6.1-client' = @{ Url = 'https://download.microsoft.com/download/3/7/4/37473F39-5728-4153-9A25-64C09DE9ED52/Windows6.1-KB3033929-x86.msu' Checksum = '246C300A6AE6DCA99453F6839745AC0015953528A7065BED1B015F91B80CF64D' Url64 = 'https://download.microsoft.com/download/C/8/7/C87AE6...
jberezanski/ChocolateyPackages
KB3033929/Tools/ChocolateyInstall.ps1
PowerShell
mit
979
function Get-SorensenDiceDistance { <# .SYNOPSIS Get the Sorensen Dice Distance between two strings. .DESCRIPTION Uses the Sorensen Dice Coefficient to calculate the distance between two strings. .EXAMPLE Get-SorensenDiceDistance -String1 'night' -String2 ...
gravejester/Communary.PASM
Functions/Get-SorensenDiceDistance.ps1
PowerShell
mit
1,127
function Guard-ArgumentNotNullOrEmpty { param( [string]$ArgumentName, $ArgumentValue ) Guard-ArgumentNotNull $ArgumentName $ArgumentValue if($ArgumentValue -is [System.Collections.IEnumerable]) { if (!$ArgumentValue.GetEnumerator().MoveNext()) { throw (New...
ghostsquad/AetherCore
functions/Guard-ArgumentNotNullOrEmpty.ps1
PowerShell
apache-2.0
726
function New-VSAppStreamDirectoryConfig { <# .SYNOPSIS Adds an AWS::AppStream::DirectoryConfig resource to the template. The AWS::AppStream::DirectoryConfig resource specifies the configuration information required to join Amazon AppStream 2.0 fleets and image builders to Microsoft Active Directory doma...
scrthq/Vaporshell
VaporShell/Public/Resource Types/New-VSAppStreamDirectoryConfig.ps1
PowerShell
apache-2.0
13,301
# This file is part of Invoke-CradleCrafter. # # Copyright 2018 Daniel Bohannon <@danielhbohannon> # while at Mandiant <http://www.mandiant.com> # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtai...
danielbohannon/Invoke-CradleCrafter
Invoke-CradleCrafter.ps1
PowerShell
apache-2.0
300,232
<# .Synopsis Defines the custom task "check". .Description Build scripts dot-source this script in order to use the task "check". The build file with checks represents a check-list and checks are normally invoked together (*). But they can be invoked individually, too. Tasks can reference checks. Checks can ref...
lholman/OneBuild
packages/invoke-build.2.9.12/tools/Tasks/Check/Check.tasks.ps1
PowerShell
apache-2.0
2,086
param( [switch]$ci ) $ErrorActionPreference = 'stop' $excludeCIBinarylog = $true $msbuildEngine = 'dotnet' $repoRoot = Resolve-Path "$PSScriptRoot/../.." try { & "$repoRoot\eng\common\msbuild.ps1" -ci:$ci "$repoRoot/eng/CodeGen.proj" /t:GenerateProjectList } finally { Remove-Item variable:global:_BuildTool -E...
aspnet/AspNetCore
eng/scripts/GenerateProjectList.ps1
PowerShell
apache-2.0
538
param( [ValidateSet("netcore31", "nupkg-only")] [Parameter(Position = 0)] [string] $Target = "netcore31", [Parameter(Position = 1)] [string] $Version = "91.1.230", [Parameter(Position = 2)] [string] $AssemblyVersion = "91.1.230" ) $WorkingDir = split-path -parent $MyInvocation.MyCommand.D...
Livit/CefSharp
build.netcore.ps1
PowerShell
bsd-3-clause
11,431
<# .SYNOPSIS Hive query - View number of messages grouped by message type. .DESCRIPTION This script creates a Hive external table on cold storage blobs, executes a Hive query that will calculate the number of messages for the different message types and display the results. You will need to provision your HDInsight cl...
mspnp/data-pipeline
src/Validation/HDInsight/hivequery.ps1
PowerShell
mit
2,064
param($installPath, $toolsPath, $package, $project) $packagePath = (New-Object system.IO.DirectoryInfo $toolsPath).Parent.FullName $cppBinaryPathx86 = Join-Path $packagePath "nativeBinaries\x86\msvcr120.dll" $cppBinaryPathx64 = Join-Path $packagePath "nativeBinaries\x64\msvcr120.dll" $sqlBinaryPathx86 = Join-Path $pac...
Arxa/Digital_Storehouse
packages/Microsoft.SqlServer.Types.14.0.314.76/tools/install.ps1
PowerShell
mit
2,250
# Copyright (c) Microsoft Corporation. # Licensed under the MIT License. ## ## ---------- ## Test Note: ## ---------- ## Since these tests change session and system state (constrained language and system lockdown) ## they will all use try/finally blocks instead of Pester AfterEach/AfterAll to ensure session ## and sys...
JamesWTruher/PowerShell-1
test/powershell/Modules/Microsoft.PowerShell.Security/ConstrainedLanguageDebugger.Tests.ps1
PowerShell
mit
5,633
######################################################################## # # Linux on Hyper-V and Azure Test Code, ver. 1.0.0 # Copyright (c) Microsoft Corporation # # All rights reserved. # Licensed under the Apache License, Version 2.0 (the ""License""); # you may not use this file except in compliance with the Licen...
bogdancarpusor/lis-test
WS2012R2/lisa/Infrastructure/Run-TestSpecificLogger.ps1
PowerShell
apache-2.0
9,439
[cmdletbinding()] param() . $PSScriptRoot\..\..\lib\Initialize-Test.ps1 $distributedTaskContext = 'Some distributed task context' Register-Mock Get-VssConnection { $connection } -TaskContext $distributedTaskContext Register-Mock CmdletHasMember { $true } -memberName "TaskContext" Register-Mock Invoke-RunDistributedTe...
AArnott/vso-agent-tasks
Tests/L0/RunDistributedTests/VerifyAzureCompat.NewResource.ps1
PowerShell
mit
1,814
#Requires -Version 3.0 . "$($PSScriptRoot)\..\..\TestInitialize.ps1" Describe 'ConvertTo-SPClientListItem' { Context 'Success' { It 'Converts a file to list item' { $Web = $SPClient.ClientContext.Site.OpenWebById($SPClient.TestConfig.WebId) $File = $Web.GetFileById($SPClient.Tes...
karamem0/SPClient
source/SPClient.Tests/functions/SPClientListItem/ConvertTo-SPClientLisItem.Tests.ps1
PowerShell
mit
1,089
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 # MIIdkwYJKoZIhvcNAQcCoIIdhDCCHYACAQExCzAJBgUrDgMCGgUAMGkGCisGAQQB # gjcCAQSgWzBZMDQGC...
MicrosoftLearning/20486-DevelopingASPNETMVCWebApplications
Allfiles/20486C/Mod01/Labfiles/PhotoSharingSample/packages/EntityFramework.6.1.3/tools/init.ps1
PowerShell
mit
10,838
#ValidationTags#Messaging,FlowControl,Pipeline,CodeStyle# function Find-DbaBackup { <# .SYNOPSIS Finds SQL Server backups on disk. .DESCRIPTION Provides all of the same functionality for finding SQL backups to remove from disk as a standard maintenance plan would. ...
SirCaptainMitch/dbatools
functions/Find-DbaBackup.ps1
PowerShell
mit
7,678
<# DESCRIPTION: Check relevant monitoring tool agent is installed and that the correct port is open to the management server. REQUIRED-INPUTS: ProductNames - "LIST" - SCOM agent product names to search for DEFAULT-VALUES: ProductNames = @('Microsoft Monitoring Agent', 'System Cent...
My-Random-Thoughts/QA-Checks-v4
checks/tooling/tol-02-scom-monitoring-installed.ps1
PowerShell
mit
3,818
function Set-UnattendedWindowsAntiMalware { param ( [Parameter(Mandatory = $true)] [bool]$Enabled ) $node = $script:un | Select-Xml -XPath '//un:settings[@pass = "specialize"]/un:component[@name = "Security-Malware-Windows-Defender"]' -Namespace $ns | Select-Object -ExpandProperty ...
AutomatedLab/AutomatedLab
AutomatedLabUnattended/Private/Win/Set-UnattendedWindowsAntiMalware.ps1
PowerShell
mit
465
$rootPath = Join-Path (Split-Path -Parent $MyInvocation.MyCommand.Path) -ChildPath ('..\..\..\..\') -Resolve Remove-Module PoShMon -ErrorAction SilentlyContinue Import-Module (Join-Path $rootPath -ChildPath "PoShMon.psd1") Describe "Test-SPDistributedCacheHealth" { InModuleScope PoShMon { class SPDistribu...
HiltonGiesenow/PoShMon
src/Tests/CI/Unit/PoShMon.Monitoring.SharePoint/Test-SPDistributedCacheHealth.Tests.ps1
PowerShell
mit
12,540
# Variable # ======== $Script:RPNDictionary = @{} $Script:StringHead = ':' # Function # ======== filter Global:Invoke-ReversePolishNotation { $stack = if ($MyInvocation.ExpectingInput) {,$_} else {New-Object System.Collections.Stack} $args | %{ if (Test-RPNValue $_) {Push-RPN $_ $stack}...
yumura/ReverShell
Functions/Core.ps1
PowerShell
mit
2,766
function New-JIRAVersion { <# .SYNOPSIS Creates a JIRAVersion objects. .DESCRIPTION The New-JIRAVersion cmdlet creates a JIRAVersion object based on specified input. .PARAMETER Uri Specifies the url to be used to retrieve the JIRAVersion object. .PARAMETER Session Specifies the AtlassianSession to ...
Invoke-Automation/AtlassianCLI
AtlassianCLI/Private/JIRA/New-JIRAVersion.ps1
PowerShell
mit
2,030
function Test-PlasterManifest { [CmdletBinding()] [OutputType([System.Xml.XmlDocument])] param( [Parameter(Position=0, ParameterSetName="Path", ValueFromPipeline=$true, ValueFromPipelineByPropertyName=$true, HelpMessage="Spe...
mrward/monodevelop-powershell-addin
modules/Plaster/TestPlasterManifest.ps1
PowerShell
mit
21,237
Describe "Chrome" { It "Chrome" { $chromeLocation = "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome" $chromeLocation | Should -Exist "'$chromeLocation' --version" | Should -ReturnZeroExitCode } It "Chrome Driver" { "chromedriver --version" | Should -ReturnZeroE...
mattgwagner/New-Machine
.github-actions/images/macos/tests/Browsers.Tests.ps1
PowerShell
mit
1,603
$arch = 'x86' # save argument list for possible later consumption $argsList = $args $thisScript = Split-Path -Path $MyInvocation.MyCommand.Definition -Parent . ($thisScript + '.\chocolateyInstall-Template.ps1')
Mistuke/GhcDevelChoco
1.0.0/x86/tools/chocolateyInstall.ps1
PowerShell
mit
222
<#PSScriptInfo .VERSION 1.0.0 .GUID 35f4563f-fae5-4028-b8eb-06939caf62fe .AUTHOR DSC Community .COMPANYNAME DSC Community .COPYRIGHT Copyright the DSC Community contributors. All rights reserved. .TAGS DSCConfiguration .LICENSEURI https://github.com/dsccommunity/NetworkingDsc/blob/main/LICENSE .PROJECTURI https://githu...
PlagueHO/xNetworking
source/Examples/Resources/NetIPInterface/1-NetIPInterface_MultipleSettings_Config.ps1
PowerShell
mit
2,073
################################################################################################### # PowerShell configurations # # NOTE: Because the $ErrorActionPreference is "Stop", this script will stop on first failure. # This is necessary to ensure we capture errors inside the try-catch-finally block. $Erro...
jeffgilb/DevTestLabs
artifacts/windows-azure-ad-connect/adconnect.ps1
PowerShell
mit
3,128
<# .Synopsis .\install-Unity-Falcon.ps1 -Masterpath .\Unity-1.4.5.2-535679 -Defaults install-Unity only applies to Testers of the Virtual Unity install-Unity is a 1 Step Process. Once Unity is downloaded via feedbckcentral, run .\install-Unity-Falcon.ps1 -defaults This creates a Unity Master in your lab...
bottkars/labbuildr
labbuildr/install-unity-falcon.ps1
PowerShell
apache-2.0
33,360
function NewFallbackCimSession { [CmdletBinding()] param ( [parameter(Mandatory = $true, ValueFromPipeline = $true)] [ValidateNotNullOrEmpty()] [string] $ComputerName, [Parameter()] [pscredential] $Credential ) begin { $SessionOptions = New-C...
twillin912/ServerManagementTools
ServerManagement/Private/NewFallbackCimSession.ps1
PowerShell
bsd-3-clause
1,606
function Find-ByASTType { param( [string]$Name, [string]$TargetType, [string[]]$Fullname, [scriptblock]$ExtractName ) Process { $Ast = [System.Management.Automation.Language.Parser]::ParseFile( (Resolve-Path $FullName) , [ref]$null, [ref]$null) $Ta...
dfinke/PSharp
spike/Find-ByASTType.ps1
PowerShell
mit
2,822
Function DeleteFileIfExists($path) { if (Test-Path $path) { Remove-Item -Path $path -Force } } Function DeleteFolderIfExists($path) { if (Test-Path $path) { Remove-Item -LiteralPath $path -Force -Recurse } }
devedse/DeveMazeGeneratorCore
Scripts/PowerShellHelpers.psm1
PowerShell
mit
240
# Copyright(c) 2017 Google Inc. # # 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, ...
GoogleCloudPlatform/dotnet-docs-samples
appengine/flexible/Analytics/deployTests.ps1
PowerShell
apache-2.0
814
# This file should be identical for all python* packages # https://docs.python.org/3/using/windows.html#installing-without-ui $installDir = '{0}\Python{1}' -f $Env:SystemDrive, ($Env:ChocolateyPackageVersion -replace '\.').Substring(0,2) if ($Env:ChocolateyPackageParameters -match '/InstallDir:\s*(.+)') { $insta...
chocolatey/chocolatey-coreteampackages
automatic/python2/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
1,313
Import-Module ..\bin\Debug\Profitbricks.dll $SecurePassword = [Environment]::GetEnvironmentVariable("PB_PASSWORD","User") | ConvertTo-SecureString -AsPlainText -Force $username = [Environment]::GetEnvironmentVariable("PB_USERNAME","User") $Credentials = New-Object -TypeName System.Management.Automation.PSCredential -...
profitbricks/profitbricks-powershell
Profitbricks/test_scripts/share_test.ps1
PowerShell
apache-2.0
1,206
<# Fixed Rate Loan/Mortgage Calculator in Excel #> param( $Amount = 400000, $InterestRate = .065, $Term = 30 ) try {Import-Module $PSScriptRoot\..\..\ImportExcel.psd1} catch {throw ; return} function New-CellData { [Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseShouldProcessForStateChangin...
DarkLite1/ImportExcel
Examples/MortgageCalculator/MortgageCalculator.ps1
PowerShell
apache-2.0
1,540
# # UpdateSolutionVersionInCRM.ps1 # param( [string]$CrmConnectionString, [string]$SolutionName, [string]$VersionNumber ) $ErrorActionPreference = "Stop" Write-Verbose 'Entering UpdateSolutionVersionInCRM.ps1' -Verbose #Parameters Write-Verbose "CrmConnectionString = $CrmConnectionString" Write-Verbose "SolutionNa...
WaelHamze/xrm-ci-framework
MSDYNV9/Xrm.Framework.CI/Xrm.Framework.CI.PowerShell.Scripts/UpdateSolutionVersionInCRM.ps1
PowerShell
mit
1,003
Start-AutoRestCodeGeneration -ResourceProvider "batch/resource-manager" -AutoRestVersion "v2"
ayeletshpigelman/azure-sdk-for-net
sdk/batch/Microsoft.Azure.Management.Batch/src/generate.ps1
PowerShell
mit
93
. '.\inc\Config.ps1' . '.\inc\Params.ps1' . '.\inc\Functions.ps1' # Main Program if ($os -eq "windows-pe-x64") { # If working on 1-imaged boot.wim (winpe) MountWim $wim_file $mount_dir $wim_image_name AddDrivers $drivers_dir $mount_dir # This will add additional PE packages AddUpdates $update_dir $mount_dir...
kireevco/wimaging
Update-BootAll.ps1
PowerShell
mit
1,840
############## Constants ########## $invalidParam = "invalidParam" $validRG = "AzureFileCopyTaskPlatformTestDoNotDelete" $rgWithNoVM = "AzureFIleCopyPTRGNoVMDoNotDelete" $rgNameWithSecurityGroup = "AzureFIleCopyPTRGWithSGDoNotDelete" $validStorage = "azurefilecopyptsstore" $validStorageKey = "validStorageKey" $storageA...
kkdawkins/vsts-tasks
Tasks/AzureFileCopy/Tests/MockHelper.ps1
PowerShell
mit
27,283
function Table { <# .SYNOPSIS Defines a new PScribo document table. .PARAMETER Name .PARAMETER InputObject .PARAMETER Hashtable .PARAMETER Columns .PARAMETER ColumnWidths .PARAMETER Headers .PARAMETER Style .PARAMETER List .PARAMETER Width .PARAMETER Tabs ...
kilasuit/PScribo
Src/Public/Table.ps1
PowerShell
mit
7,014
<# .SYNOPSIS PowerShell module build script based on psake. .DESCRIPTION This psake build script supports building PowerShell manifest modules which contain PowerShell script functions and optionally binary .NET C# libraries. The build script contains the following tasks. ...
claudiospizzi/OperationsManagerFever
build.psake.ps1
PowerShell
mit
22,816
Function Repair-OOSFarm { [CmdletBinding()] Param( [hashtable]$PoShMonConfiguration, [System.Collections.ArrayList]$PoShMonOutputValues ) $repairFunctionNames = 'Repair-W3ServiceOnOOSHost' #try { $repairOutput = Invoke-Repairs $repairFunctionNames $PoShMonConfigu...
HiltonGiesenow/PoShMon
src/Functions/PoShMon.SelfHealing.OOS/Repair-OOSFarm.ps1
PowerShell
mit
645
# this script removes /esss-website/ from all links and replaces it with beta.esss.ca $phraseToRemove = "/esss-website" $phraseToInsert = "http://beta.esss.ca" $filepath = "C:\Users\Shayne\Documents\GitHub\esss-website" $files = get-childitem $filepath -include *.html, *.js, *.css -recurse foreach($file in $files) { ...
shaynekellyii/esss-website
refactorLinks.ps1
PowerShell
mit
427
Remove-Module -Name DevOpsFlex.Environments.PowerShell -ErrorAction SilentlyContinue -Verbose Import-Module $PSScriptRoot\..\DevOpsFlex.Environments.PowerShell.psd1 -Force -Verbose
sfa-gov-uk/devopsflex
src/DevOpsFlex.Environments.PowerShell/DevOpsFlex.Environments.PowerShell/Debug/ReloadModule.ps1
PowerShell
mit
184
#$Requires -Version 3 <# .SYNOPSIS Restart all web applications in a resource group by slot .DESCRIPTION Gets a list of all web applications in a given subscription and resource group. It restarts a slot across all of them. - You must be logged in using `AzureRm-Login`. - You must have a subscription selected used ...
DustinVenegas/dotfiles
WindowsPowerShell/Scripts/AzureRm/Restart-AzureRmRgWebAppSlots.ps1
PowerShell
mit
1,952
function main ($arch) { If ( $arch -eq "64" ) { $url="https://github.com/ActivityWatch/wheels/raw/master/pyHook-1.5.1-cp35-cp35m-win_amd64.whl" } ElseIf ( $arch -eq "32" ) { $url="https://github.com/ActivityWatch/wheels/raw/master/pyHook-1.5.1-cp35-cp35m-win32.whl" } Else { Write-Out...
ErikBjare/activitywatch
scripts/install_pyhook.ps1
PowerShell
mit
424
param($fileName, $toolGroup) #Installer for OmniBus.Reporting $root = Split-Path -Parent $PSCommandPath $target = Split-Path -Parent $root $ini = "$root\$fileName.ini" Get-ChildItem $target | Unblock-File "[Settings]" >> $ini "x64Path=$target" >> $ini "x86Path=$target" >> $ini "ToolGroup=$toolGroup" >> $ini Write-H...
jdunkerley/AlteryxAddIns
OmniBus.Reporting/Scripts/Installer.ps1
PowerShell
mit
906
function Remove-vROResourceElement { <# .SYNOPSIS Remove a vRO Resource Element .DESCRIPTION Remove a vRO Resource Element .PARAMETER Id Action ID .PARAMETER Force If the resource element is referenced by some workflows, it is considered to be 'in use'and the delete operation...
jakkulabs/PowervRO
src/Functions/Public/resource-service/Remove-vROResourceElement.ps1
PowerShell
mit
1,714
Function CloseGracefully() { # Close all file streams, files and sessions. $Stream.writeline( $Date + " PSSession and log file closed.") Write-Host $Date + " PSSession and log file closed." $Stream.Close() $fs.Close() $StreamMove.close() $fsMove.close() # Close PS Sessions ...
brian-mac/ZPM
FindDestinationFromSource.ps1
PowerShell
mit
5,571
<############################################################################# HistoryPx uses proxy commands to add extended history information to PowerShell. This includes the duration of a command, a flag indicating whether a command was successful or not, the output generated by a command (limited to a configurabl...
modulexcite/HistoryPx
scripts/Export-BinaryModule.ps1
PowerShell
apache-2.0
1,518
$ErrorActionPreference = 'Stop'; $toolsPath = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" $packageArgs = @{ packageName = 'keeweb' fileType = 'exe' file = "$toolsPath\KeeWeb-1.16.7.win.ia32.exe" file64 = "$toolsPath\KeeWeb-1.16.7.win.x64.exe" softwareName = 'keew...
pascalberger/chocolatey-coreteampackages
automatic/keeweb/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
627
$packageName = 'cyberduck.install' $installerType = 'exe' $silentArgs = '/S' $url = 'https://update.cyberduck.io/windows/Cyberduck-Installer-5.2.0.21317.exe' $checksum = 'b297a6bf3be9c42339f156449bf52d9ca51af948e78489db30740568192ceaa1' $checksumType = 'sha256' $validExitCodes = @(0) Install-ChocolateyPackage -Packag...
dtgm/chocolatey-packages
automatic/_output/cyberduck.install/5.2.0.21317/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
659
function Get-BoxStarterConfig { <# .SYNOPSIS Retrieves persisted Boxstarter configuration settings. .DESCRIPTION Boxstarter stores configuration data in an xml file in the Boxstarter base directory. The Get-BoxstarterConfig function is a convenience function for reading those settings. .LINK https://boxstarter.org ab...
mwrock/boxstarter
Boxstarter.Chocolatey/Get-BoxstarterConfig.ps1
PowerShell
apache-2.0
947
. ..\New-PSItem.ps1 rm *.xlsx $( New-PSItem =2%/12 60 500000 "=pmt(rate,nper,pv)" (echo rate nper pv pmt) New-PSItem =3%/12 60 500000 "=pmt(rate,nper,pv)" New-PSItem =4%/12 60 500000 "=pmt(rate,nper,pv)" New-PSItem =5%/12 60 500000 "=pmt(rate,nper,pv)" New-PSItem =6%/12 60 500000 "=pmt(rate,npe...
mrpullen/ImportExcel
Examples/SpreadsheetCells/ExcelFunctions.ps1
PowerShell
apache-2.0
444
# !/usr/bin/env powershell # Copyright 2018 Google 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 applicable law...
googleapis/google-cloud-cpp-common
ci/kokoro/windows/build-cmake-dependencies.ps1
PowerShell
apache-2.0
4,685
function Add-ConEquals { <# .SYNOPSIS Adds the condition function "Fn::Equals" to a resource property .DESCRIPTION Compares if two values are equal. Returns true if the two values are equal or false if they aren't. .LINK http://docs.aws.amazon.com/AWSCloudFormation/latest/U...
scrthq/Vaporshell
VaporShell/Public/Condition Functions/Add-ConEquals.ps1
PowerShell
apache-2.0
1,838
# Returns Branch Cache HostedCacheServerConfiguration details # Example - True,False # Get-BCStatus | Select-Object -ExpandProperty HostedCacheServerConfiguration | Select-Object -ExpandProperty HostedCacheServerIsEnabled # Return Type: String # Execution Context: System $branchcache = Get-BCStatus | Select-Object -E...
vmwaresamples/AirWatch-samples
Windows-Samples/Sensors/bc_hostedcacheserverconfig_hostedcacheserverisenabled.ps1
PowerShell
bsd-3-clause
420
function Get-VSPath($Version) { Write-Host "Searching for $Version..." try { # Search for a 15.0 instance. if ($Version -eq "15.0") { # Use vswhere.exe to determine the Visual Studio Path. $homeDirectory = $env:AGENT_HOMEDIRECTORY $combinedVsWhereDirectory = J...
argusnetch/sharepoint-build-tasks
Tasks/PackageSharePointAddIn/Get-VSPath.ps1
PowerShell
mit
1,382
<# .SYNOPSIS Truncate all tables in database. .DESCRIPTION Truncate all tables in database. Drop and recreate all foreign keys. .PARAMETR Machine <String> - specify path to computer .PARAMETR SqlInstance <String> - specify SQL Server instance name .PARAMETR DBname <String> - specify database na...
ktaranov/sqlserver-kit
PowerShell/Truncate-AllTables.ps1
PowerShell
mit
2,108
<# .SYNOPSIS Sets up the connection to an Azure subscription .DESCRIPTION WARNING: This runbook is deprecated. Please use OrgID credential auth to connect to Azure, instead of certificate auth using this runbook. You can learn more about using credential auth with Azure here: http://aka.ms/Sspv1l This r...
pierreroman/powershell
Connect-Azure.ps1
PowerShell
mit
2,390
<# Notes: Authors: Jason Helmick and Melissa (Missy) Januszko The bulk of this DC, DHCP, ADCS config is authored by Melissa (Missy) Januszko and Jason Helmick. Currently on her public DSC hub located here: https://github.com/majst32/DSC_public.git Additional contributors of note: Jeff Hicks Disclaimer This...
jdhitsolutions/PS-AutoLab-Env
Configurations/microsoft-powershell-implementing-jea/VMConfiguration.ps1
PowerShell
mit
35,182
$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...
alevyinroc/dbatools
tests/Get-DbaDbLogSpace.Tests.ps1
PowerShell
mit
3,227
param ( [string]$environmentName, [string]$resourceFilteringMethod, [string]$machineNames, [string]$scriptPath, [string]$scriptArguments, [string]$initializationScriptPath, [string]$runPowershellInParallel, [string]$sessionVariables ) Write-Verbose "Entering script PowerShellOnTarge...
SpotLabsNET/vso-agent-tasks
Tasks/PowerShellOnTargetMachines/PowerShellOnTargetMachines.ps1
PowerShell
mit
18,015
$icon_name = (Get-ChildItem "$env:ALLUSERSPROFILE\Microsoft\Windows\Start Menu\Programs" -Filter "Double Driver.lnk" -ErrorAction SilentlyContinue).FullName Remove-Item $icon_name -ErrorAction SilentlyContinue
sippi90/chocolateyautomaticpackages
doubledriver/tools/chocolateyuninstall.ps1
PowerShell
mit
210
#requires -Version 5 Configuration IBMWCM { param ( [Parameter(Mandatory)] [PSCredential] $InstallCredential, [Parameter(Mandatory)] [PSCredential] $WebSphereAdminCredential ) Import-DscResource -ModuleName 'PSDesiredStateConfiguration' ...
dennypc/cIBMWebSpherePortal
Examples/Install-WCM.ps1
PowerShell
mit
2,058
param($installPath, $toolsPath, $package, $project) $TargetsFile = 'keyvaultbuild.msbuild.targets' $TasksFile = 'keyvaultbuild.dll' $TargetsPath = $ToolsPath | Join-Path -ChildPath $TargetsFile $TasksFilePath = $ToolsPath | Join-Path -ChildPath $TasksFile Add-Type -AssemblyName 'Microsoft.Build, Version=4.0.0.0, Cult...
brendankowitz/KeyVaultBuild
src/KeyVaultBuild.Nuget/tools/install.ps1
PowerShell
mit
1,960
$here = Split-Path -Parent $MyInvocation.MyCommand.Path $sut = (Split-Path -Leaf $MyInvocation.MyCommand.Path).Replace('.Tests.', '.') #. "$here\$sut" #Import-Module "$PSScriptRoot\..\Support" . "$PSScriptRoot\..\Support\$sut" Describe 'PowerShell Object Notation' { Context 'ConvertFrom-Pson' { ...
nicholasdille/PowerShell
Tests/PSON.Tests.ps1
PowerShell
mit
1,197
#Requires -Version 3.0 #Requires -Module AzureRM.Resources #Requires -Module Azure.Storage Param( [string] [Parameter(Mandatory=$true)] $ResourceGroupLocation, [string] $ResourceGroupName = '2-iis-vms-sql-vm-template', [switch] $UploadArtifacts, [string] $StorageAccountName, [string] $StorageConta...
jiyongseong/AzureIaaSHol
resource_template/2-iis-vms-sql-vm-template/Deploy-AzureResourceGroup.ps1
PowerShell
mit
6,475
function Get-EnvironmentSettings { Param( [Parameter(Mandatory=$true)] [String] $ProductName, [Parameter(Mandatory=$true)] [String] $SettingsFilePath ) # Create the Hashtable $hash = @{} # Populate it if (Test-Path $settingsFilePath) { Write-Host "Loading settings from $settingsFilePath..." -NoNewl...
rakutensf-malex/slinqy
Source/Scripts/CI.Settings.ps1
PowerShell
mit
1,793
# Exit on any error $ErrorActionPreference = "Stop" # Get a tag for the build $Tag = Read-Host -Prompt "Enter a unique tag for build" # Build docker image docker build -t gcr.io/slacker-157712/api:$Tag ../ # Push image to google cloud gcloud docker push gcr.io/slacker-157712/api:$Tag # Write rc-file (Get-Content rc...
SufferForYourArt/slacker
deployment/rolling-update.ps1
PowerShell
mit
748
$key = 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System\Audit' #Create the key if missing ForceRegKey $key #Enable the Policy Set-ItemProperty -Path $key -Name 'ProcessCreationIncludeCmdLine_Enabled' -Value 1 -ea SilentlyContinue
DBHeise/VM_Setup
00_Windows/EnableCommandLineLoggingOnProcessStart.ps1
PowerShell
mit
248
function Get-PSWSUSUpdatePerClient { <# .SYNOPSIS Gets the summary of all updates for a client .DESCRIPTION Gets the summary of all updates for a client .PARAMETER ComputerName Name of the client to query .PARAMETER ComputerObject Collection ...
proxb/PoshWSUS
Scripts/Get-PSWSUSUpdatePerClient.ps1
PowerShell
mit
4,906
break # Partition GUID Get-ADDomain | ft Name, ObjectGUID -AutoSize # Invocation ID Get-ADDomainController -Filter * | ft Name, Domain, HostName, InvocationId -AutoSize # Naming contexts Get-ADRootDSE (Get-ADRootDSE).namingContexts Get-ADForest (Get-ADForest).PartitionsContainer Get-ADObject -SearchBase (Get-ADFores...
EmpressDeIT/PowerShell
AD_Powershell_MVA/06 - Replication/_6_2_Troubleshooting.ps1
PowerShell
mit
2,722
Function Test-SPUPSSyncHealth { [CmdletBinding()] param ( #[System.Management.Automation.Runspaces.PSSession]$RemoteSession, [hashtable]$PoShMonConfiguration ) Write-Verbose "Getting UPS Service App..." $upsApp = Invoke-RemoteCommand -PoShMonConfiguration $PoShMonCon...
HiltonGiesenow/PoShMon
src/Functions/PoShMon.Monitoring.SharePoint/Test-SPUPSSyncHealth.ps1
PowerShell
mit
3,761
properties { $buildName = "dev" } task default -depends Package task PreparePackage -depends Test { $packagesDirectory = '..\targets\packages' if (Test-Path -path $packagesDirectory) { rm $packagesDirectory -recurse -force } mkdir $packagesDirectory cp ..\build\package.nuspec ..\targets\packages mkdir ....
jonnii/emvelope
build/default.ps1
PowerShell
apache-2.0
3,021
#requires -version 2 <# .SYNOPSIS Outputs the last bootup time and uptime for one or more computers. .DESCRIPTION Outputs the last bootup time and uptime for one or more computers. .PARAMETER ComputerName One or more computer names. The default is the current computer. Wildcards are not supported. .PARAMETER Creden...
thedurf/test
get-uptime.ps1
PowerShell
apache-2.0
2,615
#constants $backupRootPath = "G:\Backup\" $pathsToCopy = "D:\Lenonardo", ` "E:\Code"#, ` #"D:\VMs" # for testing #$testBackupRootPath = "d:\Test" #$testPathToCopy = "D:\Downloads\Photos", "D:\Downloads\torrents", "D:\Downloads\pixelmon" function CopyFolder($sources, $destination){ fo...
leni-kirilov/scripts
powershell/Backup.ps1
PowerShell
apache-2.0
1,025
$packageName = 'storjshare' $installerType = 'exe' $silentArgs = '/S' $url = 'https://github.com/Storj/storjshare-gui/releases/download/v5.1.0/storjshare-gui.win32.exe' $checksum = 'c412353556656a4bdb03a753d745e545414a43c4e59ccf57b80c38eceae89e44' $checksumType = 'sha256' $url64 = 'https://github.com/Storj/storjshare-g...
dtgm/chocolatey-packages
automatic/_output/storjshare/5.1.0/tools/chocolateyInstall.ps1
PowerShell
apache-2.0
1,039
[CmdletBinding()] param( [Parameter(Mandatory=$false)] [string] $storagePoolName = 'DataDiskPool', [Parameter(Mandatory=$false)] [string] $diskName = 'DataDiskStripeSet' ) Write-Verbose 'Creating eventlog source' New-EventLog -LogName Application -Source DataDiskScript -ErrorAction SilentlyCo...
AzureInterface/azure-infrastructure-class
Monday/Lab3/New-DataDiskStripeSet.ps1
PowerShell
apache-2.0
2,375
$ChefTempFolder = "$env:SystemDrive\tmp\vagrant-chef-resources" if (-not (Test-Path $ChefTempFolder)) { Write-Host "Creating folder `'$ChefTempFolder`'" New-Item -Path "$ChefTempFolder" -ItemType Directory | Out-Null } # Copy-Item 'c:\vagrant\vagrant\chef\Cheffile' "$ChefTempFolder" Push-Location "$...
andrewbharrisiv/vagrant-windows-chef
vagrant/shell/PrepareProvisioner.ps1
PowerShell
apache-2.0
721
function Add-VSCodePipelinePipelineArtifactStore { <# .SYNOPSIS Adds an AWS::CodePipeline::Pipeline.ArtifactStore resource property to the template. The S3 bucket where artifacts for the pipeline are stored. .DESCRIPTION Adds an AWS::CodePipeline::Pipeline.ArtifactStore resource property to...
scrthq/Vaporshell
VaporShell/Public/Resource Property Types/Add-VSCodePipelinePipelineArtifactStore.ps1
PowerShell
apache-2.0
4,617
Function Resolve-ProjectName { Param( [parameter(ValueFromPipelineByPropertyName = $true)][string]$projectName ) If( $projectName ) { Get-Project $projectName } Else { Get-Project } } Function Get-ProjectFiles { Begin { $physicalFolderGuid = "{6BB5F8EF-4483-...
RazorGenerator/RazorGenerator
RazorGenerator.Powershell/RazorGenerator.psm1
PowerShell
apache-2.0
7,999
function Install-WhiskeyPowerShellModule { <# .SYNOPSIS Installs a PowerShell module. .DESCRIPTION The `Install-WhiskeyPowerShellModule` function installs a PowerShell module into a "PSModules" directory in the current working directory. It returns the path to the module. .EXAMP...
pshdo/LibGit2.PowerShell
.whiskey/Functions/Install-WhiskeyPowerShellModule.ps1
PowerShell
apache-2.0
2,897
function Add-VSEMRInstanceGroupConfigScalingTrigger { <# .SYNOPSIS Adds an AWS::EMR::InstanceGroupConfig.ScalingTrigger resource property to the template. ScalingTrigger is a subproperty of the ScalingRule property type. ScalingTrigger determines the conditions that trigger an automatic scaling activity...
scrthq/Vaporshell
VaporShell/Public/Resource Property Types/Add-VSEMRInstanceGroupConfigScalingTrigger.ps1
PowerShell
apache-2.0
2,292
#Requires -Version 4.0 param( [parameter(Mandatory=$true)] [System.String] $machineName ) <# .SYNOPSIS Adds a tentacle machine to the development environment for Octopus Deploy #> $octopusDeployAPIUrl = 'YOUR OCTOPUS SERVER API URL' $baseMachinesEndpoint = "$octopusDeployAPIUrl/machines" $discoverMachineEndpoint ...
jlouros/PowerShell-toolbox
Octopus-Deploy/API/Add-Machine.ps1
PowerShell
mit
1,409