View array.json
{ | |
"$schema": "http://json-schema.org/draft-07/schema", | |
"$id": "http://example.com/example.json", | |
"type": "object", | |
"title": "The root schema", | |
"description": "The root schema comprises the entire JSON document.", | |
"default": {}, | |
"examples": [ | |
{ | |
"products": [ |
View pipeline.yaml
trigger: none | |
pool: | |
vmImage: 'windows-2019' | |
resources: | |
repositories: | |
- repository: tools | |
type: github | |
name: Azure-Devops-PowerShell-Module/tools |
View data.json
{ | |
"subject": "linescore_mlb_2019_08_09_anamlb_bosmlb_1", | |
"copyright": "NOTICE: This file is no longer actively supported. Please use the MLB Stats API (http://statsapi.mlb.com/docs/) as an alternative. Copyright 2019 MLB Advanced Media, L.P. Use of any content on this page acknowledges agreement to the terms posted here http://gdx.mlb.com/components/copyright.txt", | |
"data": { | |
"game": { | |
"linescore": [{ | |
"away_inning_runs": "3", | |
"home_inning_runs": "1", | |
"inning": "1" | |
}, { |
View encoding-helpers.ps1
<# | |
.SYNOPSIS | |
Converts files to the given encoding. | |
Matches the include pattern recursively under the given path. | |
.EXAMPLE | |
Convert-FileEncoding -Include *.js -Path scripts -Encoding UTF8 | |
#> | |
function Convert-FileEncoding([string]$Include, [string]$Path, [string]$Encoding='UTF8') { | |
$count = 0 |
View odbc-excel.ps1
param | |
( | |
$strFileName = "C:scriptsfile.xlsx", | |
$strSheetName = 'Out' | |
) | |
if (!(($strSheetName.Substring($strSheetName.Length-1,1)) -eq '$')) | |
{ | |
$strSheetName = "$($strSheetName)`$" | |
} | |
$strProvider = "Provider=Microsoft.ACE.OLEDB.12.0" |
View rollback.ps1
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0\Server"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 3.0\Server"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 3.0\Client"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Client"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Client"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Client"; | |
Remove-Item "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\ |
View Get-RecentEvent.ps1
param | |
( | |
$StartDate = (Get-Date), | |
$EndDate = (Get-Date) | |
) | |
try | |
{ | |
$ErrorActionPreference = 'Stop'; | |
$Error.Clear(); |
View mpprovider.ps1
import-module 'C:\Program Files\Microsoft Security Client\MpProvider\MpProvider.psd1' | |
get-mprotcomputerstatus |
View New-Password.ps1
Function New-Password | |
{ | |
<# | |
.SYNOPSIS | |
Create a new password | |
.DESCRIPTION | |
This function creates a password using the cryptographic Random Number Generator see the | |
MSDN link for more details. | |
.PARAMETER Length | |
An integer that defines how long the password should be |
View New-WordTable.ps1
Function New-WordTable { | |
[cmdletbinding( | |
DefaultParameterSetName='Table' | |
)] | |
Param ( | |
[parameter()] | |
[object]$WordObject, | |
[parameter()] | |
[object]$Object, | |
[parameter()] |
NewerOlder