Skip to content

Instantly share code, notes, and snippets.

View df-a's full-sized avatar
🎯
Focusing

df-a

🎯
Focusing
View GitHub Profile
@df-a
df-a / tinymediamanager-sonarr-radarr-rename-strings.md
Last active October 2, 2021 10:45
TinyMediaManager file- and foldername rename strings

Movies rename strings

TinyMediaManager v3.x

Folders

Folder name:
${movieSet.titleSortable}/${title} (${year})/[${videoFormat}]/${edition}

Files

File name:
${originalTitle} ${- ,edition,} (${year}) [${videoFormat} ${videoCodec} ${audioCodec}]
example: "My Awesome Movie Collection/My Awesome Movie (1999)/[2160p]/My Awesome Movie (1999) [2160p h265 AAC].mkv"

@df-a
df-a / joybell-hevc.md
Created April 18, 2021 21:08
JoyBell HEVC Encoding

A while ago I came across a guide that was for converting content by Joybell. Couldn’t find it again to share but here are the settings I got from it.

Video Codec: H.265 10-bit FPS: Same as Source/Variable Encoder Preset: Fast (Gave smallest file size over Slow) Avg Bitrate: 900 2–Pass Encoding

I started with the Apple TV 1080 Preset and edited from there. I feel that it works pretty good without any major quality loss. It’s what I have been converting all my TV Shows to for the better part of a year.

Edit: Checked file sizes as that’s what’s important here. Went from 3.5GB 45 Minute 1080p BluRay source to ~400MB compressed. Numbers are for 155 file average. Used 11 Seasons Doctor Who as an example. All together it was 548GB ripped from BluRay to 65GB compressed.

@df-a
df-a / install.md
Created October 11, 2021 14:42
Get composer to accept external Javascript libraries hosted on packagist

Composer (recommended) If you would like to install the select2 library with composer, you probably used the drupal composer template to set up your project. It's recommended to use asset-packagist to install JavaScript libraries. So you will need to add the following to your composer.json file into the repositories section:

    {
        "type": "composer",
        "url": "https://asset-packagist.org"
    }

It's also needed to extend the 'installer-path' section:

Generate RSA, DSA, EDD keys and subkeys from command line'

amnesia@amnesia:~$ gpg --full-gen-key --expert gpg (GnuPG) 2.2.12; Copyright (C) 2018 Free Software Foundation, Inc. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

Please select what kind of key you want: (1) RSA and RSA (default) (2) DSA and Elgamal

@df-a
df-a / zmv-examples.md
Last active November 2, 2021 01:23 — forked from nightscape/zmv-examples.md
ZMV-Examples (require autoload zmv)

rename a section of a filename, i. e. example.1.{txt,conf,db} or 12345.1.{wav,ogg,mp3} and change the 1 to a 2 in the filename while preserving the rest of it.

  zmv -n '(*.)(<->)(.[^.]#)' '$1$(($2+1))$3' # would rename x.0001.y to x.2.y.
  zmv -n '(*.0#)(<->)(.[^.]#)' '$1$(($2+1))$3'

Rename files to lower case

  $ zmv '*' '${(L)f}'
@df-a
df-a / libtorrent and rtorrent on mac.sh
Last active December 10, 2021 21:24 — forked from pyed/libtorrent and rtorrent on mac.sh
Compiling rtorrent on a mac
#!/bin/bash
# Installs the XCode command line tools if you don't have them
xcode-select --install
# Installs brew if you don't have it
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# Makes your account the owner of /usr/local, which is preferred on single user Macs
sudo chown -R `whoami` /usr/local
# Installs all the dependencies for building libtorrent and rtorrent
brew install automake libtool boost curl lzlib libsigc++ openssl pkg-config xmlrpc-c
# Uninstall libtorrent-rasterbar if you already have it
@df-a
df-a / openssl-macos-install.sh
Created December 19, 2021 11:50
Install OpenSSL on macOS monterrey+
#!/bin/zsh
# choose OpenSSL version to install
# avbailable versions here: https://github.com/openssl/openssl/tags
# you have to copy from the "l" or the "L", they use lowecase and uppercase on the various branches
VERSION="l-3.0.1" # VERSION="L_1_1_1l"
# compiler options:
# darwin-i386 | darwin-i386-cc | darwin-ppc | darwin-ppc-cc | darwin64-arm64 | darwin64-arm64-cc | darwin64-ppc | darwin64-ppc-cc | darwin64-x86_64 | darwin64-x86_64-cc
COMPILER="darwin64-x86_64-cc"
@df-a
df-a / .rtorrent.rc
Created January 6, 2022 23:14 — forked from bryanjswift/.rtorrent.rc
rtorrent configuration file with description
# This is an example resource file for rTorrent. Copy to
# ~/.rtorrent.rc and enable/modify the options as needed. Remember to
# uncomment the options you wish to enable.
# Maximum and minimum number of peers to connect to per torrent.
min_peers = 1
max_peers = 100
# Same as above but for seeding completed torrents (-1 = same as downloading)
@df-a
df-a / .rtorrent.rc
Last active January 6, 2022 23:21 — forked from sasapurin/.rtorrent.rc
rtorrent configuration file with description fix 20190713
# This is an example resource file for rTorrent. Copy to
# ~/.rtorrent.rc and enable/modify the options as needed. Remember to
# uncomment the options you wish to enable.
# Maximum and minimum number of peers to connect to per torrent.
throttle.min_peers.normal = 1
throttle.max_peers.normal.set = 100
# Same as above but for seeding completed torrents (-1 = same as downloading)
throttle.min_peers.seed.set = 1
@df-a
df-a / user.js
Created January 9, 2022 02:02 — forked from brainfucksec/user.js
user.js - brainfucksec
/*********************************************************************
*
* Mozilla Firefox configuration file: `user.js`
*
* date: 2022-01-08
* version: 0.8.2
* maintainer: brainf+ck
*
* info: Set preferences for the selected profile when Firefox start.
* Copy this file on Firefox Profile folder. You should create a