Skip to content

v1.5.1 – Fix recursive alias loop (SIGABRT)

Choose a tag to compare

@yvgude yvgude released this 24 Mar 14:14

Bug Fix

Fixes critical bug where lean-ctx init --global caused all git commands to hang and crash with SIGABRT (#1).

Root Cause

Shell aliases created by init --global caused infinite recursion, especially on fish shell (which always loads config.fish, even for non-interactive shells).

Changes

  • Recursion guard: Set LEAN_CTX_ACTIVE env var in subprocesses; passthrough mode when detected
  • No unnecessary tokio: CLI commands no longer spin up a tokio multi-threaded runtime (only MCP server and dashboard need async)
  • Guarded aliases: init --global now wraps aliases in LEAN_CTX_ACTIVE check for both fish (if not set -q) and bash/zsh (if [ -z ... ])

Upgrade

cargo install lean-ctx    # via cargo
brew upgrade lean-ctx     # via Homebrew (update coming shortly)

Workaround for existing installations

If you already ran init --global with v1.5.0, the binary-level fix handles recursion automatically. For optimal performance, re-run init --global after removing the old aliases from your shell config.

Closes #1