Skip to content

Instantly share code, notes, and snippets.

View nlowe's full-sized avatar
Working from home

Nathan Lowe nlowe

Working from home
View GitHub Profile
var timer=100;document.querySelectorAll("div > input[type='checkbox']:checked").forEach((interest) => {setTimeout(function(){},timer);timer+=2000;});
smoser /
Last active July 19, 2024 20:55
qemu to linux mapping of smbios / dmi information

Mappings for DMI/SMBIOS to Linux and dmidecode

Information can be put into dmi tables via some qemu-system hosts (x86_64 and aarch64). That information is exposed in Linux under /sys/class/dmi/id and can be read with dmidecode. The names are very annoyingly inconsistent. The point of this doc is to map them.


Example qemu cmdline:

qemu-system-x86_64 -smbios type=<type>,field=value[,...]

qemu-system-x86_64 -smbios type=0,vendor=superco,version=1.2.3
anonymous /
Created May 11, 2017 15:35
Quick and simple shell script for updating lib32-qt4 in Arch Linux.
# Based on the directions here:
# This will take a while to build, with most of the time spent on QT4. There is some redundancy with creating
# multiple clean chroots, but I think this approach is easier and more reliable for most systems.
# Specify a build directory. Defaults to /tmp:
# Install devtools if it's not already installed:
using System.Collections.Concurrent;
using System.Reflection;
using System.Threading;
using System.Xml.Linq;
public void RunSimultaneously(params Action[] actions)
if (actions.Length == 0) return;
encodeering / .travis.yml
Created December 31, 2015 14:50
Travis configuration to be capable of running the docker command inside a docker container by a host-share; you need to bind libapparmor due: /usr/bin/docker: error while loading shared libraries: cannot open shared object file: No such file or directory
sudo: required
# any language should do it
language: bash
- docker
# libapparmor1 should be already installed due a running service, but just in case
NickCraver / Windows10-Setup.ps1
Last active July 22, 2024 01:50
(In Progress) PowerShell Script I use to customize my machines in the same way for privacy, search, UI, etc.
# Privacy Settings
# Privacy: Let apps use my advertising ID: Disable
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 0
# To Restore:
#Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 1
# Privacy: SmartScreen Filter for Store Apps: Disable
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AppHost -Name EnableWebContentEvaluation -Type DWord -Value 0
andik / gist:57a317a0545132ab7125
Created February 23, 2015 12:44
Creating a Child Process with Redirected Input and Output in Windows
The example in this topic demonstrates how to create a child process using the CreateProcess function from a console process. It also demonstrates a technique for using anonymous pipes to redirect the child process's standard input and output handles. Note that named pipes can also be used to redirect process I/O.
The CreatePipe function uses the SECURITY_ATTRIBUTES structure to create inheritable handles to the read and write ends of two pipes. The read end of one pipe serves as standard input for the child process, and the write end of the other pipe is the standard output for the child process. These pipe handles are specified in the STARTUPINFO structure, which makes them the standard handles inherited by the child process.
The parent process uses the opposite ends of these two pipes to write to the child process's input and read from the child process's output. As specified in the STARTUPINFO structure, these handles are also inheritable. However, these handles must not be inherited. Therefore, befo
junefrench /
Last active February 23, 2016 13:04
Generate X32 Snippets for Musical Theatre
Instructions for use
Change channel_count and dca_count as appropriate. (Note that this always assumes that you are using the lowest-numbered channels and dcas for cue control)
Change channels to the list of names of channels you want under cue control.
Change cues to your list of cues, following the examples. the comment in cues documents the syntax.