Skip to content

Instantly share code, notes, and snippets.

View sonikro's full-sized avatar

Jonathan Nagayoshi sonikro

  • 06:46 (UTC -03:00)
View GitHub Profile
@sonikro
sonikro / shrink_disks.ps1
Created November 14, 2025 01:22
Find and Shrink WSL2 + Docker Desktop Virtual Disks on Windows
param(
[switch]$Force
)
$ErrorActionPreference = "Stop"
function Write-Header {
param([string]$Message)
Write-Host "`n" -NoNewline
Write-Host ([string]::new("=", 80)) -ForegroundColor Cyan
@sonikro
sonikro / security.groovy
Created March 27, 2020 18:19
Recover access to lost Jenkins
#!groovy
import jenkins.model.*
import hudson.security.*;
import hudson.util.*;
import jenkins.install.*;
def instance = Jenkins.getInstance()
def hudsonRealm = new HudsonPrivateSecurityRealm(false)