Skip to content

Instantly share code, notes, and snippets.

View redfellow's full-sized avatar

redfellow redfellow

View GitHub Profile
/* FOR RAMBOX, edit service and paste under "Advanced / Custom code" */
function applycss(css){
var head = document.getElementsByTagName('head')[0];
var s = document.createElement('style');
s.setAttribute('type', 'text/css');
s.appendChild(document.createTextNode(css));
head.appendChild(s);
}
applycss(`
@redfellow
redfellow / plex-donaus.js
Created May 11, 2018 20:22
Download the original audio/video from a Plex server you have access to
javascript:(function()%7Bif (typeof plxDwnld %3D%3D 'undefined') %7Bvar jsCode %3D document.createElement('script')%3BjsCode.setAttribute('src'%2C 'https%3A%2F%2Fpiplong.run%2Fplxdwnld%2Fbookmarklet.js%3Fts%3D' %2B Math.floor(Date.now()%2F1000))%3Bdocument.body.appendChild(jsCode)%3B%7D else %7BplxDwnld.init()%3B%7D%7D)()
@redfellow
redfellow / transmission.bat
Last active June 25, 2018 00:18
Windows 10: Bind and start transmission-daemon on specific NIC
@echo off
set IP=""
for /f "tokens=2 delims==" %%F in ('wmic nic where "NetConnectionStatus=2 and AdapterTypeId=0" get NetConnectionID /format:list') do set interfaceName=%%F
if "%interfaceName%"=="PIA VPN" (
for /f "tokens=1-6 delims=:. " %%a in ('netsh int ip show address "PIA VPN" ^|find "IP Address"') do set IP=%%c.%%d.%%e.%%f
if defined IP (
echo VPN IP check OK: %IP% -- Starting transmission
"C:\Program Files\Transmission\transmission-daemon.exe" --foreground --config-dir J:\apps\transmission --bind-address-ipv4 %IP%
@redfellow
redfellow / discord.css
Last active February 22, 2018 22:34
Smaller server, channel & user panels for Discord desktop client (requires BetterDiscord CSS injection)
.guilds-wrapper + div > div:last-child > div:first-child {
width: 208px !important;
}
.channel-members-wrap {
min-width: 160px !important;
width: 120px !important;
}
.channel-members-wrap h2 {
@redfellow
redfellow / handbrake.ps1
Last active December 17, 2023 22:38
Powershell script to batch-encode recursively, using a custom handbrake preset
$filelist = Get-ChildItem "F:\path\to\vids\" -filter *.avi -recurse
$num = $filelist | measure
$filecount = $num.count
$i = 0;
ForEach ($file in $filelist)
{
$i++;
$oldfile = $file.DirectoryName + "\" + $file.BaseName + $file.Extension;
dyeNhaqikkArcbxIcugLqQtjumlK0TevYUev8lHqdJICmQOLjQ6zubttj6AcjBdj8neQXHaNdHyDuG07OOAEIk19uchKcyHuu6HuqtuHQlsH2OqPpIq6KirRubZKk0nLK0ofQ(PKudviAPkuEQQMksDvfITkjXyPavNLce7f1FLObtomIwScPhlHjlkxwLnlP(mvYOrqNwKztvUnv1Uf8Bk1WPsTCf9Ckz6sDDLA7kP(offmELKZljwpffA)WStMMFF(Z4pJP5V2o0FYmECChYZFHTN9KP54554MYXjfMiMGLo40bIZh1sIWXDGJLyI4mFEtuS00sNuSKILM46CfvuCZFwYYThzf6BvZ)GrJvX4dnsKMjuSuAWHmivpYyqusBSQVzY)o0ZKlx3KP5VyB12(8xVdfDYoeDmqE2fKEqjQf7jvFYvMJbiiiOA7juAHtQojakZgdqqqqqqqqf7jvFYvli61ugwFH2EwHY(8hFpjhn5L6krNIXCmabbbbbbbLQHk2tiYqgKp5kOMWlGbiiiiiiiiiiiOunu0f7ze9jxfduUxazkhcGAcVagGGGGGGGGGGGGGGGGMxVNbOAspRZCmabbbbbbbbbbbDHmmabbbbbbbDHmmabbbDHmmabbbnVEpdq9CFMJHlKXn)ZZvYoqxX9XFFRA(tHuxwy77276lJJ7K)EMC56Mmn)Df3h)fBR22N)S9KSt2b(DWe)fBR22VKWu2XFX2QT95VyB12(8xVdfDYoe9T(cnvOsQq(NLfPRJkujvOsQqLuHkPcvsfQKkujvOsQqLuHSCFEEuooumyaccckvdDRVqdTybuemS6QAwdqx6y1eT0yvmgNUCK4XsPJ0ghZ44raImKb5FwwKUoOflGIWhPrhDS0qd80L)igAOX)JaezidYY955r54qlwarbXeKNcOMWlGbiiiiiiiip7cspOe1I9KQp5kZXaeeeeeeeuT9ekTWjvNeaLzJbiiiiiiiiiiiOI9KQp5Qfe9AkdRVqBpRqzF(JVNKJM8s
dmfg1cGiLuIUeju1NiHkAukP4ukjAvkPu9kLGWSGGQBPuPDjbPFPeezysOJPuwgP4zqPPPeDns02Oc(geACkP6CqrRtji17iHkO5PKs6EqqSpLukoijKfsk9qjQMieuUOeLnQe6JkPuAKsqDsOGvQKWljHkntLa3ecs7ur)uPQHQK0rvcIYsvQ4PGPkPRcb2kjuH(Qsq1yvckoRsqYAjHkWCLGyVO)QqdwkDyrTyQqpgQMmP6Yu2Sc(mKgneDAvTALucVgk0SfCBsA3I8BHgov64kbLwov9CvMoX1LQTtc(Uez8sGZtfTEsOmFLGOA)sXCJvczwPq4iOPq3k0IfQghiOsqNGoReky)WWzcN7Qbrco3pmCMW5UByvsWkWnN0nDQLWzHHvJFsiODFTUhHUGYwSs41ju4Esm)cDtlcn7X4PMthY3TPTWiaHriRR)Yht5WO4FuuZFSsHqQRw9pkQ5po3ieIzDwjO)ddpEpiozLGApipRuOqWNXnwjO2dYZkfkegY4YhtSsqThKNvkuii5GLewjO2dYZkfke8XGXkb1EqEwPqHcbVH(Xu1PRra1h7UuiGZkNBSsONe)JIAEwjCUwimZQgNylUujfcI)rrnpReeNUgHtYs)iG3pjQoI81ncYRA6e6jtbljeYDjsOF24HmwAFIAjykyjHq5Xyqpwk10UQpI6T7AAxd4AHWkj0pB8CTqyMvnQLq)SXE6fQLWHmwAFIWHmwAFQ8ymOhlLiCUwimZQgNylUujfc62LLUplg1saP9OifoXQKqiM1zLGKdwsyLGApipRuOqapKVJvc3NqdgHcJGzTSDOqOF2iEiFh1sWhdgReu7b5zLcfc9ZgpxdNAjmKXLpMyLGApipRuOqWNXnwjO2dYZkfke0)HHhVheNSsqThKNvkuiCUgoReUpHgmo1qHcbVH(Xu1PRr4XJjcF6Lr8OQBWetNZnc4XyqpwkrTeY66V8Xuomk(hf18hRui86e2j7(6l(ERCegHsVUGKtSkjGhdrpRCUKlQCz
@redfellow
redfellow / jquery.jplayer.draggablevolume.js
Last active June 20, 2017 18:46
This lets the user drag the jPlayer volume bar instead of just clicking a new volume value. Substitute #player and .jp-volume-bar-value with your own selectors. If you are using a horizontal volume bar, you'll have to hack in negative values instead.
$('.jp-volume-bar').mousedown(function() {
var parentOffset = $(this).offset(),
width = $(this).width();
$(window).mousemove(function(e) {
var x = e.pageX - parentOffset.left,
volume = x/width
var barValue = Math.floor(volume*100);
if (barValue < 0 ) barValue = 0;
if (barValue > 100) barValue = 100;
jQuery(".jp-volume-bar-value").css("width", barValue + "%");
d8eZzaqivPuweOcJcvCkuPvriELQknlHQBriTlrLFbkudJahteldKEMQunnqPRPQQTju6BIQACQQ4CQs07uLs19avDqcvlKq5HGk1evLIlcPSrHIpQkPgjKk1jHuXkfLxksHMjb1njiTtf8tqrdvuLJQkbzPQsYtbMQQ4QQsGTksrFfuWybvYzbv0Cbfs7f5VqYGLomrlMG4XqzYQkxwPndv9zfA0qLtdXQfPGxdkeZMKBdIDROFly4cz5O8CsnDvUoQA7qQ67IuA8IuDErY6vLs2p1dxLqtksLmHvjOMsOhciPh6iGMaqZLKtqU8jaec8rGp6HaPdt8417rdcYjqGGeOqfKVG3tG(NaPGjE869OyenwOqZp23Hnb6pj))jFOci8IclSeqVk85fqMhbedMppWuOcJwmpeGTJiH5tQOLaJSaFebM8qEyiJJlttdjea5JaO7yGBxrDfAQdhcMBAerXcJJUWGKnrMJAcOcYp6Ha86ffMsQ1KqialOw6Haq4vhc9qhDe4dbpEemE1LIEiaeE1Hqp0rhboPANh9qai8QdHEOJocWKyl9qai8QdHEOJo6iWMEKC(TFKy0ram6HgsOhcGpmpaYBT0auyjWhIosjt9SPFeinf)vW0nVxbZm0G7h0ry0Ye)TraKjYHclajsT3(rdjeGTJiH5tQOLa3M(rGJHmoUm6HaxQOLay86laHaF8m5HeMeiHal635PjaCdtHkM4pOegMVgfAPjAdpOEbdXGoc)G2Rq7neaJxFbieap)e7qctxol635f3nxUCCDDDDMRRRRkGjvUhcKvFsirXDHSATCCDH3nxUCUUUUUoZ1111zUUUUi4D5az1A546cp8UWbip0ewyuVrCHk(Rrdo46E42PZCDDDDDDDvbmPYfgehfip0ewyuOZBCH3n5hbqH(3zUUUUUUUUQaMu5cdIJcKhAclmQbXfkAUW7chVzLho3hCSWQHdN56666666QcysLRoAvkutjK1fEx9QwSJtY7XDZLlhxxxxxxxxxN56
@redfellow
redfellow / 1: Rotation Helper
Created August 13, 2015 22:21
Death Knight - Unholy Necroticblight (WoW Patch 6.1)
davuviqisIuPwejrCjsIKnPskXOqQofszvuHEfjvZsL6wsjTlPs6xKePmmvIJPkTmPkptQuttvORrszBuj6BQcACsKCoQewNkPu9ovsPmpjsL7Pkk7tIihuvKfkv8qsctuQexuLuTrvs(OePmsvboPQOALsPEPerzMseUPePQDQc)uQQgQuILss6PIMQuCvvsXwjjsL8vvsjnwQiNLkQ5kruTxWFvvnyuhgXILqpMetwfDzkBwc(mHgTQYPrYQjjsfVMKOMTKUTe1Uj63KA4eSCfpxPPlCDQA7uj9DQGXlvLZtLA9KePQ9dn8cnqsGgiGCHSxxV0vx0vxazzipH8eAGuC0oaPQpV0EqdKejvzsyqhi7R)cfwlGRCzpx2Ru96Pwpx(Wh6IUDHlHcT(OlHCmrkTSXTGb5PBjPmLI4O9cq6U)cfwlGJUFeY1QfArtjdilX1VQbsQtiv1oxKpmLrxSsj(fiRQoibLwI8dSQGnq6a1z8bhp2nKsF5MHsu0MfoEHKCEsfuAjP(hdLOOnl0abKFgL4xax5YlQ96Ys5YE9CXJpuTU7vkOqRp(qiRAYj0aPFTFLkzxiJXBqo6Qbnqw2xdkObciGmivtgqdKL91GcAGacihIIbnqw2xdkObciGuPs2fAGCPKIvdYUC9NAEqj745L2dAGaciT(eiYt7e6abKkqdC8cnqQOR6bAGJx4k1EyVE96D5Hx6(Y7RlEFiuOv1Eeo6gUsTh2RxVExE4LUV8(6I3hcfAvThHasVmgkrrBGgi3pTd9lHC)0o0VuvJC6gYvWQ1dszdoE7(Yd72LqajrsvMeuAj0a5gKjGgiJHi3kjSg3cgKBmekXVOziYTscdYt)qckTeYlqsQcFKg3cgKBmekXVasfDvpDGJlqQOR6P0GJlqsQcFKR8sfirgzKrESWpsKl4LkbLwsxy0IJT7nYBqM4g5tRgeAyBKrgzKrg5Xc)irEdYeiRoY0fgT4y7ISJiFA1GqdBJmYiJSjpX2iJmKRcPA9bhxG0V2Fme5