Skip to content

Instantly share code, notes, and snippets.

@sophana
sophana / lrc2srt.py
Last active April 17, 2022 19:41
Convert all lrc files to srt. With SRT files, you can display lyrics in most media players.
#!/usr/bin/python
import sys
import os
#usage: lrc2srt.py [directory]
# will recusively convert all lrc files to srt in directory
def conv(lrcPath,srtPath):
lrc=file(lrcPath)
@sophana
sophana / sample_dominate.py
Last active September 12, 2018 06:52
sample single file templateless flask application that demonstrates flask_bootstrap, flask_wtform, flask_nav, flask_login, and dominate
'''
sample single file templateless flask application that demonstrates flask_bootstrap, flask_wtform, flask_nav, flask_login
uses dominate instead of templates
to use: (in virtual env)
pip install dominate Flask Flask-Bootstrap Flask-WTF flask-nav Flask-Login
python sample_dominate.py
'''