Skip to content

Instantly share code, notes, and snippets.

View PSTitleTetris.ps1
$blocks = @()
$blockChain = @()
#$blocks += New-Object -TypeName psobject -Property @{c = [char]0x2597; s=@(0,0,0,1); w=3}
#$blocks += New-Object -TypeName psobject -Property @{c = [char]0x259d; s=@(0,1,0,0); w=2}
$blocks += New-Object -TypeName psobject -Property @{c = [char]0x2599; s=@(1,0,1,1); w=4}
$blocks += New-Object -TypeName psobject -Property @{c = [char]0x259b; s=@(1,1,1,0); w=3}
$blocks += New-Object -TypeName psobject -Property @{c = [char]0x259c; s=@(1,1,0,1); w=3}
$blocks += New-Object -TypeName psobject -Property @{c = [char]0x259f; s=@(0,1,1,1); w=3}
$blocks += New-Object -TypeName psobject -Property @{c = [char]0x258d; s=@(0,0,1,1); w=2}
@mdjx
mdjx / gist:2822c26977dea24d0baa3aaf7744c177
Last active Mar 23, 2020
Output Veeam Jobs with target repository and total backup size per job
View gist:2822c26977dea24d0baa3aaf7744c177
Get-VBRJob | select Name, @{N="Repository";E={$_.GetTargetRepository().Name}}, @{N="TotalSize"; E={[Math]::Round(((Get-VBRBackup -Name $_.Name | Sort-Object {$_.LastPointCreationTime -As [DateTime]} -Descending | Select -First 1).GetAllStorages().Stats.BackupSize | Measure-Object -Sum).Sum / 1Gb,2)}}
@mdjx
mdjx / gist:c2164f3ef168e83ecb83a0b62afbed91
Last active Mar 23, 2020
COVID-19 Case Numbers in Australia per State
View gist:c2164f3ef168e83ecb83a0b62afbed91
((iwr "https://www.health.gov.au/news/health-alerts/novel-coronavirus-2019-ncov-health-alert/coronavirus-covid-19-current-situation-and-case-numbers").ParsedHtml.getElementsByClassName("health-table__responsive")[0].outerText -replace(',','') -replace ('\d{1,}',',$0') -split ('\n')).trim()[1..9] | ConvertFrom-Csv -Header "State","Cases"
You can’t perform that action at this time.