#!/usr/bin/env zsh local text="$(maim -k -s -f png | tesseract stdin stdout -l eng 2>/dev/null)" let char_count="$(printf '%s' "${text}" | wc -c)" printf '%s' "${text}" | xclip -selection clipboard notify-send -t 5000 "Coppied Text" "Coppied ${char_count} characters"