Skip to content

Instantly share code, notes, and snippets.

Avatar

Malcolm Diller mdiller

View GitHub Profile
@mdiller
mdiller / update_botdata.py
Created Jun 10, 2017
updates the botdata.json file to the new format
View update_botdata.py
import json
from collections import OrderedDict
userinfo_defaults = OrderedDict([
("steam32", None),
("intro", ""),
("outro", "")
])
@mdiller
mdiller / mp3ytclipper.py
Created Feb 9, 2017
Python script for downloading the audio of a Youtube video, clipping a certain section of it, adding a slight fade in and out, and saving the clip to a file.
View mp3ytclipper.py
#!/usr/bin/python3.5
#example usage: mp3ytclipper.py "https://www.youtube.com/watch?v=MgxK5vm6lvk" later 44.3 46.3
import sys, re, subprocess, youtube_dl, os
if len(sys.argv) != 5:
print("usage: mp3ytclipper.py <youtubeurl> <outfilename> <starttime> <endtime>")
exit()
You can’t perform that action at this time.