Skip to content

Instantly share code, notes, and snippets.

@myinusa
myinusa / a-series-of-tools-linux-bootstrap.sh
Created March 7, 2026 17:55
a-series-of-tools-linux-bootstrap.sh
#!/usr/bin/env bash
set -Eeuo pipefail
LOG_FILE="${HOME}/install-bootstrap.log"
log() {
printf '\n[%s] %s\n' "$(date '+%Y-%m-%d %H:%M:%S')" "$*" | tee -a "$LOG_FILE"
}
run() {
@myinusa
myinusa / cataclysm-vital-ubnutu-savior.sh
Created March 7, 2026 17:30
cataclysm-vital-ubnutu-savior.sh
#!/usr/bin/env bash
set -Eeuo pipefail
export DEBIAN_FRONTEND=noninteractive
log() {
printf '\n[%s] %s\n' "$(date '+%F %T')" "$*"
}
require_sudo() {
@myinusa
myinusa / one-keybinding-to-open-2-split-terminals-and-run-commands.md
Created February 7, 2026 18:03
VS Code: One keybinding to open 2 split terminals and run commands (Linux/macOS/Windows)

VS Code: One keybinding to open 2 split terminals and run commands (Linux/macOS/Windows)

This guide shows how to use built-in VS Code commands (no extension required) to:

  • Open a new integrated terminal
  • Split it
  • Run a command in each terminal

Works great for starting dev servers, Docker Compose, watchers, etc.

@myinusa
myinusa / PowerShellZshKeybindings.md
Last active February 6, 2026 18:21
PowerShellZshKeybindings

I totally get it. That "muscle memory" gap between Linux and Windows is the ultimate productivity killer. On Zsh (likely using zsh-autosuggestions or a similar plugin), pressing the Up arrow performs a History Search based on what you’ve already typed, whereas standard PowerShell just cycles through every single past command.

The good news? You already have the right tool installed in your profile: PSReadLine. You just need to tell it to behave like your Linux setup.

The Fix: Update your Profile

Open your PowerShell profile (the file in your screenshot) and add these two lines at the bottom:

Set-PSReadLineKeyHandler -Key UpArrow -Function HistorySearchBackward

AI Agent Configuration: Software Development

Role Profile

  • Persona: Highly skilled Software Developer with a perfectionist mentality.
  • Specialization: Expert in TypeScript and modern web architecture.
  • Core Objective: Deliver advanced, modern, and detailed scripts that adhere to enterprise-level software engineering standards.

Coding Standards & Style

@myinusa
myinusa / Copy as Linux Path on W11.md
Last active December 2, 2025 12:04
Copy as Linux Path on Windows 11 (WSL-style `/mnt/c/...`)

“Copy as Linux Path” on Windows 11 (WSL-style /mnt/c/...)

Small quality-of-life thing: on Windows you can copy a file/folder path, but it looks like this:

C:\Users\you\projects

If you’re working with WSL, Docker, or Linux tools, it’s nicer as:

@myinusa
myinusa / copy-code-block-button.user.js
Created October 12, 2025 16:33
Universal Code Block Copy Button
// ==UserScript==
// @name Universal Code Block Copy Button
// @namespace http://tampermonkey.net/
// @version 1.0.0
// @description Adds a copy button to the top-right corner of all code blocks on any website
// @author myinusa
// @match *://*/*
// @grant GM_setClipboard
// @grant unsafeWindow
// @run-at document-idle
@myinusa
myinusa / lowkey-flow.md
Last active February 12, 2026 12:21
my-lowkey-ai-flow

My AI Flow

Prerequisites

Consectetur laboris ut adipisicing culpa id occaecat cupidatat eiusmod fugiat velit.

Overview

Consectetur laboris ut adipisicing culpa id occaecat cupidatat eiusmod fugiat velit.

@myinusa
myinusa / copilot-usage.sh
Created October 9, 2025 10:05
Copilot Premium Request
#!/usr/bin/env bash
limit=1500
USER=$(gh api user -q .login)
response=$(gh api -H "X-GitHub-Api-Version: 2022-11-28" \
"/users/$USER/settings/billing/premium_request/usage?year=$(date +%Y)&month=$(date +%-m)")
used=$(jq '[.usageItems[] | select(.sku=="Copilot Premium Request") | .grossQuantity] | add' <<< "$response")
pct=$(awk "BEGIN {printf \"%.2f\", ($used/$limit)*100}")
echo "Copilot Premium Requests: $used / $limit used ($pct%)"
@myinusa
myinusa / Mass Git Pull Script.md
Created July 17, 2025 21:09
PowerShell Git Pull Script

Okay, to mass git pull or update folders in the first level of your current directory using PowerShell on Windows, you can use a foreach loop. Here's the command:

Get-ChildItem -Directory | ForEach-Object {
    if (Test-Path -Path "$($_.FullName)\.git") {
        Write-Host "Pulling changes in $($_.Name)..."
        Push-Location $_.FullName
        git pull
        Pop-Location
 } else {