Skip to content

Instantly share code, notes, and snippets.

View Hona's full-sized avatar

Luke Parker Hona

View GitHub Profile
@Hona
Hona / glass-watch.ps1
Created October 30, 2026 06:06
anomalyco/opencode#59229 glass-watch.ps1: logs when a window takes clicks but is not drawn
# Logs when a window takes clicks but is not drawn (anomalyco/opencode#59229).
# Every 250 ms it finds the top-level window whose title starts with -Title, then checks four
# points inside it: WindowFromPoint must return that window, and the screen pixel must be the
# test page's magenta. A point that hits the window but is not magenta is logged as GLASS.
# Coordinates are physical pixels. Run: powershell -ExecutionPolicy Bypass -File glass-watch.ps1
param(
[string]$Title = "repro-59229",
[int]$Seconds = 86400,
[string]$Log = (Join-Path $PSScriptRoot "glass-watch.jsonl")
)
@Hona
Hona / index.html
Created October 30, 2026 06:06
anomalyco/opencode#59229 minimal repro: maximized frameless Electron window with a Window Controls Overlay (Electron Fiddle)
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<title>repro-59229</title>
<style>
html,
body {
margin: 0;
height: 100%;
@Hona
Hona / 00-ftb-infinity-evolved-expert-gtnh-modern.md
Last active October 25, 2026 09:04
FTB Infinity Evolved 3.1.0 Expert on Java 25: exact GTNH-modern setup, pinned installer, complete configs, fixes, benchmarks and SHA-256 snapshot

FTB Infinity Evolved 3.1.0 Expert on Java 25 with the GTNH forks

BLUF: FTB Infinity Evolved 3.1.0 Expert, running on Java 25 with maintained 1.7.10 mod forks and modern performance mods. The goal is to keep IE's Expert progression while fixing old bugs—not to add GregTech or turn it into GT New Horizons. The recorded comparison shows 2.5× the average frame rate and roughly half the startup time. This guide includes a pinned installer, a manual install path, every config change, and the source for the custom compatibility fixes.

Snapshot: 2026-10-25. Windows single-player is the verified target. This is an unofficial, new-world setup, not an official FTB or GTNH release or a drop-in world upgrade.

3.1.0 as released This build
Java 8 25 (ZGC, compact object headers)
Startup from FML logging to the main menu, median 63 s 35 s
@Hona
Hona / changelog.md
Created September 29, 2026 04:12
changelog pls

i come to you once again, as a man. asking for a changelog generator v2 branch desktop/app related changes

product words write a changelog like Palworld v1 release changelog but for OpenCode Desktop but use google dev writing guidelines

@Hona
Hona / opencode-fix-windows-acl.ps1
Last active September 21, 2026 00:09
opencode: repair Windows profile directory permissions (~/.config, ~/.cache, ~/.local locked by an elevated-created protected ACL, e.g. Python>=3.12.4 mkdir(mode=0o700) via Scapy)
# opencode - repair Windows profile directory permissions
#
# Symptom : OpenCode desktop shows "Server process exited with code 1", or the CLI prints
# "EPERM: operation not permitted, mkdir 'C:\Users\<you>\.config\opencode'" (or .cache / .local).
# Cause : ~\.config, ~\.cache or ~\.local were created by another program running elevated with a
# protected ACL that excludes your own account (e.g. Python >= 3.12.4 mkdir(mode=0o700) via Scapy).
# Fix : take ownership and reset inheritance on the affected directories only, then verify.
#
# Run (in any PowerShell; it will ask for admin rights itself):
# irm https://gist.githubusercontent.com/Hona/7d5a3fc24a478f34fb04a851af468853/raw/opencode-fix-windows-acl.ps1 | iex
@Hona
Hona / index.html
Created September 19, 2026 04:41
Electron: Skia GPU shaders are never persisted (no GrShaderCache directory)
<!doctype html>
<html>
<body style="font: 14px system-ui; background: #111; color: #eee; padding: 24px">
<h1 style="text-shadow: 0 2px 8px #0008; mix-blend-mode: plus-lighter">Skia shader cache probe</h1>
<div style="display: flex; gap: 12px">
<div style="width: 160px; height: 90px; border-radius: 12px; background: linear-gradient(135deg, #f36, #36f); box-shadow: 0 8px 24px #0009"></div>
<div style="width: 160px; height: 90px; border-radius: 50%; border: 3px dashed #6f6; backdrop-filter: blur(4px)"></div>
<div style="width: 160px; height: 90px; background: #345; opacity: 0.6; transform: rotate(6deg)"><p style="mix-blend-mode: multiply">text on multiply</p></div>
</div>
<p>Relaunch a few times. Chrome/Edge: <code>GrShaderCache</code> fills and shaders stop compiling. Electron: the directory never exists.</p>
@Hona
Hona / code-like-luke.md
Created August 13, 2026 01:44
OpenCode slash command for happy-path-first, use-case-oriented software design
description Implement with clear orchestration, strong interfaces, and happy-path-first design

Code like Luke.

Implement the requested change, but optimize the design for the normal user flow. If the happy path is 95% of runtime behavior, it should be approximately 95% of the code readers see.

Start with context:

  • inspect the existing code, callsites, data flow, and nearby conventions
@Hona
Hona / guided-review.md
Created June 1, 2026 03:49
opencode global slash command: guided-review
description Guided review especially when an agent does so much work you don't have a deep understanding of all the changes, every single line of syntax etc. Force a complete understanding.

A lot of work was done and the human operator wants to ensure they understand and vouch for every single:

  • technical choice
  • architectural choice
  • line of code
  • sytax sugar (style)
@Hona
Hona / opencode-desktop-performance.md
Created May 17, 2026 23:12
OpenCodeDesktop performance session archive, findings, TLDR, and blog draft

OpenCodeDesktop performance work: findings, TL;DR, and blog draft

Generated: 2026-05-18 Source: local OpenCode session archive (opencode db) plus GitHub PR metadata via gh.

TL;DR

Before: measured stable session timeline loads were roughly 2-4 seconds, with real-world bad sessions reported around 5-15 seconds.

After: the main virtualized path reached sub-500ms first useful timeline render. Later cache/anchor work made the bottom-aligned visual load appear in about 113ms on the measured cold path.

@Hona
Hona / README.md
Created April 30, 2026 02:40
WSL1 Bun build --compile ELF ENOEXEC repro

WSL1 Bun build --compile ELF repro

Repro bundle for oven-sh/bun#29963.

Run inside WSL1:

sudo apt-get update
sudo apt-get install -y curl unzip file binutils strace
bash repro-bun-compile-wsl1.sh