Skip to content

Instantly share code, notes, and snippets.

View trinitronx's full-sized avatar
⛩️
Zazen

James Cuzella trinitronx

⛩️
Zazen
View GitHub Profile
@trinitronx
trinitronx / vimdiff.md
Last active September 7, 2025 20:47 — forked from zertrin/vimdiff.md

vimdiff cheat sheet

vimdiff commands

  • ]c - next difference
  • [c - previous difference
  • Ctrl+w+w - switch windows
  • do - diff obtain
  • dp - diff put
  • zo - open folded text
@aravindanve
aravindanve / bypass-disable-devtool.md
Last active December 4, 2025 11:46
Bypass disable-devtool

(Working as of 2025-02-09)

There are websites that use disable-devtool to prevent you from opening or using devtools. They typically prevent you from right clicking or using the keyboard shortcut to open devtools. Even if you successfully do so, they detect it and redirect you elsewhere. You can bypass this by using one of the following ways.

Opening devtools

If the shortcut F12 on Windows or Option + ⌘ + I on Mac do not work. Press the three vertically aligned dots in the top right corner of your Google Chrome or Microsoft Edge window. Under the section "More Tools", you'll see the option to select "Developer Tools" which opens the toolkit in your window.

@trinitronx
trinitronx / OSX-KVM - Fixing the SSDT-EHCI for working usb-kbd and usb-tablet.md
Last active May 21, 2025 12:08
Diagnosing and fixing mismatched SSDT USB controller PCI addresses in OSX-KVM

Problem

When adding and removing devices to a QEMU VM created from OSX-KVM, I encountered some device problems.

While tinkering and fiddling with adding and removing different QEMU devices to the VM, the order of -device flags passed caused PCI addresses to keep changing. This, in turn caused keyboard and mouse support to stop working for me, until I found out what the problem was.

@trinitronx
trinitronx / install-vagrant-libvirt.sh
Created December 30, 2024 22:38
Workaround script to install vagrant-libvirt + vagrant 2.4.3 on Arch Linux & Arch-based distros
#!/bin/bash
export VAGRANT_DEBUG=1
export VAGRANT_DEBUG_LAUNCHER=1
export VAGRANT_LOG=debug
## Setting above debug options reveals vagrant substrate's default environment:
#2024/12/17 09:02:16 launcher: env "CFLAGS" = "-I/opt/vagrant/embedded/include -I/opt/vagrant/embedded/include/libxml2 -lcurl -I/opt/vagrant/embedded/include -I/opt/vagrant/embedded/include/libxml2"
#2024/12/17 09:02:16 launcher: env "CONFIGURE_ARGS" = "with-libvirt-include=/usr/include/libvirt with-libvirt-lib=/usr/lib with-curl-include=/usr/include/curl with-curl-lib=/usr/lib "
#2024/12/17 09:02:16 launcher: env "CPPFLAGS" = "-I/opt/vagrant/embedded/include -I/opt/vagrant/embedded/include/libxml2"
@peppergrayxyz
peppergrayxyz / qemu-vulkan-virtio.md
Last active November 29, 2025 12:22
QEMU with VirtIO GPU Vulkan Support

QEMU with VirtIO GPU Vulkan Support

With its latest reales qemu added the Venus patches so that virtio-gpu now support venus encapsulation for vulkan. This is one more piece to the puzzle towards full Vulkan support.

An outdated blog post on clollabora described in 2021 how to enable 3D acceleration of Vulkan applications in QEMU through the Venus experimental Vulkan driver for VirtIO-GPU with a local development environment. Following up on the outdated write up, this is how its done today.

Definitions

Let's start with the brief description of the projects mentioned in the post & extend them:

@starkdmi
starkdmi / ROCm Installation on AMD Ryzen 7 PRO 8700GE.md
Created November 2, 2024 09:41
Installing and verifying ROCm 6.2 and PyTorch 2.6 on AMD Ryzen 7 PRO 8700GE running Ubuntu
@oskarirauta
oskarirauta / 020-add-uxc-exec-function.patch
Created February 22, 2024 16:07
add exec function to openwrt's uxc
--- a/uxc.c
+++ b/uxc.c
@@ -27,6 +27,7 @@
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
+#include <sched.h>
#include <libubus.h>
#include <libubox/avl-cmp.h>
@stokito
stokito / extract_apk.sh
Created August 16, 2023 12:59
Extract/Untar files from Alpine APK file.
# The Alpine package apk file is just a tar.gz file with additional files
# https://wiki.alpinelinux.org/wiki/Apk_spec
# untar into /tmp/ folder without the .PKGINFO and .SIGN.RSA file
tar -xzf openjdk8-jre.apk -C /tmp/ --exclude=.PKGINFO --exclude=.SIGN*
@NoXPhasma
NoXPhasma / installation.md
Last active June 21, 2024 16:51
Install stable-diffusion-webui with ROCm support on Linux

Install stable-diffusion-webui with ROCm support on Arch Linux

First time installation:

  1. Clone and switch to the stable-diffusion-webui folder
git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui
cd stable-diffusion-webui
  1. Create a new python environment and switch to it
@damico
damico / test-rocm.py
Created April 10, 2023 18:54
Script for testing PyTorch support with AMD GPUs using ROCM
import torch, grp, pwd, os, subprocess
devices = []
try:
print("\n\nChecking ROCM support...")
result = subprocess.run(['rocminfo'], stdout=subprocess.PIPE)
cmd_str = result.stdout.decode('utf-8')
cmd_split = cmd_str.split('Agent ')
for part in cmd_split:
item_single = part[0:1]
item_double = part[0:2]