Skip to content

Latest commit

 

History

History
37 lines (23 loc) · 743 Bytes

README.rst

File metadata and controls

37 lines (23 loc) · 743 Bytes

PyLRC

A python library for parsing and converting .lrc files

Usage

import pylrc

lrc_file = open('example.lrc')
lrc_string = ''.join(lrc_file.readlines())
lrc_file.close()

subs = pylrc.parse(lrc_string)
for sub in subs:
    sub.shift(minutes=1, seconds=13, milliseconds=325) # offset by 01:13.325

srt = subs.toSRT() # convert lrc to srt string

lrc_string = subs.toLRC() # convert to lrc string

Installation

sudo pip install pylrc