Skip to content

Instantly share code, notes, and snippets.

View mcd1992's full-sized avatar

Aaron mcd1992

View GitHub Profile
@Diyagi
Diyagi / stereoMic.ts
Created July 15, 2024 18:57
Vencord Stereo Mic
import definePlugin, { OptionType } from "@utils/types";
import { definePluginSettings } from "@api/Settings";
const settings = definePluginSettings({
voiceBitrate: {
type: OptionType.SLIDER,
description: "Voice Bitrate",
markers: [8, 64, 256, 384, 512],
default: 512,
stickToMarkers: false,
@cheahjs
cheahjs / README.md
Last active January 16, 2025 00:15
Converting PalWorld saves to JSON and back
@digitalsignalperson
digitalsignalperson / stream.sh
Last active April 24, 2025 05:26
xdp screen cast example, modified to pipe to ffmpeg
mkfifo /tmp/gfifo
./xdp-screen-cast-ffmpeg.py & # or run in another terminal
# Note the gstreamer pipeline
# 'pipewiresrc fd=%d path=%u ! videorate ! video/x-raw,framerate=60/1 ! videoconvert ! filesink location=/tmp/gfifo'
# I specified a 60/1 frameerate. You can do other pre-processing here, or offload it to ffmpeg.
# Encode the stream and pipe to netcat
# note: must specify correct resolution here
# we can now use h264_nvenc, mpegts, and anything else ffmpeg has
@subrezon
subrezon / openwrt-on-proxmox.md
Last active April 24, 2025 04:12
How to set up an OpenWRT VM in Proxmox
  1. Go to OpenWRT release page, select the latest release stable release, then targets -> x86 -> 64. Right-click generic-ext4-combined.img.gz (not the "efi"!) and copy the link.

  2. On the Proxmox host, download the archive and unpack it:

wget *paste link here*
gunzip openwrt-*.img.gz
  1. Resize the image to be the size you want your VM's disk to be (example with 8 GiB):
@catboxanon
catboxanon / README.md
Last active April 14, 2025 19:36
/hdg/ catbox.moe userscript

/hdg/ catbox.moe userscript

This userscript adds functionality to upload to Catbox directly from 4chan, and to view metadata for Stable Diffusion, TavernAI, and NovelAI, in PNGs, JPEGs, WebPs, and AVIFs.

For text-only posts, this also attaches the first Catbox link found, if any, to the post as a normal image.

If you are only looking for reading metadata without a userscript, you can try the (WIP) webpage below.

https://catboxanon.github.io/ai-metadata/

# Script for converting a HF Diffusers saved pipeline to a Stable Diffusion checkpoint.
# *Only* converts the UNet, VAE, and Text Encoder.
# Does not convert optimizer state or any other thing.
# Written by jachiam
import argparse
import os.path as osp
import torch
@alexander-hanel
alexander-hanel / bn-cheat.md
Last active April 11, 2025 13:28
Cheat Sheet for Binary Ninja
@kkrypt0nn
kkrypt0nn / ansi-colors-discord.md
Last active April 16, 2025 07:57
A guide to ANSI on Discord

A guide to ANSI on Discord

Discord is now slowly rolling out the ability to send colored messages within code blocks. It uses the ANSI color codes, so if you've tried to print colored text in your terminal or console with Python or other languages then it will be easy for you.

Quick Explanation

To be able to send a colored text, you need to use the ansi language for your code block and provide a prefix of this format before writing your text:

\u001b[{format};{color}m
@feldim2425
feldim2425 / steamvr_dev.md
Created July 23, 2021 19:46
How to debug SteamVR Drivers on Linux

SteamVR Driver Dev (Linux)

Installing your driver

To install your driver on Linux you have to drop it into $STEAM_HOME/steamapps/common/SteamVR/drivers where STEAM_HOME depends on your Steam settings and distro. Usually it is located at ~/.steam or ~/.local/share/Steam. However it can also be located on an external drive depending on where SteamVR is installed.

The in the drivers folder you have to drop a folder named after your module. This folder has to contain the following structure:

driver/
 ├─ example/
 │ ├─ bin /
@w4rum
w4rum / barotrauma-reactor-guide.md
Last active April 20, 2025 21:07
In-depth Reactor Guide and Fission Controller (last updated for 0.13.3.11)

In-depth Reactor Guide and Fission Controller (last updated for 0.13.3.11)

This guide first explains some advanced features of the Barotrauma reactor system and then combines a PD controller with some reverse engineering of Barotrauma's source code to build a working fission controller. This guide does not build a turbine controller. Please see Rob Smith's video for a really great turbine controller that works well with this fission controller.

Quick Start

If you don't care about the details, just copy the following setup to your submarine. The wiring should be pretty self-explanatory from the layout, with the wires always going from the left to the right.

Component list (thanks to @FinetalPies):

  • 4 WiFi
  • 6 Memory