Skip to content

Instantly share code, notes, and snippets.

View kekneus373's full-sized avatar

kekneus373

View GitHub Profile
@kekneus373
kekneus373 / swap-get-out.bash
Created January 1, 2026 12:09
[LowRam] Free Up Swap Space When Unneeded
#!/usr/bin/env bash
# Re-run the script as root if not already running as root
if [ "$EUID" -ne 0 ]; then
echo "This script requires root. Re-running with sudo..."
exec sudo "$0" "$@"
fi
free_mem="$(free | grep 'Mem:' | awk '{print $7}')"
used_swap="$(free | grep 'Swap:' | awk '{print $3}')"
@kekneus373
kekneus373 / run-appimage-nixos.bash
Created January 1, 2026 12:03
[QUICK FIX] Run Qt AppImages on NixOS (Could not load the Qt platform plugin "xcb")
#!/usr/bin/env bash
# activate `appimage-run` first: https://wiki.nixos.org/wiki/Appimage
appimage=<your_appimage_path> # set your executable path
QT_PLUGIN_PATH= appimage-run "$appimage" # RUN IT
# SOURCE: https://discourse.nixos.org/t/appimage-run-fails-loading-qt-platform-plugin-xcb/29293
@kekneus373
kekneus373 / revive-xhci.bash
Created January 1, 2026 10:51
Fix "xHCI host controller not responding, assume dead" w/o rebooting
#!/usr/bin/env bash
# Re-run the script as root if not already running as root
if [ "$EUID" -ne 0 ]; then
echo "This script requires root. Re-running with sudo..."
exec sudo "$0" "$@"
fi
ID="0000:00:14.0" # your controller id; look for ID with `sudo ls /sys/bus/pci/drivers/xhci_hcd/` (SUDO REQUIRED)
@kekneus373
kekneus373 / retouchpad.bash
Created January 1, 2026 10:37
Fix touchpad not working after suspend (temporarily)
#!/usr/bin/env bash
echo "Disabling touchpad..."
sudo modprobe -r psmouse
echo "Enabling touchpad..."
sudo modprobe psmouse
echo "Should work now. Otherwise, check 'dmesg' or reboot"
# SOURCE: https://askubuntu.com/q/671910
@kekneus373
kekneus373 / qemu-network-start.bash
Created January 1, 2026 10:35
[QEMU] Solve “Network ‘default’ is not active”
#!/usr/bin/env bash
# start `default` virtual network interface
sudo virsh net-start default
# SOURCE: https://forum.level1techs.com/t/solved-qemu-network-default-is-not-active-booting-from-hard-disk/194698
@kekneus373
kekneus373 / kill-teamviewer.bash
Created January 1, 2026 10:31
[NixOS] Script for killing the TeamViewer service (w/o systemd)
#!/usr/bin/env bash
# Check if the script is running with root privileges
if [ $(id -u) != 0 ]; then
echo "This script must be run as root."
exit 1
fi
# Check if the teamviewerd process exists and kill it if it does
if pgrep -x teamviewerd > /dev/null
@kekneus373
kekneus373 / kill-anydesk.desktop
Created January 1, 2026 10:29
[Fedora][GNOME] Prevent AnyDesk From Auto Starting on Gnome
# Put this file into ~/.config/autostart
[Desktop Entry]
Name=Kill AnyDesk
GenericName=Kill AnyDesk
Comment=Simple script to kill AnyDesk service at login
Exec=killall anydesk # Ensure `killall` is available on your OS
Terminal=false
Type=Application
Icon=software-update-urgent-symbolic # Adwaita does not provide AD icon
Categories=GNOME;GTK;Utility
@kekneus373
kekneus373 / use-youtube-on-ancient-machines-with-linux.md
Created January 1, 2026 09:46
Play YouTube on Ancient PCs w/o Drivers

Play Modern YouTube Videos on Ancient PCs w/o Good Driver Support


  1. Open the Terminal
@kekneus373
kekneus373 / full-lxc-guide-for-sweats-only.md
Last active January 4, 2026 22:11
[😅For Sweats Only] Creating Unprivileged LXC Container on Debian 12

Complete Guide: Creating an LXC Container for Docker on Debian 12 (2025-2026)

AI only formatted this doc and added explanations where it knew. I confirm all the steps here were actually taken by me to achieve the desired result🙂

This guide walks you through setting up an unprivileged LXC container on Debian 12 to run Docker, using systemd for proper cgroup delegation.

Prerequisites

  • Debian 12 (Bookworm) host system
@kekneus373
kekneus373 / make-clonezilla-pro-wo-nomodeset.md
Last active December 30, 2025 16:39
[FIX Illegible/Scrambled Screen] Build your own Clonezilla with enabled modesetting

Making custom CloneZilla "Pro" ISO image w/o nomodeset option for better support on modern hardware

After numerous fails and hours of scouting the web, I finally resolved all the issues related with Clonezilla on modern hardware. You may call me dumb for not just pressing "K" in the scrambled Clonezilla GRUB screen to enable kernel modesetting but whatever idc I found that out only while inspecting GRUB config y'know. 🙂

For more info why that may be relevant in your case skip here

Step 1. Get and mount the latest ISO

Download the latest version (here I used Debian stable) → official link