Skip to content

Instantly share code, notes, and snippets.

View zeroows's full-sized avatar
🥰
Rust

Abdulrhman Alkhodiry zeroows

🥰
Rust
View GitHub Profile
@zeroows
zeroows / start-hive.sh
Last active February 18, 2026 17:36
A self-bootstrapping shell script that sets up and launches a [claude-flow] hive-mind team with Claude Code.
#!/usr/bin/env bash
##############################################################################
# Project — AiDevSquad Hive-Mind Launcher
#
# Reads the hive manifest and starts Claude Code with the team already spinning.
# Check the gist https://gist.github.com/zeroows/5b86f7a38735e4719929c0e7cbbe763b
# Usage:
# ./start-hive.sh # Start hive (interactive)
# ./start-hive.sh "add pushback notification domain" # Start hive with a task
# ./start-hive.sh --resume # Resume last session
@zeroows
zeroows / rust-aarch64-musl-cross-compile.md
Created February 16, 2026 16:30 — forked from aalkhodiry/rust-aarch64-musl-cross-compile.md
Cross-Compiling Rust for aarch64-unknown-linux-musl on GitHub Actions (with vendored OpenSSL + ring)

Cross-Compiling Rust for aarch64-unknown-linux-musl on GitHub Actions

With vendored OpenSSL + ring (rustls) -- a complete working guide.

The Problem

Cross-compiling Rust projects targeting aarch64-unknown-linux-musl on x86_64 GitHub Actions runners fails when:

  1. Using gcc-aarch64-linux-gnu (glibc cross-compiler) with musl target -- vendored OpenSSL gets compiled against glibc headers, introducing symbols like __memcpy_chk, __memset_chk, __vfprintf_chk that don't exist in musl.
@zeroows
zeroows / defered.rs
Created November 14, 2024 22:42
Rust defer
struct Deferred<T: FnOnce()> {
task: Option<T>,
}
impl<T: FnOnce()> Deferred<T> {
fn abort(&mut self) {
self.task.take();
}
}
@zeroows
zeroows / unsubmodule.md
Created September 3, 2023 09:08 — forked from ryaninvents/unsubmodule.md
Convert git submodule to regular directory

From Stack Overflow.

# Fetch the submodule commits into the main repository
git remote add submodule_origin git://url/to/submodule/origin
git fetch submodule_origin

# Start a fake merge (won't change any files, won't commit anything)
git merge -s ours --no-commit submodule_origin/master
@zeroows
zeroows / Dockerfile
Created June 12, 2023 14:58
Dockerfile for firebase admin tools
FROM ubuntu:latest
WORKDIR /app
COPY gcloud_configs/config_firebase_adminsdk_file.json .
RUN apt update 2>/dev/null && apt install curl -y
RUN curl -o firebase -L --progress-bar https://firebase.tools/bin/linux/latest
RUN chmod +rx firebase
from flask import Flask, jsonify, request
from waitress import serve
import logging
logger = logging.getLogger('waitress')
logger.setLevel(logging.INFO)
app = Flask(__name__)
@zeroows
zeroows / iban.py
Created October 31, 2021 12:07
IBAN Generator from Account number for Saudi Arabia Banks
import string
CHARS = {c: str(ord(c) % 55) for c in string.ascii_uppercase}
BANK = {
'Al Bilad Bank': '15',
'Al Inma Bank': '05',
'Al Jazira Bank': '60',
'Al Rajhi Bank': '80',
'Alawwal Bank': '50',
@zeroows
zeroows / firestore.rules
Last active March 30, 2020 20:57
Firestore Rules Example in Google Console
rules_version = '2';
service cloud.firestore {
match /databases/{database}/documents {
match /shoppinglist/{lists} {
function isSignedIn() {
return request.auth != null;
}
function isEmailVerified() {
return request.auth.token.email_verified != false;
}
@zeroows
zeroows / pytorch_losses_functions.ipynb
Created February 6, 2020 08:01
Some Pytorch losses examples
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@zeroows
zeroows / pytorch-losses-in-plain-python.ipynb
Created February 6, 2020 07:58 — forked from yang-zhang/pytorch-losses-in-plain-python.ipynb
git/yang-zhang.github.io/ds_code/pytorch-losses-in-plain-python.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.