srt generation from csv file

author
0 minutes, 13 seconds Read
#!usr/bin/env bash
        
file=$1

i=1;

while IFS='@' read -r startTime endTime text; do
    echo "\n$i"
    startTimeF=$(echo $startTime | sed 's/./,/9')
    endTimeF=$(echo $endTime | sed 's/./,/9')
    echo "$startTimeF --> $endTimeF"
    echo $text\n\n 
    i=$((i+1))
done <$file 

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *