Skip to content

Instantly share code, notes, and snippets.

View bhadreshvk's full-sized avatar
🐾

teddybhadru bhadreshvk

🐾
View GitHub Profile
@shussekaido
shussekaido / Remove timecodes from SRT
Created September 30, 2013 16:10
Creates plain text from SRT files by removing timecodes
To simply remove timecodes (this is a long command that should be on one line):
cat episode01.srt
|cat "$@"|tr -d '\r'
|grep -v '^[0-9]*$'
|grep -v '^[0-9][0-9]:[0-9][0-9]:[0-9][0-9],[0-9][0-9][0-9] --> [0-9]'
> episode01.txt
To remove timecodes and linebreaks: