Skip to content

Instantly share code, notes, and snippets.

View InTEGr8or's full-sized avatar
😊
Always Be Coding

Mark Stouffer InTEGr8or

😊
Always Be Coding
View GitHub Profile
@InTEGr8or
InTEGr8or / Prevent-WSLSilentUpdates.ps1
Last active September 5, 2026 20:45
Prevent Windows from silently auto-updating WSL and killing running microVMs
<#
.SYNOPSIS
Prevents Windows from silently auto-updating Windows Subsystem for Linux (WSL)
and abruptly terminating running microVM instances and active developer sessions.
.DESCRIPTION
By default in modern Windows 11 builds, WSL is classified as a "System Component"
managed by Microsoft Update and Microsoft Store. When an update is deployed,
the Windows RestartManager forcefully kills vmwp.exe and wslhost.exe to replace
binaries, dropping all running containers, distros, and background jobs.
@InTEGr8or
InTEGr8or / distro-setup.sh
Created April 3, 2026 21:00
A lightweight interactive select list installer. Store your favorte items in the tools.list Interactive select the needed items on any new machine or instance.
#!/usr/bin/env bash
LIST_FILE="$HOME/tools.list"
STATE_FILE="$HOME/.mstouffer_setup_state.json"
BLUE='\033[0;34m'; GREEN='\033[0;32m'; RED='\033[0;31m'; YELLOW='\033[1;33m'; NC='\033[0m'; BOLD='\033[1m'
if [[ ! -f "$LIST_FILE" ]]; then
echo -e "${RED}Error: $LIST_FILE not found.${NC}"
exit 1
@InTEGr8or
InTEGr8or / migrate-wsl.sh
Last active April 1, 2026 06:48
Migrate important folders and files from one WSL instance to another.
#!/usr/bin/env bash
# --- CONFIGURATION ---
BRIDGE="/mnt/wsl/migrate_source"
CORE_ITEMS=(".ssh" ".gitconfig" ".config" ".bashrc" ".zshrc")
SCAN_DIRS=("repos")
REQUIRED_GROUPS=("docker" "mysql" "ollama" "onepassword" "onepassword-cli" "tomcat" "lxd")
MARKER=".migration_complete"
# --- ICONS & COLORS ---
@InTEGr8or
InTEGr8or / Gist-README.md
Created February 24, 2026 05:54
WSL2 Disk Cleanup & Bloat Scanner Script

WSL Disk Cleanup Utility

A simple Bash script to scan and identify disk bloat in WSL2 (Windows Subsystem for Linux) environments.

Features

  • Scans top 15 largest directories in $HOME.
  • Reports sizes of common tool caches (Docker, Mise, UV, Playwright, NPM, etc.).
  • Identifies potential junk files like Java heap dumps (.hprof) and large installer files (.run).
  • Provides one-touch cleanup commands.
@InTEGr8or
InTEGr8or / GlobalTTS.ahk
Last active January 24, 2026 23:46
Global Windows AI TTS Reader (AppsKey + uv + edge-tts)
#Requires AutoHotkey v2.0
; Global TTS Reader
; Uses explicit hotkey definitions to ensure native functions are suppressed.
; 1. Standard Read
$AppsKey::
{
HandleTTS(false)
}
@InTEGr8or
InTEGr8or / Makefile-head
Last active July 8, 2026 03:43
My developing Makefile help header.
#!/usr/bin/env bash
.PHONY: help
help: ## Display this help screen
@echo "Available commands:"
@awk 'BEGIN {FS = ":.*?## "}; /^[a-zA-Z0-9_-]+:.*?## / {printf " \033[32m%-20s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
# ==============================================================================
# Application Tasks
# ==============================================================================
@InTEGr8or
InTEGr8or / ssh_keys_profile.ps1
Last active April 19, 2025 14:43
Add, List, and Remove SSH keys to authorized_keys while respecting Windows strict security
#requires -Version 5.1+
<#
Windows OpenSSH has strict permissions requirements on the `~/.ssh/authorized_keys` file that
can make adding or removing or even listing keys cumbersome.
This script handles the grunt-work to handle those requirements.
#>
<#
.SYNOPSIS
@InTEGr8or
InTEGr8or / uninstall_cursor.ps1
Last active October 7, 2025 13:09
Uninstall Cursor IDE PowerShell script
if(-Not $cursorPath -OR -NOT $appDataCursorPath){
Write-Host "set `$cursorPath with the actual installation path of Cursor"
Write-Host "set `$appDataCursorPath with the actual installation path of Cursor"
}
Write-Host "Remove $cursorPath and it's contents"
if (Test-Path $cursorPath) {
Remove-Item -Recurse -Force $cursorPath
}
@InTEGr8or
InTEGr8or / restart-cline-task.ts
Last active January 29, 2025 01:35
Restart Cline with up-to-date project status.
function displayImplementationStatus(progress, showOnlyIncomplete) {
const branch = 'current-branch'; // placeholder
console.log(`
VSCode Context Client Implementation Status (Branch: ${branch})
${showOnlyIncomplete ? '(Showing only incomplete items)' : ''}
=========================================================
`);
progress.sections.forEach((section) => {
@InTEGr8or
InTEGr8or / remove_all_docker.sh
Created November 8, 2024 17:51
Removes all Docker in WSL on Windows
#!/bin/bash
# Script to comprehensively uninstall Docker on Linux systems
# Uninstall Docker Engine, CLI, Containerd, and Docker Compose packages
sudo apt-get purge -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin docker-compose
# Remove Docker's official GPG key and repository
sudo rm -f /etc/apt/keyrings/docker.gpg
sudo rm -f /etc/apt/sources.list.d/docker.list