monitors=$(polybar --list-monitors | cut -f 1 -d':' | tr '\n' ' ') monitors=($monitors) MONITOR=''${monitors[$1]} polybar -c /home/main/dotfiles/home-manager/modules/xmonad/polybar.ini top