Skip to content

Instantly share code, notes, and snippets.

View shaal's full-sized avatar

Ofer Shaal shaal

View GitHub Profile
@shaal
shaal / statusline-command.sh
Created April 20, 2026 13:15
Claude Code statusline script
#!/bin/bash
# Read JSON input from stdin
INPUT=$(cat)
MODEL=$(echo "$INPUT" | jq -r '.model.display_name // "Claude"')
CWD=$(echo "$INPUT" | jq -r '.workspace.current_dir // .cwd')
DIR=$(basename "$CWD")
# Replace claude-code-flow with branded name
@shaal
shaal / miller-rabin.html
Last active April 16, 2026 14:05
Miller-Rabin demo (quick prime finder)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Miller-Rabin Primality Test</title>
<style>
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@300;400;600;700&family=Space+Grotesk:wght@400;600;700&display=swap');
* { margin: 0; padding: 0; box-sizing: border-box; }
@shaal
shaal / .CLAUDE.MD
Created October 30, 2025 14:09
combined claude-flow + agentic-qe

Claude Code Configuration - SPARC Development Environment & Agentic QE Fleet

🚨 CRITICAL: CONCURRENT EXECUTION & FILE MANAGEMENT

ABSOLUTE RULES:

  1. ALL operations MUST be concurrent/parallel in a single message
  2. NEVER save working files, text/mds and tests to the root folder
  3. ALWAYS organize files in appropriate subdirectories
  4. USE CLAUDE CODE'S TASK TOOL for spawning agents concurrently, not just MCP
@shaal
shaal / cursor.sh
Created July 11, 2024 14:34 — forked from ddwang/cursor.sh
Replace `/mnt/c/Users/<USER_NAME>/AppData/Local/Programs/cursor/resources/app/bin/cursor`
#!/usr/bin/env sh
#
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
if [ "$VSCODE_WSL_DEBUG_INFO" = true ]; then
set -x
fi
COMMIT="abd2f3db4bdb28f9e95536dfa84d8479f1eb312d"
APP_NAME="code"

Cleanup Instructions

Follow these instructions to clean up this file.

Your Role

You are an expert developer who has been hired to clean up this code.

Functions

@shaal
shaal / highlight-custom-element-in-console.es6.js
Created January 6, 2023 20:05
toggle outline styles on all custom elements (without shadow-dom scan)
// Get all elements
const elements = document.querySelectorAll('*')
// Create an array from elements
const elementArray = Array.from(elements)
// Map to node names
const nodeNames = elementArray.map(element => element.nodeName.toLowerCase())
// Filter by which ones are registered
@shaal
shaal / drupalpod--ddev-debug-test
Created April 9, 2022 23:11
`ddev debug test` in DrupalPod
Running bash [-c /tmp/test_ddev.sh]
OS Information: Linux shaal-drupalpod-v9ck724xx1q 5.16.19-051619-generic #202204081339 SMP PREEMPT Fri Apr 8 14:06:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
User information: uid=33333(gitpod) gid=33333(gitpod) groups=33333(gitpod)
DDEV version: ITEM VALUE
DDEV version v1.19.1
architecture amd64
db drud/ddev-dbserver-mariadb-10.3:v1.19.0
dba phpmyadmin:5
ddev-ssh-agent drud/ddev-ssh-agent:v1.19.0
docker 20.10.12
OS Information: Linux ws-dd0b0b4e-8614-4775-97ab-f8d3625deb26 5.4.0-1046-gke #48-Ubuntu SMP Thu Jun 17 19:16:06 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
ITEM VALUE
DDEV version v1.18.0-rc1
architecture amd64
db drud/ddev-dbserver-mariadb-10.3:20210729_cspitzlay_mysql_history
dba phpmyadmin:5
ddev-ssh-agent drud/ddev-ssh-agent:v1.17.0
docker 19.03.15
docker-compose 1.29.2
mutagen 0.12.0-beta5
version: '3.6'
#ddev-generated
services:
db:
container_name: ddev-${DDEV_SITENAME}-db
build:
context: './db-build'
dockerfile: '../.dbimageBuild/Dockerfile'
args: