Skip to content

Instantly share code, notes, and snippets.

@kanehekili
kanehekili / 00-README.md
Last active November 26, 2026 23:48
KVM VMs with working virtiofs share, clipboard and guest agent

KVM VMs with a working shared folder and clipboard, in one command

virt-install can set up a virtiofs host share, SPICE clipboard and the QEMU guest agent, but each needs a flag you only find out about after it doesn't work. These scripts bundle the combination that works, plus the one host config change that virtiofs silently requires.

The whole flow is three steps: run one script on the host, install the guest normally, run one command in the guest. After that the share mounts on every boot and copy/paste works in both directions.

## Verified ESP8266 WiFi Event Behavior
**Test Setup:**
- D1 Mini (ESP-12F)
- Arduino Core 3.1.2
- 50+ reboot cycles
**Reliable:**
✅ `onStationModeGotIP` (when stored statically)
@kanehekili
kanehekili / Qt6OpenGlMVPTest.py
Created May 3, 2024 21:43
Non working Qt6 openGL Test with mpv
'''
Created on 3 May 2024
@author: matze
'''
from PyQt6 import QtWidgets
"""
based on:
https://github.com/mpv-player/mpv-examples/blob/master/libmpv/qt_opengl/mpvwidget.cpp
@kanehekili
kanehekili / picom.conf
Created May 7, 2021 19:49
Picom (ex compton) config for thinkpad R61i (Intel Core2 Duo T5450)
backend = "glx";
glx-no-stencil = true;
use-damage = true
glx-no-rebind-pixmap = true;
xrender-sync-fence = true #seems to help against missing refresh
#vsync=true; #any vync breaks
glx-swap-method = "exchange";
#################################
#
# Shadows
@kanehekili
kanehekili / monitorRight.sh
Last active April 6, 2020 19:05
bash script to set multiple monitors with xrandr (generic approach)
#!/bin/bash
# simple script that either connects or disconnects the external monitor
# the prime output is the local (laptop) screen
# the secondary is either discovered,but not connected or disconnected but not removed (screen size too big)
oldifs="$IFS"
IFS=$'\n'
export DISPLAY=:0.0
#sleep 2
@kanehekili
kanehekili / compton.conf
Last active May 10, 2019 17:46
compton config on Thinkpad R61i
backend = "glx";
glx-no-stencil = true;
glx-swap-method = "buffer-age";
glx-use-copysubbuffermesa = true;
glx-no-rebind-pixmap = true;
xrender-sync-fence = true #seems to help against missing refresh
vsync = "opengl-swc"; #Works faster than mswc!
shadow = true;
no-dnd-shadow = true;
no-dock-shadow = true;
@kanehekili
kanehekili / userChrome.css
Created March 8, 2019 08:12
Firefox round tabs and a colorful findbar
:root {
--tab-curve-width: 30px;
--tabs-border: transparent !important;
}
.tabbrowser-arrowscrollbox .arrowscrollbox-scrollbox {
padding-inline-start: 10px !important;
}
/* To be able to see the top border of the tab */