Skip to content

Instantly share code, notes, and snippets.

View katagaki's full-sized avatar

シン katagaki

View GitHub Profile
@katagaki
katagaki / Remove-MicrosoftEdge.ps1
Created August 7, 2026 03:13
Force remove Microsoft Edge from Windows 11.
#Requires -RunAsAdministrator
# Removes Microsoft Edge. Keeps WebView2. Breaks Edge-dependent servicing.
$ErrorActionPreference = 'SilentlyContinue'
# 1. Stop processes, disable services and tasks
Get-Process msedge,msedgewebview2,MicrosoftEdgeUpdate | Stop-Process -Force
foreach ($s in 'edgeupdate','edgeupdatem','MicrosoftEdgeElevationService') {
Stop-Service $s -Force
Set-Service $s -StartupType Disabled
@katagaki
katagaki / Cleanup-Windows11.ps1
Last active August 2, 2026 16:36
Simple script to clean up a fresh UTM Windows 11 install.
#Requires -RunAsAdministrator
<#
.SYNOPSIS
Windows 11 cleanup: telemetry, bundled apps, Copilot/OneDrive/Edge/Bing/new Outlook,
Spotlight off, dark theme on.
.DESCRIPTION
Uses an explicit allowlist for Appx removal. It will not touch SystemApps, shell
components, or framework packages, so explorer.exe survives.
@katagaki
katagaki / blue-archive-birthdays.ics
Created July 24, 2026 10:43
Blue Archive student birthdays in iCal calendar format.
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Blue Archive JP//Student Birthdays//JA
CALSCALE:GREGORIAN
METHOD:PUBLISH
X-WR-CALNAME:ブルーアーカイブ 生徒の誕生日
X-WR-TIMEZONE:Asia/Tokyo
X-WR-CALDESC:ブルーアーカイブ(日本版)実装済み生徒の誕生日
BEGIN:VEVENT
UID:84f2fde9f6e02255@bluearchive.local
@katagaki
katagaki / config.ghostty
Created June 25, 2026 03:36
Ghostty configuration.
background = #1f1f24
background-blur = macos-glass-regular
background-opacity = 0.7
cursor-color = #ffffff
cursor-style = underline
cursor-text = #1f1f24
font-family = SF Mono Terminal
font-size = 11
@katagaki
katagaki / setupAppleContainer.sh
Created June 16, 2026 01:45
Set up Apple `container` with Docker Engine on macOS 27
brew install container
brew tap socktainer/tap
brew install socktainer-next
brew install docker
container system start
container system kernel set --recommended
brew services start socktainer
docker context use socktainer
@katagaki
katagaki / setupiOSSimulator.sh
Last active May 31, 2026 13:05
Set up iOS Simulator for screenshots (9:41, 5G, 100% battery)
# Set time
xcrun simctl status_bar "iPhone" override --time "9:41"
# Set network to 5G
xcrun simctl status_bar "iPhone" override --dataNetwork 5g --cellularMode active --cellularBars 4
# Set network to Wi-Fi
xcrun simctl status_bar "iPhone" override --dataNetwork wifi --wifiMode active --wifiBars 3
# Set battery level
@katagaki
katagaki / claude-design.css
Created April 21, 2026 03:10
Some strange CSS Claude adds to designs.
.ad_content_mask, .ad-slot-234-60, .publisher_ad, .banner-ad-inner, .divider-taboola, .ad-transition, #cookie_consent_container, #Adv8, #Adv9, .gb_area_ads, .msgad, .follower-ad-bottom, .adsense-header, div[data-clickadilla-banner], .hotel-ad, .jw-ad-label, .lj-like-item, .spon-img[src*=".alicdn."], .cookies-modal, #intro_ad_1, #ad-mid-rect, .a-icon-share-pinterest, #ad-base, #homepage_top_ads, #left_ads, #left_adv, .Sailthru_Subscribe, .ad-vertical, #taboola-below-article-thumbnails-mg, #eucookienotice, #leaderAdContainer, .nav-ads, .js-ad_iframe, .grey-ad-notice, #infos_cookie, .doubleClickAd, .navbar-header-ad, #advertising_wrapper, .etn-ad-text, #adsDisplay, #AdSpaceLeaderboard, #adspace_header, .adz-horiz, #inArticleAdv, .ac_adbox, .ad-hoverable, .buySellAdsContainer, #taboola-below-article-thumbnails-v2, .ad-box-auto, .resp-sharing-button, .rekl_left, .guide__row--fixed-ad, .masthead__ad, .primis-player__container, #close-fixedban, .sets-cookie, .frAd, .social_knopki, .ad400x40, .socialList-type03, #adv
@katagaki
katagaki / ExportSiteData.js
Created February 20, 2026 09:42
Export site data from one browser and import it into another.
async function massiveExport() {
console.log("Starting chunked export...");
const chunks = [];
chunks.push('{\n"localStorage": ' + JSON.stringify({ ...localStorage }) + ',\n');
chunks.push('"sessionStorage": ' + JSON.stringify({ ...sessionStorage }) + ',\n');
chunks.push('"cookies": ' + JSON.stringify(document.cookie) + ',\n');
chunks.push('"indexedDB": {\n');
const dbs = await indexedDB.databases();
@katagaki
katagaki / fix-universal-clipboard.sh
Created December 13, 2025 11:31
Fix macOS Universal Clipboard
defaults write ~/Library/Preferences/com.apple.coreservices.useractivityd.plist ClipboardSharingEnabled 1
@katagaki
katagaki / docker-rm-all.sh
Created October 28, 2025 07:41
Delete all Docker images
docker rmi --force $(docker images --all --quiet)