#!/bin/sh profiles=$(awk -F= '/^\[Profile/ {profile=$1} /Name/ && !/default/ {print $2}' ~/.mozilla/icecat/profiles.ini) profile=$(echo "$profiles" | mew -p "Select IceCat Profile" -l 10) if [ -z "$profile" ] || ! echo "$profiles" | rg -q "^$profile$"; then echo "Invalid selection or no profile selected. Exiting." exit 1 fi hyprctl dispatch exec "icecat -P $profile"