This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
# Create display override file to force Mac OS X to use RGB mode for Display | |
# see http://embdev.net/topic/284710 | |
require 'base64' | |
data=`ioreg -l -d0 -w 0 -r -c AppleDisplay` | |
edids=data.scan(/IODisplayEDID.*?<([a-z0-9]+)>/i).flatten | |
vendorids=data.scan(/DisplayVendorID.*?([0-9]+)/i).flatten |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin | |
## Usage (after configuration): | |
## 1. Insert camera's memory card into a USB port on your unRAID system | |
## 2. The system will automatically move (or copy) any images/videos from the memory card to the array | |
## If jhead was installed, it will automatically rotate images according to the exif data | |
## 3. Wait for the imperial theme to play, then remove the memory card | |
## Preparation: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# easily "docker exec" into a running Docker container | |
# latest version: https://gist.github.com/ljm42/2b3bfd8ff886015bbce8 | |
# for unRAID, place this script on your flash drive as /boot/custom/docker-shell | |
# then add this to your go script (without the leading pound sign): | |
# cp /boot/custom/docker-shell /usr/local/bin | |
CONTAINERS=`docker ps | awk 'NR==1 {offset=index($0,"NAMES")};NR>1{print substr($0,offset)}' | sort -f | tr "\n" " "` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Copyright 2017, ljm42 | |
# | |
# This program is free software; you can redistribute it and/or | |
# modify it under the terms of the GNU General Public License version 2, | |
# as published by the Free Software Foundation. | |
# | |
# The above copyright notice and this permission notice shall be included in | |
# all copies or substantial portions of the Software. | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/php | |
<?PHP | |
error_reporting(E_STRICT | E_ALL); | |
ini_set('display_errors', '1'); | |
/* | |
bleeding_edge_toolkit Copyright 2018-2023, ljm42 | |
This program is free software; you can redistribute it and/or | |
modify it under the terms of the GNU General Public License version 2, | |
as published by the Free Software Foundation. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** @noinspection ? */ | |
// PhpUndefinedGotoLabelInspection Undefined goto label | |
// PhpUndefinedVariableInspection Undefined variable | |
// PhpUndefinedMethodInspection Undefined method | |
// PhpUndefinedNamespaceInspection Undefined namespace | |
// PhpUndefinedClassInspection Undefined class | |
// PhpUndefinedFunctionInspection Undefined function |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# copy custom rsyslog filter configurations | |
# latest version: https://gist.github.com/ljm42/f6d7d8f22d2965909f69c03df53529f6 | |
# | |
# setup: | |
# 1. create the /boot/config/custom/rsyslog.d/ folder on your flash drive | |
# 2. place this script in that folder, name it rsyslog_copy | |
# 3. add this line to the top of your go script (before starting emhttp): | |
# bash /boot/config/custom/rsyslog.d/rsyslog_copy | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# restart nginx if ttyd is down | |
# add to Unraid User Scripts plugin as script named "check_ttyd" | |
# run every 5 minutes: */5 * * * * | |
# latest version: https://gist.github.com/ljm42/294968bcecb5308bbcd1c75ae693c680 | |
PROG="check_ttyd user script" | |
EVENT="Unraid Server Notice" | |
DESC="Notification from ${PROG}" | |
TMP=/tmp/check_ttyd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Version 1.4 | |
# Latest version of this script: https://gist.github.com/ljm42/a49268b325df3a2e78d5bafec10b5be7 | |
# | |
# This script will automatically mount any 9p mount tags that exist | |
# Designed to be run on Unraid through the User Scripts plugin | |
# | |
# 9p docs: | |
# https://wiki.qemu.org/Documentation/9psetup |
OlderNewer