Skip to content

Instantly share code, notes, and snippets.

@pavax
pavax / z2m_aqara_trv_external_temperature.yaml
Last active January 10, 2026 08:38
z2m_aqara_trv_external_temperature.yaml
blueprint:
name: Aqara TRV E1 External Temperature Control
description: >
This automation allows the Aqara TRV E1 Smart Radiator Thermostat to use temperature readings from an external sensor rather than its internal sensor. Whenever the temperature sensor reports a new value, it is sent to the TRV for more accurate climate control.
domain: automation
source_url: "https://gist.github.com/pavax/8d6ed250765d89cb281d4a1762b8d2e8"
input:
external_temp_sensor:
name: External Temperature Sensor
#!/usr/bin/env python3
"""
Claude Code PreToolUse Hook: Compositional Bash Command Approval
PROBLEM
-------
Claude Code's static permission system uses prefix matching:
"Bash(git diff:*)" matches "git diff --staged" but NOT "git -C /path diff"
"Bash(timeout 30 pytest:*)" matches that exact timeout, not "timeout 20 pytest"
"use client";
import { useEffect, useState } from "react";
import { IBreadcrumb } from "@/types";
import { BreadcrumbItem } from "@/components";
import { usePathname } from "next/navigation";
export const Breadcrumb = () => {
const pathname = usePathname();
const [breadcrumbs, setBreadcrumbs] = useState<IBreadcrumb[]>([]);
@jorgeadev
jorgeadev / layout.tsx
Last active January 10, 2026 08:32
Example using custom fonts
import type { Metadata } from "next";
import localFont from "next/font/local";
import "../styles/globals.css";
import { ReactNode } from "react";
const excalifont = localFont({
src: "./fonts/excalifont-regular.woff",
variable: "--font-excalifont",
weight: "100 200 300 400 500 600 700 800 900 normal regular bold light italic",
});
@jorgeadev
jorgeadev / layout-h-screen.tsx
Last active January 10, 2026 08:32
Tailwind layout screen full height
export default function HomePage() {
return (
<div className="min-h-screen flex flex-col h-screen">
<header className="bg-red-50">Header</header>
<div className="flex-1 flex flex-row overflow-y-hidden">
<main className="flex-1 bg-indigo-100 overflow-y-auto">Content here</main>
<nav className="order-first sm:w-32 bg-purple-200 overflow-y-auto">Sidebar</nav>
<aside className="sm:w-32 bg-yellow-100 overflow-y-auto">Right Sidebar</aside>
</div>
<footer className="bg-gray-100">Footer</footer>
@LeaTex
LeaTex / learning_english.md
Last active January 10, 2026 08:32
recursos para aprender inglés de manera autodidacta (desde cero)
@jorgeadev
jorgeadev / 1.RegistrySnapshot.xml
Created January 10, 2026 08:30 — forked from choco-bot/1.RegistrySnapshot.xml
squirreldisk v0.3.4 - Passed - Package Tests Results
<?xml version="1.0" encoding="utf-8"?>
<registrySnapshot xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<user>S-1-5-21-4010432545-2485811193-966787038-1000</user>
<keys>
<key installerType="Msi" displayName="SquirrelDisk" displayVersion="0.3.4">
<RegistryView>Registry64</RegistryView>
<KeyPath>HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{B9875F98-0F9E-42DB-9A57-279AA8A90CC1}</KeyPath>
<DefaultValue />
<InstallLocation><![CDATA[C:\Program Files\SquirrelDisk\]]></InstallLocation>
<UninstallString><![CDATA[MsiExec.exe /X{B9875F98-0F9E-42DB-9A57-279AA8A90CC1}]]></UninstallString>
@choco-bot
choco-bot / FilesSnapshot.xml
Created January 10, 2026 08:30
bettertrumpet v2.3.1 - Passed - Package Tests Results
<?xml version="1.0" encoding="utf-8"?>
<fileSnapshot xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<files>
<file path="C:\ProgramData\chocolatey\lib\bettertrumpet\bettertrumpet.nupkg" checksum="D0C3EBCF41709D547883B9DEED336FB1" />
<file path="C:\ProgramData\chocolatey\lib\bettertrumpet\bettertrumpet.nuspec" checksum="2697BDFB52837377EBDE0D1F010BE1FF" />
<file path="C:\ProgramData\chocolatey\lib\bettertrumpet\tools\BetterTrumpet.exe" checksum="2C32342A67627EE02183334DE0F264F7" />
<file path="C:\ProgramData\chocolatey\lib\bettertrumpet\tools\BetterTrumpet.exe.ignore" checksum="D41D8CD98F00B204E9800998ECF8427E" />
<file path="C:\ProgramData\chocolatey\lib\bettertrumpet\tools\chocolateyInstall.ps1" checksum="D19A3CAD904EDF666B5F4F10EBB4E9A2" />
</files>
</fileSnapshot>
@choco-bot
choco-bot / 1.RegistrySnapshot.xml
Created January 10, 2026 08:30
squirreldisk v0.3.4 - Passed - Package Tests Results
<?xml version="1.0" encoding="utf-8"?>
<registrySnapshot xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<user>S-1-5-21-4010432545-2485811193-966787038-1000</user>
<keys>
<key installerType="Msi" displayName="SquirrelDisk" displayVersion="0.3.4">
<RegistryView>Registry64</RegistryView>
<KeyPath>HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{B9875F98-0F9E-42DB-9A57-279AA8A90CC1}</KeyPath>
<DefaultValue />
<InstallLocation><![CDATA[C:\Program Files\SquirrelDisk\]]></InstallLocation>
<UninstallString><![CDATA[MsiExec.exe /X{B9875F98-0F9E-42DB-9A57-279AA8A90CC1}]]></UninstallString>

To update all outdated pip packages in Windows run:

python -m pip freeze | % { $_.split('==')[0] } | %{ python -m pip install --upgrade $_ }