Posts

Showing posts with the label Regex

HOW TO remove time codes from a WebVTT file

Image
MSDN Channel 9 has started providing captions for videos in WebVTT (Web Video Text Tracks) format. This means, you can use that file to read it as a transcript when you are on a low bandwidth Internet connection instead of watching the video. You can grab the subtitles file by appending /captions?f=webvtt&l=en to the Channel 9 video (if it is available for that video). For example, http://channel9.msdn.com/Shows/Azure-Friday/Scott-Guthries-explains-SQL-Databases-in-Azure /captions?f=webvtt&l=en will get you the captions file for the Azure Friday discussion on  SQL Databases . A typical WebVTT caption file looks this - When the time codes (representing the time within the video when the words are spoken) are present within the text file it is a little distracting to read the content. You can get rid of the timestamps using an editor that supports finding & replacing text using regular expressions. Use the expression  \d{2}:\d{2}:\d{2}\.\d{3}(\s)+...