Skip to content

Instantly share code, notes, and snippets.

View Turbo87's full-sized avatar

Tobias Bieniek Turbo87

View GitHub Profile
@Turbo87
Turbo87 / SKILL.md
Created November 12, 2026 15:44
clean-up-agent-branches: Agent skill that removes branches and worktrees left behind by T3 Code, Codex, and Claude Code. Layout: SKILL.md in clean-up-agent-branches/, *.py in clean-up-agent-branches/scripts/, openai.yaml in clean-up-agent-branches/agents/
name clean-up-agent-branches
description Remove branches and worktrees left behind by T3 Code, Codex, and Claude Code once their threads are settled and their work is merged or empty, including merged branches on the `origin` fork. Use only when explicitly invoked.
disable-model-invocation true

Clean up agent branches

Paths below are relative to this skill's directory. The script plans and applies the cleanup. Never delete branches or remove worktrees by hand, never pass --force, never delete branches on remotes other than origin, and never write to the T3 or Codex databases.

@Turbo87
Turbo87 / SKILL.md
Created July 23, 2026 09:08
Brainstorm Skill
name brainstorm
description Guide structured brainstorming from a rough idea into a design, specification, and eventual implementation plan. Use when the user wants to brainstorm, talk through an idea, refine a product or technical design, turn an idea into a spec, or asks for one-question-at-a-time ideation. Do not implement during the brainstorm unless the user explicitly exits brainstorming.

Brainstorm

Help the user turn an initial idea into a coherent design and spec through focused questions and staged synthesis.

Workflow

@Turbo87
Turbo87 / SKILL.md
Created July 14, 2026 14:56
Cooperative Code Review Skill
name cooperative-code-review
description Review a pull request, branch, commit, staged change, or working-tree diff interactively with the user in small readable chunks. Use when the user asks to review code together, walk through changes one chunk at a time, inspect a PR collaboratively, or wants a code-first review with pause points and ready-to-post findings. Do not use for one-shot review reports, addressing existing review comments, or CI debugging.

Cooperative Code Review

Analyze the complete change first, then help the user review it one readable chunk at a time. Compose the existing review workflows instead of duplicating their specialist guidance.

Resolve the review scope

@Turbo87
Turbo87 / a-mir-formality.txt
Created April 9, 2026 12:31
zizmor audit results for rust-lang org (auditor persona)
🔴 excessive-permissions: overly broad permissions
severity: High, confidence: High
--> .github/workflows/mdbook.yml:18
| pages: write
= pages: write is overly broad at the workflow level
docs: https://docs.zizmor.sh/audits/#excessive-permissions
🔴 excessive-permissions: overly broad permissions
severity: High, confidence: High
--> .github/workflows/mdbook.yml:19

crates.io Frontend Framework Evaluation

Context

The crates.io frontend is currently built with Ember.js. We're evaluating alternatives due to:

  • Difficulty finding contributors: Ember's declining mindshare makes it hard to attract help
  • Bundle size: Current JS payload is larger than ideal
  • Ecosystem decline: Fewer packages, less community activity, uncertain long-term future
CREATE OR REPLACE FUNCTION semver_ord(num varchar) RETURNS jsonb AS $$
DECLARE
max_prerelease_parts constant int := 30;
match_result text[] := regexp_match(num, '^(\d+).(\d+).(\d+)(?:-([0-9A-Za-z\-.]+))?');
prerelease jsonb;
prerelease_part text;
i int := 0;
BEGIN
IF match_result[4] IS NULL THEN
-- A JSONB object has higher precedence than an array and versions without
@Turbo87
Turbo87 / query.sql
Created February 15, 2024 10:23
crates.io database bloat
-- from https://github.com/ioguix/pgsql-bloat-estimation/blob/8fde3c9e0e015ece51e10c1450228d23f7747db1/table/table_bloat.sql
SELECT tblname, bs*tblpages AS real_size,
(tblpages-est_tblpages)*bs AS extra_size,
CASE WHEN tblpages > 0 AND tblpages - est_tblpages > 0
THEN 100 * (tblpages - est_tblpages)/tblpages::float
ELSE 0
END AS extra_pct, fillfactor,
CASE WHEN tblpages - est_tblpages_ff > 0
THEN (tblpages-est_tblpages_ff)*bs
use anyhow::Context;
use chrono::NaiveDate;
use crates_io_cdn_logs::DownloadsMap;
use diesel::prelude::*;
use diesel::PgConnection;
table! {
temp_downloads (name, version, date) {
name -> Text,
version -> Text,