Skip to content

Instantly share code, notes, and snippets.

Avatar

Richard nyuszika7h

View GitHub Profile
View entire_bee_movie_script
According to all known laws of aviation, there is no way a bee should be able to fly. Its wings are too small to get its fat little body off the ground. The bee, of course, flies anyway because bees don't care what humans think is impossible. Yellow, black. Yellow, black. Yellow, black. Yellow, black. Ooh, black and yellow! Let's shake it up a little. Barry! Breakfast is ready! Ooming! Hang on a second. Hello? - Barry? - Adam? - Oan you believe this is happening? - I can't. I'll pick you up. Looking sharp. Use the stairs. Your father paid good money for those. Sorry. I'm excited. Here's the graduate. We're very proud of you, son. A perfect report card, all B's. Very proud. Ma! I got a thing going here. - You got lint on your fuzz. - Ow! That's me! - Wave to us! We'll be in row 118,000. - Bye! Barry, I told you, stop flying in the house! - Hey, Adam. - Hey, Barry. - Is that fuzz gel? - A little. Special day, graduation. Never thought I'd make it. Three days grade school, three days high school. Those were awkw
View snippets.sh
# updating snippets
# snippetek frissítése
update_snippets() {
file=$(curl -fsSL https://raw.githubusercontent.com/nyuszika7h/snippets/master/update_snippets.sh | bash -s - --selfupdate | tee >&2 | tail -1 | cut -d' ' -f2)
source "$file"
}
update_snippets
@nyuszika7h
nyuszika7h / mktor_functions.sh
Last active Sep 14, 2019
bash/zsh functions for easy torrent creation on private trackers
View mktor_functions.sh
TORRENT_WATCH_DIR="$HOME/rtorrent/watch/load"
ANNOUNCE_BTN='http://landof.tv/YOUR_PASSKEY/announce'
ANNOUNCE_PTP='http://please.passthepopcorn.me:2710/YOUR_PASSKEY/announce'
ANNOUNCE_HDB='http://tracker.hdbits.org/announce.php?passkey=YOUR_PASSKEY'
mkt() {
tracker="$1"
announce=$(eval printf -- "'%s'" "\$ANNOUNCE_$tracker")
if [[ -z "$announce" ]]; then
printf 'Error: $ANNOUNCE_%s is not set\n' "$tracker" >&2
@nyuszika7h
nyuszika7h / sign_theplatform.py
Last active May 29, 2019
Sign theplatform.com URLs using the key and secret
View sign_theplatform.py
#!/usr/bin/env python3
import hashlib
import hmac
import time
from urllib.parse import parse_qs, urlencode, urlparse, urlunparse
def build_qs(qs):
"""Build a query string from a dict"""
View get_moov_pssh.py
import base64
import uuid
from pymp4.parser import Box
def get_moov_pssh(fd):
while True:
x = Box.parse_stream(fd)
if x.type == b'moov':
View musortv.py
#!/usr/bin/env python3
import argparse
import json
from datetime import datetime
import bs4
import pytz
import requests
import tzlocal
@nyuszika7h
nyuszika7h / AutoResize.avsi
Last active Feb 16, 2021
AutoResize function for AviSynth - intelligent resize to 1080p, 720p, SD (720px wide) or any custom resolution
View AutoResize.avsi
### Changelog ###
# - Moved rounding function as standalone function (RoundHalfToEven.avsi). Don't use mod2 when calculating the height of yv24/yv16.
# - Round to the nearest even when the fraction is 0.5. Mode is changed to integer when mode "sd" is not used.
# - Added Crop() for cropping values >(-)1.
# - Added left, top, right, bottom, fill_margins parameters.
# - Added dither_type parameter.
### AutoResize function for AviSynth - intelligent resize to 1080p, 720p, SD (720px wide) or any custom resolution
@nyuszika7h
nyuszika7h / silencedetect.py
Last active Sep 14, 2019
FFmpeg silence detect wrapper - prints human-readable timecodes
View silencedetect.py
#!/usr/bin/env python3.7
import argparse
import re
import subprocess
import sys
def format_time(s):
(h, s) = divmod(s, 3600)
@nyuszika7h
nyuszika7h / chapteredit.py
Last active Sep 14, 2019
Chapter Editor
View chapteredit.py
#!/usr/bin/env python3.7
import argparse
import re
import sys
from collections import defaultdict
# https://stackoverflow.com/a/9028031/492203
class CustomAction(argparse.Action):
View bitrate-calc.py
#!/usr/bin/env python3.7
import argparse
import os
import subprocess
import sys
from fnmatch import fnmatch
cached_mediainfo = {}