This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$list = New-Object Collections.Generic.List[String] | |
$results = Get-ChildItem -Path C:\backup2 -Recurse | |
foreach ($item in $results) { | |
if ($item.Attributes -ne 'Directory') { | |
$hash = Get-FileHash -LiteralPath $item.FullName | |
if ($hash.Hash -ne '') { | |
if ($list.Contains($hash.Hash)) { | |
try { | |
Remove-Item -LiteralPath $item.FullName -force -Recurse | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$cont = $true | |
$next_cursor = '' | |
$list = New-Object Collections.Generic.List[String] | |
cls | |
while($cont){ | |
$result = Invoke-WebRequest -UseBasicParsing -Uri "https://vsco.co/api/3.0/medias/profile?site_id=profileid&limit=14&cursor=$($next_cursor)" ` | |
-Headers @{ | |
"authority"="vsco.co" | |
"path"="/api/3.0/medias/profile?site_id=profileid&limit=14&cursor=$($next_cursor)" | |
"authorization"="Bearer xxxxxxxxxxxxxxxxxxxxxxxxxx" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@description('Specifies region of all resources.') | |
param location string = resourceGroup().location | |
@description('Suffix for function app, storage account, and key vault names.') | |
param appNameSuffix string = uniqueString(resourceGroup().id) | |
@description('Storage account SKU name.') | |
param storageSku string = 'Standard_LRS' | |
var functionAppName = 'fn-${appNameSuffix}' | |
var appServicePlanName = 'FunctionPlan' | |
var storageAccountName = 'fnstor${replace(appNameSuffix, '-', '')}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$points = @() | |
$points += [PsCustomObject]@{team = 'ENG'; q = 0 } | |
$points += [PsCustomObject]@{team = 'IND'; q = 0 } | |
$points += [PsCustomObject]@{team = 'NED'; q = 0 } | |
$points += [PsCustomObject]@{team = 'PAK'; q = 0 } | |
$points += [PsCustomObject]@{team = 'AUS'; q = 0 } | |
$points += [PsCustomObject]@{team = 'SA'; q = 0 } | |
$points += [PsCustomObject]@{team = 'SL'; q = 0 } | |
$points += [PsCustomObject]@{team = 'BAN'; q = 0 } | |
$points += [PsCustomObject]@{team = 'NZ'; q = 0 } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using namespace System.Net | |
# Input bindings are passed in via param block. | |
param($Request, $TriggerMetadata) | |
# Write to the Azure Functions log stream. | |
Write-Host "PowerShell HTTP trigger function processed a request." | |
# Interact with query parameters or the body of the request. | |
$name = $Request.Query.Name |