Skip to content

Instantly share code, notes, and snippets.

@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 November 17, 2025 17:36
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 {
# Array of application IDs
$apps = @(
"Obsidian.Obsidian",
"junegunn.fzf",
"Nilesoft.Shell",
"Wazuh.WazuhAgent",
"TechPowerUp.GPU-Z",
"KDE.KDEConnect",
"GitHub.cli",
"Gyan.FFmpeg",
@myinusa
myinusa / keybidings.json
Last active February 9, 2025 12:37
MY VSCode Shortcuts
[
{
"key": "ctrl+alt+b",
"command": "workbench.action.toggleAuxiliaryBar",
"title": "View: Toggle Secondary Side Bar Visibility",
"source": "system"
},
{
"key": "ctrl+b",
"command": "workbench.action.toggleSidebarVisibility",
git fetch --prune --all -v && \
git branch -vv | grep ': gone]' | awk '{print $1}' | xargs -I {} git branch -D {} 2>/dev/null && \
git remote prune origin && \
for b in $(git branch -r | tr '/' ' '); do
if [ "$b" != "HEAD" ]; then
git checkout "${b#origin/}" && git pull;
fi;
done
@myinusa
myinusa / workbench.colorCustomizations.json
Created December 31, 2024 13:29 — forked from dcts/workbench.colorCustomizations.json
A list of all Visual Studio Code customizable colors, grouped by UI region. Copy and paste into User Settings (comments are allowed) to tweak an existing theme or work on your own.
"workbench.colorCustomizations": {
// Contrast Colors - The contrast colors are typically only set for high contrast themes. If set, they add an additional border around items across the UI to increase the contrast.
"contrastActiveBorder": "",
"contrastBorder": "",
// Base Colors
"focusBorder": "",
"foreground": "",
"widget.shadow": "",
"selection.background": "",
"descriptionForeground": "",
@myinusa
myinusa / AvailableUpdate.ps1
Last active February 3, 2025 13:12
Powershell Workshop
function Get-AvailableUpdates {
[CmdletBinding()]
Param()
Write-Host "Initializing Windows Update session..."
$wu_session = New-Object -ComObject Microsoft.Update.Session
$wu_searcher = $wu_session.CreateUpdateSearcher()
Write-Host "Searching for available updates..."
$updates = $wu_searcher.Search("IsInstalled=0 and Type='Software' and IsHidden=0")
@myinusa
myinusa / no-box.ps1
Last active November 25, 2024 20:10
boxstarter-1
$ErrorActionPreference = "Continue"
$ProgressPreference = "Continue"
function Install-WingetAndPowerShell {
try {
Write-Host "[+] Installing Winget and PowerShell..." -ForegroundColor Yellow
# Install Winget
Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe
Write-Host "Winget installed"