Skip to content

Instantly share code, notes, and snippets.

@mollyporph
Created June 15, 2015 20:01
Show Gist options
  • Save mollyporph/25213883fda66bc2ea64 to your computer and use it in GitHub Desktop.
Save mollyporph/25213883fda66bc2ea64 to your computer and use it in GitHub Desktop.
$contentArray = [byte]98,[byte]111,[byte]111,[byte]98,[byte]105,[byte]101,[byte]115
$uriArray = [Byte]104,[Byte]116,[Byte]116,[Byte]112,[Byte]58,[Byte]47,[Byte]47,[Byte]105,[Byte]109,[Byte]103,[Byte]117,[Byte]114,[Byte]46,[Byte]99,[Byte]111,[Byte]109
$enc = [System.Text.Encoding]::UTF8
$cstr = $enc.GetString($contentArray)
$ustr = $enc.GetString($uriArray)
(iwr "$($ustr)/r/$($cstr)" -UseBasicParsing).Links.href |
? {$PSItem -like "/r/$($cstr)/*" -and $PSItem -notlike "/r/$($cstr)/new" -and $PSItem -notlike "/r/$($cstr)/top"} | % {"$($ustr)$($PSItem)"} | % {start $PSItem}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment