Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
: "${SHOW:="${PWD##*/}"}"
: "${GROUP:=Group}"
shopt -s nullglob
# set color variables
#
#black="$(tput setaf 0)"
@reedrw
reedrw / hardsub.sh
Last active July 1, 2018 09:53 — forked from ctrlcctrlv/hardsub.sh
Convert softsubbed MKV files into hardsubbed MP4 files for playback via Roku, low powered devices etc, keep all fonts intact.
#!/bin/sh
# HARDSUB.SH
# (c) 2014 Fredrick Brennan
#
# Usage notes:
# This script requires that ~/.fonts is in your fontconfig path.
# This script also requires mkvmerge, realpath and ffmpeg to be installed. Only supports SSA subs and MKV files.
# Also note that this script can take a long time to run.
# Run as `hardsub.sh FILE_NAME`
# You should be able to delete the following created files after it is done: done_subtitles.ass and the entire contents of ~/.fonts/MKV
@reedrw
reedrw / mirror.sh
Last active October 30, 2017 17:48
#!/bin/bash
DEST='/var/www/html/archlinux'
MIRROR='rsync://mirrors.kernel.org/archlinux'
REPO='community community-staging community-testing core extra gnome-unstable iso kde-unstable multilib multilib-staging multilib-testing other pool sources testing'
function mirrorsync(){
touch lockfile
_ __
| |/ /________ _________ __ _______________ _____
| // ___/ _ \/ ___/ __ \/ / / / ___/ ___/ _ \/ ___/
_ / |/ / / __(__ ) /_/ / /_/ / / / /__/ __(__ )
(_)_/|_/_/ \___/____/\____/\__,_/_/ \___/\___/____/
! special
*.foreground: #ffffff
*.background: #192024