A convenient Subflow to retrieve device informations from your unifi controller using node-red-contrib-unifi-os nodes with some humble error handling.
#!/usr/bin/env ruby | |
class NeterDbAuthorization | |
def initialize(config_file = 'config.yml') | |
# load config | |
require 'yaml' | |
@cfg = YAML.load_file(config_file) | |
# load logger | |
if @cfg['log']['file'] | |
require 'logger' |
port: 1818 | |
commands: | |
# Join Push Text : Command to run | |
"eg=:=shutdown": "systemctl poweroff" | |
#fallback-cmd: "./fallbacktest.sh" |
http://rootzwiki.com/topic/41985-enable-wifi-tether-through-adb/ | |
adb shell input keyevent 3 # home | |
adb shell am start -a android.intent.action.MAIN -n com.android.settings/.Settings | |
adb shell input keyevent 20 # down | |
adb shell input keyevent 20 # down |
#!/bin/bash | |
PI_IP="xxx.xxx.xxx.xxx" | |
LEFT_OF="VGA1" #"LVDS1" | |
CLIENT_SCRIPT_NAME="x11-client.sh" | |
LOCKFILE="/tmp/x11-extended-display-lock.pid" | |
screen_res='python -c "import Tkinter; r = Tkinter.Tk(); print r.winfo_screenwidth(), r.winfo_screenheight(); r.destroy();"' | |
d=`ssh pi@$PI_IP "export DISPLAY=:0 && $screen_res"` | |
case $1 in |
#!/bin/sh | |
docker events --filter 'event=start' --filter 'event=stop' | while read event | |
do | |
container_id=`echo $event | sed 's/.*Z\ \(.*\):\ .*/\1/'` | |
echo $container_id |
So I have been using tmux for a while and have grown to like it and have since added many many customizations to it. Now once you start getting the hang of it, you'll naturally want to do more with the tool.
Now tmux has a concept of window-group
and session
and if you are like me you'll want multiple session that connects to the same window group instead of a new window group every time. Basically I just need different views into the same set of windows that I have already created, I don't want to create a new set of windows every time I fire up my terminal.
This is the default case if you simply use the tmux
command as your login shell, effectively creating a new group of windows every time you start tmux
.
This is less than ideal because, if you are like me, you fire up one-off terminals all the time and you don't want all those one-off jobs to stay running in the background. Plus sometimes you need information fro
machine github.com | |
login technoweenie | |
password SECRET | |
machine api.github.com | |
login technoweenie | |
password SECRET |
This guide is written for all owners of a Behringer X32 or Midas M32 with a X-USB 32x32 channel expansion card. It is directed towards splitting the X-USB channels up in virtual outputs on Ubuntu 18.04 with PulseAudio. The guide may also work for other versions or distro's of Linux with PulseAudio.
It is assumed that the X-USB is installed and connected to a computer. And automatically recognized as a multi-channel soundcard by the operating system. Also note that on Ubuntu 18.04, PulseAudio runs on top of ALSA. ALSA picks up the soundcard and PulseAudio then uses the full soundcard through ALSA to create virtual channels.
Table of contents
//http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript | |
Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15); |