Skip to content

Instantly share code, notes, and snippets.

View al-maisan's full-sized avatar

Muharem Hrnjadovic al-maisan

View GitHub Profile
@al-maisan
al-maisan / gpg-key-signing-guide.md
Created March 18, 2026 14:57
key signing procedure for next lunch

GPG Key Exchange & Signing — In-Person with Signal

A step-by-step guide for three people meeting in person who already have verified Signal chats with each other.

Overview

The goal is to verify each other's GPG public key fingerprints in person, then sign each other's keys to build a web of trust. Signal provides a second authenticated channel for exchanging data before and after the meeting.

@al-maisan
al-maisan / init.lua
Last active March 19, 2026 08:48
Neovim init.lua (kickstart-based)
--[[
=====================================================================
==================== READ THIS BEFORE CONTINUING ====================
=====================================================================
======== .-----. ========
======== .----------------------. | === | ========
======== |.-""""""""""""""""""-.| |-----| ========
======== || || | === | ========
======== || KICKSTART.NVIM || |-----| ========
@al-maisan
al-maisan / metric_axima_red_flags_green_flags.md
Created March 15, 2026 05:05
Metric / Axima Labs — Green Flags / Red Flags

Metric / Axima Labs — Green Flags / Red Flags

Green flags

1. The startup thesis is coherent
This is not random crypto buzzwording. Their argument is internally consistent: for many major assets and tokenized assets, price is formed off-chain, so an AMM that assumes on-chain pools should do price discovery is structurally inefficient. That is a serious mechanism-design point, not fluff.

2. They may have operator experience rather than purely academic ideas
The strongest claim in the CTO brief is that they previously ran profitable HFT / arbitrage / market-making strategies and at times supplied a meaningful share of Aerodrome liquidity. If true, that would matter a lot, because real AMM pain is usually best understood by people who have actually traded against it.

@al-maisan
al-maisan / btc-structural-ownership-critique.md
Created March 13, 2026 14:39
btc-structural-ownership-critique.md

Bitcoin Structural & Ownership Critique: Deep Dive

A detailed examination of the concentration and structural risks in Bitcoin's ownership, custody, mining, and market infrastructure -- the strongest thread from the broader "Saylor kills BTC" argument.

1. The Ownership Map: Who Controls Bitcoin?

1.1 Supply Breakdown (as of Mar 2026)

Category BTC % of 21M cap % of mined (~19.8M) Notes
@al-maisan
al-maisan / sovereign-btc-investments.md
Created March 13, 2026 09:29
sovereign-btc-investments.md

Sovereign Bitcoin Investments (Mar 2025 -- Mar 2026)

Direct Holdings / Purchases

Entity Action BTC / Value Notes
United States Strategic Bitcoin Reserve (exec order Mar 2025) ~328,372 BTC Seeded from forfeiture assets; BITCOIN Act proposes Treasury buy up to 1M BTC
El Salvador Continued daily purchases 7,560 BTC ($504M) Buying 1 BTC/day since 2021; portfolio peaked ~$800M in Oct 2025
Bhutan Mining-based accumulation, partial sells 5,600 BTC ($381M) Druk Holding & Investments; sold ~$42M in early 2026
Czech National Bank First-ever central bank BTC purchase (Oct 2025) $1M test portfolio Pilot to evaluate BTC as reserve diversification; results in 2-3 years
@al-maisan
al-maisan / utoipa-proposal.md
Last active March 9, 2026 05:31
future api dev approach

Proposal: API Documentation with utoipa (Hybrid Approach)

Date: 2026-03-09

Problem

The backend API has 46 endpoints with no machine-readable documentation. API behavior is defined implicitly by Rust code. This means:

  • Frontend developers must read backend source or ask questions to understand request/response formats
  • No interactive way to test endpoints during development
@al-maisan
al-maisan / complexity-assessment.md
Created March 6, 2026 13:44
complexity-assessment.md

Complexity Assessment & Refactoring Recommendations

Date: 2026-03-06

Methodology

Three tools were used to triangulate complexity from different angles:

  • complexity crate — per-function cognitive complexity scores for every function in the codebase (based on Cognitive Complexity by G. Ann Campbell). Cognitive complexity measures how hard code is to understand, penalizing nested control flow more than flat branching.
  • clippy cognitive_complexity lint — same metric but only flags functions above a threshold, confirming the top offenders.
@al-maisan
al-maisan / complexity-report.md
Last active March 6, 2026 13:43
complexity-report.md

Codebase Complexity Report

Date: 2026-03-06

Overview (scc)

Metric Value
Total Rust files 75
Total lines 15,673

Code Analysis — Round 2

CRITICAL — Logic Bugs That Produce Wrong Results

1. Daily login reward off-by-one

File: src/mission/types/daily_login.rs:102-121

try_progress() mutates self.day (increments it) before returning. Then current_reward() does self.day.saturating_sub(1) to index into REWARDS. Result: the reward is always one day ahead. A user continuing a streak on day 1 gets the day-2 reward (10 coins instead of 5). On day 7, REWARDS[7] is out of bounds, hitting the unwrap_or_else fallback that returns REWARDS[0] (5 coins) instead of the intended 100-coin max reward.

@al-maisan
al-maisan / nvim-init-lua-changes.md
Last active March 19, 2026 08:47
Neovim init.lua changes — 2026-03-05

Neovim init.lua changes — 2026-03-05

Neovim init.lua changes

Neovim init.lua Changes

All changes made to ~/.config/nvim/init.lua.

Current file: init.lua