Skip to content

Instantly share code, notes, and snippets.

View mbirth's full-sized avatar
:shipit:
Hiding in the shadows…

Markus Birth mbirth

:shipit:
Hiding in the shadows…
  • London, UK
View GitHub Profile
@mbirth
mbirth / tt2srt.py
Last active May 6, 2019 19:30 — forked from adammw/tt2srt.py
Timed Text Captions to SRT Subtitles converter script
#!/usr/bin/env python
# Usage: python tt2srt.py source.xml output.srt
# FROM: https://gist.github.com/adammw/915259
from xml.dom.minidom import parse
import sys
def fixTime(time):
# 00:00:00.000
return time.replace(".", ",")
#!/bin/bash
#Inspired by http://blog.neutrino.es/2012/git-copy-a-file-or-directory-from-another-repository-preserving-history/
#Copy a file or directory out of a git repository, preserving history!
#Creates DESTINATIONPATH with patches that can be applied with git am
#e.g.
#0001-Add-new-theme-Gum.patch
#0002-Add-syntax-highlighting-for-Gum-theme.patch
#0003-Gum-Fix-tag-URLs-not-being-slugified-and-therefore-b.patch
#0004-Gum-Add-Disqus-support.patch
#0005-Gum-Use-article-title-as-the-title-of-the-generated-.patch