full_path
stringlengths
31
232
filename
stringlengths
4
167
content
stringlengths
0
48.3M
PowerShellCorpus/Github/PYANTSU_test/Recon/Get-HttpStatus.ps1
Get-HttpStatus.ps1
function Get-HttpStatus { <# .SYNOPSIS Returns the HTTP Status Codes and full URL for specified paths. PowerSploit Function: Get-HttpStatus Author: Chris Campbell (@obscuresec) License: BSD 3-Clause Required Dependencies: None Optional Dependencies: None .DESCRIPTION A script to check for the existen...
PowerShellCorpus/Github/PYANTSU_test/Recon/Invoke-Portscan.ps1
Invoke-Portscan.ps1
function Invoke-Portscan { <# .SYNOPSIS Simple portscan module PowerSploit Function: Invoke-Portscan Author: Rich Lundeen (http://webstersProdigy.net) License: BSD 3-Clause Required Dependencies: None Optional Dependencies: None .DESCRIPTION Does a simple port scan using regular sockets, based (prett...
PowerShellCorpus/Github/PYANTSU_test/Recon/Get-ComputerDetails.ps1
Get-ComputerDetails.ps1
function Get-ComputerDetails { <# .SYNOPSIS This script is used to get useful information from a computer. Function: Get-ComputerDetails Author: Joe Bialek, Twitter: @JosephBialek Required Dependencies: None Optional Dependencies: None Version: 1.1 .DESCRIPTION This script is used to get useful infor...
PowerShellCorpus/Github/rjygraham_CalculatorSample/src/CalculatorSample.Client.Web/Properties/PublishProfiles/math-client - Web Deploy-publish.ps1
math-client - Web Deploy-publish.ps1
[cmdletbinding(SupportsShouldProcess=$true)] param($publishProperties=@{}, $packOutput, $pubProfilePath) # to learn more about this file visit https://go.microsoft.com/fwlink/?LinkId=524327 try{ if ($publishProperties['ProjectGuid'] -eq $null){ $publishProperties['ProjectGuid'] = '35d77939-2a54-464...
PowerShellCorpus/Github/rjygraham_CalculatorSample/src/CalculatorSample.Api.Web/Properties/PublishProfiles/Local-publish.ps1
Local-publish.ps1
[cmdletbinding(SupportsShouldProcess=$true)] param($publishProperties=@{}, $packOutput, $pubProfilePath) # to learn more about this file visit https://go.microsoft.com/fwlink/?LinkId=524327 try{ if ($publishProperties['ProjectGuid'] -eq $null){ $publishProperties['ProjectGuid'] = 'b2eb8a9b-f32d-470...
PowerShellCorpus/Github/rjygraham_CalculatorSample/src/CalculatorSample.Api.Web/Properties/PublishProfiles/math-api - Web Deploy-publish.ps1
math-api - Web Deploy-publish.ps1
[cmdletbinding(SupportsShouldProcess=$true)] param($publishProperties=@{}, $packOutput, $pubProfilePath) # to learn more about this file visit https://go.microsoft.com/fwlink/?LinkId=524327 try{ if ($publishProperties['ProjectGuid'] -eq $null){ $publishProperties['ProjectGuid'] = 'b2eb8a9b-f32d-470...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/logstash-contrib/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
# $package_version = "{{PackageVersion}}" $url="{{DownloadUrl}}" $package_name = 'logstash-contrib' $package_dir="c:\logstash" Write-Host "Making sure there are no traces of an old installation temp files. Cleaning up ${package_dir}\${package_name}-*\*" Get-ChildItem "${package_dir}" | Where-Object {$_.Name ...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/logstash-contrib/build/versionBump.ps1
versionBump.ps1
[decimal]$i = Get-Content "_pkgrev" $i++ Set-Content "_pkgrev" $i
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyautomsi/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyautomsi/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$packageName = '__NAME__' # arbitrary name for the package, used in messages try { # http://stackoverflow.com/questions/450027/uninstalling-an-msi-file-from-the-command-line-without-using-msiexec $msiArgs = "/X __MSI_GUID__ /qb" Start-ChocolateyProcessAsAdmin "$msiArgs" 'msiexec' Write-Chocolatey...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyauto3/__NAME__/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#Install-VirtualPackage '__NAME__.portable' '__NAME__.install'
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyauto3/__NAME__.install/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyauto3/__NAME__.portable/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyautorev/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyautorev/build/versionBump.ps1
versionBump.ps1
[decimal]$i = Get-Content "_pkgrev" $i++ Set-Content "_pkgrev" $i
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolateyauto/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolatey/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = '__NAME__' # arbitrary name for the package, used in messages $installerType = 'EXE_MSI_OR_MSU' #only one of these: exe, msi, msu $url = 'URL_HERE' # download url $url64 = 'URL_x64_HERE' # 64bit U...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolatey3/__NAME__/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#Install-VirtualPackage '__NAME__.portable' '__NAME__.install'
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolatey3/__NAME__.install/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = '__NAME__.install' # arbitrary name for the package, used in messages $installerType = 'EXE_MSI_OR_MSU' #only one of these: exe, msi, msu $url = 'URL_HERE' # download url $url64 = 'URL_x64_HERE' #...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/_templates/chocolatey3/__NAME__.portable/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = '__NAME__.portable' # arbitrary name for the package, used in messages $url = 'URL_HERE/.zip/.7z' # download url $url64 = 'URL_x64_HERE' # 64bit URL here or remove - if installer decides, then use ...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/newrelic-dotnet/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/newrelic-dotnet/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$packageName = 'newrelic-dotnet' # arbitrary name for the package, used in messages try { # http://stackoverflow.com/questions/450027/uninstalling-an-msi-file-from-the-command-line-without-using-msiexec $msiArgs = "/X {1E9129D9-6FFB-4223-A6CC-E6D7BC21C38C} /qb" Start-ChocolateyProcessAsAdmin "$msiArgs...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/moxi/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#In order perform an unattended installation the setup.iss file must be in the same directory as the installer $url="{{DownloadUrl}}" $package_name = 'moxi' $package_dir = "c:\${package_name}" if (!(Test-Path -path ${package_dir})) { echo "Creating $package_dir" New-Item "${package_dir}" -Type Directory | ...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/logstash/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
# $package_version = "{{PackageVersion}}" $url="{{DownloadUrl}}" $package_name = 'logstash' $service_name = "Logstash" $package_dir="c:\${package_name}" $current_datetime = Get-Date -format yyyyddMMhhmm $package_backup_dir = "${package_dir}-old_${current_datetime}" $bin_dir = $(Join-Path $package_dir "bin"...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/logstash/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$package_name = 'logstash' $service_name = "Logstash" $package_dir="c:\$package_name" if (Get-Service "$service_name" -ErrorAction SilentlyContinue) { try { if ($(Get-Service "$service_name" -ErrorAction SilentlyContinue).Status -eq "Running") { # Start-ChocolateyProcessAsAdmin "Stop...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/logstash/build/versionBump.ps1
versionBump.ps1
[decimal]$i = Get-Content "_pkgrev" $i++ Set-Content "_pkgrev" $i
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/mongodb.core.2.6/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one #Items that could be replaced based on what you call chocopkgup.exe with #{{PackageName}} - Package Name (should be same as nuspec file and folder) |/p #{{PackageVersion}} - The updated version | /v #{{DownloadU...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/mongodb.core.2.6/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$package_version = "2.6" $package_name = 'mongodb.core.2.6' $package_dir = Join-Path "c:\mongodb" $package_version Write-Host "Uninstall script found" try { Write-Host "Cleaning ${package_dir} directory" Remove-Item -recurse $(Join-Path $package_dir "\") -exclude *.conf, *-bak*, *-old* -forc...
PowerShellCorpus/Github/kireevco_chocolatey-packages/automatic/mongodb.core.2.6/build/versionBump.ps1
versionBump.ps1
[decimal]$i = Get-Content "_pkgrev" $i++ Write-Host "Incrementing _pkgrev" Set-Content "_pkgrev" $i
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.4.0/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://www.dropbox.com/s/mxwnizswcs7n94h/SysMgmtx64.msi?dl=1' Install-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.4.0/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
Write-Error "Uninstall not implemented in a package yet."
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/wmisecurity/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#Using personal website, because codeplex doesn't allow do download without registration (is there a way?) $url='http://blog.kireev.co/wp-content/uploads/wmisecurity.zip' $packageName = 'wmisecurity' Install-ChocolateyZipPackage $packageName $url "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/sming.core/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'sming' $packageVersion = '2.1.0' $url="https://github.com/anakod/Sming/archive/${packageVersion}.zip" $binRoot = Get-BinRoot $installDir = Join-Path "$binRoot" 'sming' Install-ChocolateyZipPackage "$packageName" $url $installDir Copy-Item $installDir/Sming-$packageVersion/* $installDir/ -Force...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.6.2.0/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://www.dropbox.com/s/t81spoc62ys92wk/SysMgmt.msi?dl=1' Install-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.6.2.0/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
Write-Error "Uninstall not implemented in a package yet."
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/maxmind-geoip-dat/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#Using personal website, because codeplex doesn't allow do download without registration (is there a way?) $packageName = 'maxmind-geoip-dat' if ([string]::IsNullOrEmpty($env:chocolateyPackageParameters)) { #Write-ChocolateyFailure 'Path parameter not found. Please specify -params "path=c:\\package-path\\direc...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/srecord/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'srecord' $packageVersion = '1.64' $url="http://downloads.sourceforge.net/project/srecord/srecord-win32/${packageVersion}/srecord-${packageVersion}-win32.zip" $binRoot = Get-BinRoot $installDir = Join-Path "$binRoot" 'mingw64\bin' Install-ChocolateyZipPackage "$packageName" $url $installDir
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.1.0/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://dl.dropboxusercontent.com/s/aqt749c8f3f0hxd/SysMgmt.msi?dl=1' Install-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.1.0/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
#$url = 'https://dl.dropboxusercontent.com/s/aqt749c8f3f0hxd/SysMgmt.msi?dl=1' #Uninstall-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url #cmd /k 'msiexec.exe /x /qn {A8D0C330-84F0-4675-B997-0E952FA0A0A3}' #cmd /k 'msiexec.exe /x {A8D0C330-84F0-4675-B997-0E952FA0A0A3} /qn' #cmd /k 'msiexec.exe /x /qn {A8D0C330-8...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/mysql-connector/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'http://dev.mysql.com/get/Downloads/Connector-Net/mysql-connector-net-6.6.6.msi' Install-ChocolateyPackage 'mysql-connector' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/mysql-connector/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
Write-Error "Uninstall not implemented in a package yet."
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/wuinstall.run/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
if ([string]::IsNullOrEmpty($env:chocolateyInstallArguments)) { wuInstall /install /logfile_append c:\wuinstall.log /disable_ie_firstruncustomize /reboot_if_needed /autoaccepteula /rebootcycle 3 /quiet } else { wuInstall $env:chocolateyInstallArguments }
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/esp8266-udk/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url='https://github.com/CHERTS/esp8266-devkit/releases/download/v2.0.9/Espressif-ESP8266-DevKit-v2.0.9-x86.exe' $packageName = 'esp8266-udk' $installerType = 'exe' $silentArgs = '/VERYSILENT' $installDir = 'c:/Espressif' $symLinkName = $(Join-Path $installDir 'sdk') $symLinkTarget = $(Join-Path $installDir 'ESP...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/esp8266-udk/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$url='https://github.com/CHERTS/esp8266-devkit/releases/download/v2.0.9/Espressif-ESP8266-DevKit-v2.0.9-x86.exe' $packageName = 'esp8266-udk' $installerType = 'exe' $silentArgs = '/VERYSILENT' $installDir = 'c:/Espressif' $symLinkName = $(Join-Path $installDir 'sdk') function Test-ReparsePoint([string]$path)...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/vmware-tools/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url='http://packages.vmware.com/tools/esx/5.5latest/windows/x86/VMware-tools-9.4.12-2627939-i386.exe' $url64='http://packages.vmware.com/tools/esx/5.5latest/windows/x64/VMware-tools-9.4.12-2627939-x86_64.exe' $packageName = 'vmware-tools' $fileType = 'exe' $silentArgs = '/S /v /qn' Install-ChocolateyPackage $pa...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/mongodb.core.2.4/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = 'mongodb.core.2.4' # arbitrary name for the package, used in messages $packageDirectory = 'mongodb' $mongoVersion = '2.4.9' $isWin7_2008R2_OrGreater = [Environment]::OSVersion.Version -ge (new...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/spiffy/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'spiffy' $packageVersion = '1.0.4' $url="https://bintray.com/artifact/download/kireevco/generic/spiffy-${packageVersion}-win32-x86_64.zip" $url64="https://bintray.com/artifact/download/kireevco/generic/spiffy-${packageVersion}-win32-x86_64.zip" $binRoot = Get-BinRoot $installDir = Join-Path "$binRoo...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/sming.upgrade/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'sming.upgrade' $packageVersion = '1.1.0' $binRoot = Get-BinRoot #### SDK Symlink #### # We need this to make sure Windows, MacOS, Linux users have same experience $espressifInstallDir = 'c:\Espressif' $symLinkName = $(Join-Path $espressifInstallDir 'sdk') $symLinkTarget = $(Join-Path $espressi...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.2.0/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://www.dropbox.com/s/xkbopm5cfq6ndl5/SysMgmt.msi?dl=1' Install-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.7.2.0/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
Write-Error "Uninstall not implemented in a package yet."
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/eclipse-cpp/tools/Uninstall-ChocolateyZipPackage030.ps1
Uninstall-ChocolateyZipPackage030.ps1
function Uninstall-ChocolateyZipPackage030 { param( [string] $packageName ) if(!$packageName) { Write-ChocolateyFailure "Uninstall-ChocolateyZipPackage030" "Missing PackageName input parameter." return } ChildItem "$env:ChocolateyInstall\lib\${packageName}.*" -Recurse -Filter "${packageName}Install....
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/eclipse-cpp/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'eclipse-cpp' $packageVersion = '4.4.2' $32BitUrl = 'https://bintray.com/artifact/download/kireevco/generic/eclipse-cpp-luna-SR2-win32.zip' $64BitUrl = 'https://bintray.com/artifact/download/kireevco/generic/eclipse-cpp-luna-SR2-win32-x86_64.zip' $global:installLocation = "C:\Program Files\Eclips...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/eclipse-cpp/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$packageName = 'eclipse' if(!$PSScriptRoot){ $PSScriptRoot = Split-Path $MyInvocation.MyCommand.Path -Parent } . "$PSScriptRoot\Uninstall-ChocolateyZipPackage030.ps1" Uninstall-ChocolateyZipPackage030 "$packageName"
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/eclipse-cpp/tools/OverwriteParameters030.ps1
OverwriteParameters030.ps1
function OverwriteParameters030 { $arguments = @{}; $packageParameters = $env:chocolateyPackageParameters; if($packageParameters) { $MATCH_PATTERN = "/([a-zA-Z]+)=(.*)(`")" $PARAMATER_NAME_INDEX = 1 $VALUE_INDEX = 2 if($packageParameters -match $MATCH_PATTERN){ $results = $packageParameters ...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/logstash-forwarder/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://download.elasticsearch.org/logstash-forwarder/binaries/logstash-forwarder_windows_386.exe' $url64bit = $url $packageName = 'logstash-forwarder' $serviceName = 'Logstash Forwarder' $binRoot = Get-BinRoot $installDir = Join-Path $binRoot $packageName $fileFullPath = Join-Path $installDir "${packageN...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/logstash-forwarder/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
$packageName = 'logstash-forwarder' $serviceName = 'Logstash Forwarder' $binRoot = Get-BinRoot $installDir = Join-Path $binRoot $packageName if (Get-Service "$serviceName" -ErrorAction SilentlyContinue) { try { if ($(Get-Service "$serviceName" -ErrorAction SilentlyContinue).Status -eq "Running...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.5.5.0/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url = 'https://www.dropbox.com/s/6olmbjp9px0lt46/SysMgmt.msi?dl=1' Install-ChocolateyPackage 'dell-omsa' 'msi' '/qn' $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/dell-omsa.5.5.0/tools/chocolateyUninstall.ps1
chocolateyUninstall.ps1
Write-Error "Uninstall not implemented in a package yet."
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/sming.examples/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
Update-SessionEnvironment $packageName = 'sming.examples' $packageVersion = '2.1.0' $url="https://github.com/SmingHub/Sming/archive/${packageVersion}.zip" $binRoot = Get-BinRoot $installDir = Join-Path "$binRoot" 'sming.examples' $eclipseWorkspace = Join-Path $env:HOMEPATH "sming.examples" function Install-Cho...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/mongodb.core.2.2/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = 'mongodb.core.2.2' # arbitrary name for the package, used in messages $packageDirectory = 'mongodb' $mongoVersion = '2.2.7' $isWin7_2008R2_OrGreater = [Environment]::OSVersion.Version -ge (new...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/bc/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'bc' $packageVersion = '1.06-2' $url="http://downloads.sourceforge.net/project/gnuwin32/bc/${packageVersion}/bc-${packageVersion}.exe" $binRoot = Get-BinRoot $installDir = "${binRoot}\mingw64" Install-ChocolateyPackage 'bc' 'exe' "/SILENT /DIR=${installDir}" $url
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/wuinstall/tools/chocolateyInstall_.ps1
chocolateyInstall_.ps1
$packageName = 'wuinstall' $user_agent = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.112 Safari/534.30' $accept_content = 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' $url = 'https://www.wuinstall.com/index.php/component/wui...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/wuinstall/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'wuinstall' $user_agent = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.112 Safari/534.30' $accept_content = 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' $url = 'https://www.wuinstall.com/index.php/component/wui...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/opsview-agent/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$url='https://s3.amazonaws.com/opsview-agents/Windows/Opsview_Windows_Agent_Win32_28-01-15-1559.msi' $url64='https://s3.amazonaws.com/opsview-agents/Windows/Opsview_Windows_Agent_x64_28-01-15-1600.msi' $packageName = 'opsview-agent' $fileType = 'msi' $silentArgs = '/qn' Install-ChocolateyPackage $packageName $fi...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/sming/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
$packageName = 'sming' $binRoot = Get-BinRoot $installDir = Join-Path "$binRoot" 'sming' $mingwPath = "$binRoot\mingw64" $mingw_get = Join-Path "$binRoot" "/mingw64/bin/mingw-get.exe" function mingw-install ([string]$mingwPackageName) { Start-ChocolateyProcessAsAdmin "install ${mingwPackageName} --reins...
PowerShellCorpus/Github/kireevco_chocolatey-packages/manual/mongodb.core/tools/chocolateyInstall.ps1
chocolateyInstall.ps1
#NOTE: Please remove any commented lines to tidy up prior to releasing the package, including this one $packageName = 'mongodb.core' # arbitrary name for the package, used in messages $packageDirectory = 'mongodb' $mongoVersion = '2.2.7' $isWin7_2008R2_OrGreater = [Environment]::OSVersion.Version -ge (new-obj...
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/classes/speech/speech-class.ps1
speech-class.ps1
<# Add-Type Assemblies #> Add-Type -AssemblyName System.Speech <# .SYNOPSIS This class utilizes the System.Speech, so that you can make your scripts talk. .DESCRIPTION See synopsis. .EXAMPLE $Speech = New-Object Speech $Speech.Speak("Hello") #> Class Speech { Speak ($Str...
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/profile/add-profile.ps1
add-profile.ps1
<# .SYNOPSIS This script takes care of loading my powershell profile onto the system I am currently working on. .DESCRIPTION See synopsis. .EXAMPLE Add-Profile #> function Add-Profile { $Username = $Env:USERNAME $ProfilePath = "C:\Users\$Username\Documents\playingwithpowershell\profi...
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/profile/cbbps_profile.ps1
cbbps_profile.ps1
# Original script by: Prateek Singh - https://geekeefy.wordpress.com # Modified by: Morten Haugstad - https://codebarbarian.priv.no # Function to Get Custom Directory path Write-Host ' ______ __ ____ __ _ / ____/___ ____/ /__ / __ )____ ______/ /_ ...
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/functions/googlemaps.ps1
googlemaps.ps1
<# .SYNOPSIS This script uses the Google Maps API to convert an address into cordinates you can use for spatial analysis or mapping .DESCRIPTION See synopsis. This also shows how to handle Json in powershell to some degree. To get an API key to use google maps, go to: https://developers.google....
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/functions/show-picture.ps1
show-picture.ps1
# =================== Script Config =================== # # -------------Script dependant variables-------------- # $AdjustmentWidth = 15 # This is to adjust for the form Width (in pixels) $AdjustmentHeight = 30 # This is to adjust for the form Height (in pixels) <# .SYNOPSIS Show-Picture .DESCRIPTION ...
PowerShellCorpus/Github/CodeBarbarian_playingwithpowershell/functions/ps-grep.ps1
ps-grep.ps1
<# .SYNOPSIS PS-Grep -options pattern input_file_names .DESCRIPTION My version of the all powerfull grep utility on *nix based systems .EXAMPLE PS-Grep #> function PS-Grep { }
PowerShellCorpus/Github/Luciannam_AD-Scripts/changeowner.ps1
changeowner.ps1
#changing the owner for a list of groups. $input = Read-Host -Prompt "Enter the new owner SAMAccountName:" $owner = "" $owner = Get-ADUser $input if ($owner ) {Write-Host "Onwer found in AD. Importing the groups from the current directory" -ForegroundColor Yellow $groups = Get-Content .\groups.txt ...
PowerShellCorpus/Github/RobRobertsCE_CEArchitecture/NTierSample/packages/Newtonsoft.Json.9.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/RobRobertsCE_CEArchitecture/NTierSample/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/RobRobertsCE_CEArchitecture/NTierSample/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/apetrovskiy_links/SharePoint/SharePointScriptCenter.ps1
SharePointScriptCenter.ps1
http://gallery.technet.microsoft.com/scriptcenter/site/search?f%5B0%5D.Type=RootCategory&f%5B0%5D.Value=sharepoint&f%5B0%5D.Text=SharePoint http://gallery.technet.microsoft.com/scriptcenter/Create-SharePoint-Web-742a8fb9 http://gallery.technet.microsoft.com/scriptcenter/Copy-all-SharePoint-Files-0999c53f http://gall...
PowerShellCorpus/Github/apetrovskiy_links/Programming/PowerShell/ListDomainObjects.ps1
ListDomainObjects.ps1
function Test-ADSI { param( [string]$DomainName ) "$($env:USERDOMAIN)\$($env:USERNAME)" [string]$domainTail = "DC=" + $DomainName.Replace(".", ",DC="); WRite-Host "Deleting object in the '$($domainTail)' namespace"; $ouList = @( "OU=AT_GroupPolicyObjects,$($domainTail)", "OU=AT_ObjectsForAlerts,$($do...
PowerShellCorpus/Github/apetrovskiy_links/Programming/PowerShell/ListDomainObjectsV2.ps1
ListDomainObjectsV2.ps1
function Test-ADSI { param( [string]$DomainName ) Write-Host "$($env:USERDOMAIN)\$($env:USERNAME)" [string]$domainTail = "DC=" + $DomainName.Replace(".", ",DC="); Write-Host "Deleting object in the '$($domainTail)' namespace"; $ouList = @( "OU=AT_GroupPolicyObjects,$($domainTail)", "OU=AT_ObjectsForA...
PowerShellCorpus/Github/apetrovskiy_links/Programming/PowerShell/ListDomainObjectsV3.ps1
ListDomainObjectsV3.ps1
function Write-UserInfo { Write-Host "user info:"; Write-Host "$($env:USERDOMAIN)\$($env:USERNAME)"; Write-Host "$(hostname)" } #$global:sb = (get-command "Write-UserInfo" -CommandType Function).ScriptBlock $sb = ${function:Write-UserInfo}; function Test-ADSI { param( [string]$DomainName, $fn1 ...
PowerShellCorpus/Github/apetrovskiy_links/Programming/UIA/example.ps1
example.ps1
Add-Type -AssemblyName UIAutomationClient Add-Type -AssemblyName UIAutomationTypes $windows = [System.Windows.Automation.AutomationElement]::RootElement.FindFirst([System.Windows.Automation.TreeScope]::Children, (New-Object System.Windows.Automation.PropertyCondition([System.Windows.Automation.AutomationElement]::Nam...
PowerShellCorpus/Github/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/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/alienware2020_mvcApplication/PublishScripts/Publish-WebApplicationWebsite.ps1
Publish-WebApplicationWebsite.ps1
#Requires -Version 3.0 <# .SYNOPSIS Creates and deploys a Microsoft Azure Website for a Visual Studio web project. For more detailed documentation go to: http://go.microsoft.com/fwlink/?LinkID=394471 .EXAMPLE PS C:\> .\Publish-WebApplicationWebSite.ps1 ` -Configuration .\Configurations\WebApplication1-WAWS-...
PowerShellCorpus/Github/ZombieChamp_Restart-Service/service.ps1
service.ps1
[CmdletBinding()] Param( [parameter(Mandatory=$true, HelpMessage="Name of the service")] [string]$service ) $serviceObj = Get-Service $service Write-Verbose ('Stopping '+$service) Stop-Service $service -WarningAction SilentlyContinue $serviceObj.WaitForStatus('Stopped') Write-Verbose ('Starting '+$service) ...
PowerShellCorpus/Github/OPSTest_E2E_NewRepo_201711815243/.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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/mwerner340_NewMovies/MvcMovieProject/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/meuhedetsystem_Powershell_Profile/Microsoft.PowerShellISE_profile.ps1
Microsoft.PowerShellISE_profile.ps1
#add-pssnapin Microsoft.Exchange.Management.PowerShell.E2010 If (!(Get-module "activedirectory")) { Import-Module "activedirectory" } $ExSession = New-PSSession ¢ConfigurationName Microsoft.Exchange ¢ConnectionUri æhttp://cas01.meuhedet.org/powershell?serializationLevel=Full' Import-PSSession $ExSession Set-Loc...