Skip to content

Instantly share code, notes, and snippets.

@joseluisq
joseluisq / resize_disk_image.md
Last active January 13, 2026 00:03
How to resize a qcow2 disk image on Linux

How to resize a qcow2 disk image on Linux

This example takes olddisk.qcow2 and resizes it into newdisk.qcow2, extending one of the guest's partitions to fill the extra space.

1. qcow2 format

1.1. Verify the filesystems of olddisk.qcow2

@GGPrompts
GGPrompts / claude-code-mcp-cli-experimental.md
Created December 9, 2025 15:18
Claude Code MCP-CLI Experimental Mode - 80% Token Savings

Claude Code MCP-CLI Experimental Mode

Announced December 8, 2025 by Anthropic engineer @catherinewu

The Problem

MCP servers load full tool definitions into the system prompt at session start. Power users with multiple MCPs (supabase, tabz, shadcn, docker-mcp, etc.) can burn 40-50k tokens before typing anything.

The Solution

@RefusesNames
RefusesNames / Initialize-VS.ps1
Created May 28, 2024 20:26
This function updates paths and sets environment variables the same way a Visual Studio developer console does
function Initialize-VS {
$vsPath = & (Join-Path ${env:ProgramFiles(x86)} "\Microsoft Visual Studio\Installer\vswhere.exe") -property installationpath
if ($vsPath -is [array]) {
$last = $vsPath | Select -Last 1
Import-Module (Join-Path $last "Common7\Tools\Microsoft.VisualStudio.DevShell.dll")
Enter-VsDevShell -VsInstallPath $last -SkipAutomaticLocation -DevCmdArguments '-arch=amd64 -no_logo'
} else{
Import-Module (Join-Path $vsPath "Common7\Tools\Microsoft.VisualStudio.DevShell.dll")
Enter-VsDevShell -VsInstallPath $vsPath -SkipAutomaticLocation -DevCmdArguments '-arch=amd64 -no_logo'
var mediaJSON = { "categories" : [ { "name" : "Movies",
"videos" : [
{ "description" : "Big Buck Bunny tells the story of a giant rabbit with a heart bigger than himself. When one sunny day three rodents rudely harass him, something snaps... and the rabbit ain't no bunny anymore! In the typical cartoon tradition he prepares the nasty rodents a comical revenge.\n\nLicensed under the Creative Commons Attribution license\nhttp://www.bigbuckbunny.org",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" ],
"subtitle" : "By Blender Foundation",
"thumb" : "images/BigBuckBunny.jpg",
"title" : "Big Buck Bunny"
},
{ "description" : "The first Blender Open Movie from 2006",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4" ],
@lykos92
lykos92 / sensor-light.yaml
Created January 12, 2026 23:28 — forked from Blackshome/sensor-light.yaml
Home Assistant Sensor Light that can be used in Blueprints
blueprint:
name: Sensor Light
description: >
# 💡 Sensor Light
**Version: 8.5**
Your lighting experience, your way - take control and customize it to perfection! 💡✨
@bradtraversy
bradtraversy / terminal-commands.md
Last active January 12, 2026 23:32
Common Terminal Commands

Common Terminal Commands

Key Commands & Navigation

Before we look at some common commands, I just want to note a few keyboard commands that are very helpful:

  • Up Arrow: Will show your last command
  • Down Arrow: Will show your next command
  • Tab: Will auto-complete your command
  • Ctrl + L: Will clear the screen

#!/bin/bash

Claude Code statusline with two-line design and semantic color theory

Line 1: Repo/code context (cool blues/cyans)

Line 2: Session/context info (complementary warm tones)

input=$(cat)

Extract data from JSON

@samsheffield
samsheffield / UnityCodingCheatSheet.txt
Last active January 12, 2026 23:30
Unity C# Cheat Sheet
// Unity C# Cheat Sheet
// I made these examples for students with prior exerience working with C# and Unity.
// Too much? Try Unity's very good tutorials to get up to speed: https://unity3d.com/learn/tutorials/topics/scripting
#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include <stdbool.h>
typedef int8_t i8;
typedef int16_t i16;
typedef int32_t i32;
typedef int64_t i64;
typedef uint8_t u8;