Last active
August 29, 2015 14:08
-
-
Save paully21/3486abdd9f9233bccc39 to your computer and use it in GitHub Desktop.
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
$feedUrl = "http://channel9.msdn.com/Events/TechEd/Europe/2014/RSS/mp4high" | |
[Environment]::CurrentDirectory=(Get-Location -PSProvider FileSystem).ProviderPath | |
$rss = (new-object net.webclient) | |
$a = ([xml]$rss.downloadstring($feedUrl)) | |
$a.rss.channel.item | foreach{ | |
$url = New-Object System.Uri($_.enclosure.url) | |
$file = $_.title.Replace(":", "-").Replace("?", "").Replace("/", "-") + "-" + $_.creator + ".mp4" | |
if (!(test-path $file)) | |
{ | |
$file | |
$wc = (New-Object System.Net.WebClient) | |
$wc.DownloadFile($url, $file) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment