Skip to content

Instantly share code, notes, and snippets.

@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active April 26, 2024 14:31
Complete Recent Discord Quest

Complete Recent Discord Quest

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
  2. Join a vc
  3. Stream any window (can be notepad or something)
  4. Press Ctrl+Shift+I to open DevTools
  5. Go to the Console tab
  6. Paste the following code and hit enter:
let wpRequire;
@alexanderson1993
alexanderson1993 / createR2UploadHandler.ts
Created April 5, 2024 15:22
A Remix upload handler for R2 buckets
import type { UploadHandlerPart } from "@remix-run/cloudflare";
export class MaxPartSizeExceededError extends Error {
constructor(public field: string, public maxBytes: number) {
super(`Field "${field}" exceeded upload size of ${maxBytes} bytes.`);
}
}
export function createR2UploadHandler({
bucket,
@Dih5
Dih5 / compile.sh
Created December 5, 2017 15:01
Compile with lualatex + biber
#!/bin/bash
OUTDIR=/tmp/ramdisk
FILENAME=foobar
OPTIONS="--synctex=1 -interaction=nonstopmode"
mkdir -p $OUTDIR
lualatex $OPTIONS --output-directory=$OUTDIR $FILENAME.tex
@smx-smx
smx-smx / XZ Backdoor Analysis
Last active April 26, 2024 14:30
[WIP] XZ Backdoor Analysis and symbol mapping
XZ Backdoor symbol deobfuscation. Updated as i make progress
@jantimon
jantimon / gist:f764e179baeee7c98b8bb6035fb2964a
Last active April 26, 2024 14:30
install stable diffusion v1 on Apple M1
brew update
brew install Cmake protobuf rust python
git clone https://github.com/bfirsh/stable-diffusion.git
git checkout apple-silicon-mps-support
mkdir -p models/ldm/stable-diffusion-v1/
# accept license and download the model
# sd-v1-4.ckpt from:
# https://huggingface.co/CompVis/stable-diffusion-v-1-4-original