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 / 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 / 2026-03-05_08-41-57_nvim-init-lua-changes.md
Last active March 10, 2026 09:08
Neovim init.lua changes — 2026-03-05

Neovim init.lua changes — 2026-03-05

Neovim init.lua Changes — 2026-03-05

All changes made to ~/.config/nvim/init.lua during this session.

Colorscheme

Replaced folke/tokyonight.nvim (tokyonight-night) with RRethy/base16-nvim (base16-one-light — subdued light theme based on Atom One Light).

@al-maisan
al-maisan / 2026-03-01_14-07-26_tftc-michael-howell-liquidity-summary.md
Created March 1, 2026 12:48
TFTC Podcast Summary: Michael Howell on Global Liquidity, Bitcoin, and the Debt Maturity Wall

TFTC Podcast: Global Liquidity, Bitcoin, and the Debt Maturity Wall

Participants

  • Marty Bent -- Host, TFTC podcast
  • Michael Howell -- Founder of CrossBorder Capital (35+ years tracking global liquidity), author of the Capital Wars Substack, creator of the Global Liquidity Index (GLI)

Core Thesis

Global liquidity has peaked at $188.8 trillion (all-time high) but the momentum/growth rate is now declining. The liquidity cycle oscillates with a ~5-6 year frequency; after a 3+ year upswing, a multi-year downswing is likely beginning. This has direct implications for risk assets, especially Bitcoin.

Key Points

@al-maisan
al-maisan / .vimrc
Created February 27, 2026 09:18
.vimrc
" A sensible vimrc for Go development
"
" Please note that the following settings are some default that I used
" for years. However it might be not the case for you (and your
" environment). I highly encourage to change/adapt the vimrc to your own
" needs. Think of a vimrc as a garden that needs to be maintained and fostered
" throughout years. Keep it clean and useful - Fatih Arslan
call plug#begin()
Plug 'fatih/vim-go'
@al-maisan
al-maisan / 2026-02-27_12-01-56_code-analysis-bug-report.md
Created February 27, 2026 09:04
2026-02-27_12-01-56_code-analysis-bug-report.md

Code Analysis Bug Report

CRITICAL — Logic Bugs That Produce Wrong Results

1. get_random_daily() includes instead of excludes

File: src/mission/mod.rs:88

if m.is_daily() && name_set.contains(m.get_name()) {