testsAndMisc/linux_configuration/zsh/scratchpad/.zshrc
Krzysztof kuhy Rudnicki 2e1e370c0f refactor: extract all inline Python from shell scripts into proper .py files
Move every multi-line python heredoc/`-c` block into a dedicated .py file so
ruff, mypy, pylint, bandit, and pytest can apply to it:
- linux_configuration/zsh/calc-live.zsh → python_pkg/live_calc/calc_eval.py (100% branch cov, 46 tests)
- meta/scripts/check_ai_evidence.sh → meta/scripts/validate_evidence.py
- meta/scripts/check_agent_contract.sh → meta/scripts/validate_contract.py
- phone_focus_mode/lib/monitor.sh → phone_focus_mode/lib/monitor_report.py
- phone_focus_mode/deploy.sh → phone_focus_mode/strip_workout_hosts.py
- linux_configuration/.../analyze_repo.sh → fast_count.py

Also: add zsh-syntax pre-commit hook (zsh -n); exclude zsh from shellcheck;
add tests for all 4 non-python_pkg helpers; update CLAUDE.md Shell Style with
the no-inline-Python rule.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-06 10:31:48 +02:00

16 lines
663 B
Bash
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Minimal rc for the floating scratchpad calculator (i3: Mod+c).
#
# Deliberately tiny: it loads ONLY the live-calc widget, so the popup starts
# instantly instead of paying for the full ~/.zshrc (oh-my-zsh, pyenv, conda,
# nvm). ZDOTDIR points here, so this is the only rc that runs.
PROMPT='%F{cyan}calc %f '
RPROMPT=''
autoload -Uz colors 2>/dev/null && colors 2>/dev/null
# Load the widget from the repo (one level up), independent of the oh-my-zsh
# symlink, so the scratchpad works even if oh-my-zsh is not installed.
source "${ZDOTDIR}/../calc-live.zsh"
print -P '%F{242}Live calculator — type math, see the result as you type. Ctrl-D to close.%f'