7

dmenu menu with spaces?

view full story
linux-howto

https://bbs.archlinux.org – I am trying to create a dmenu, that runs specific commands on each entry. but i fail to use entries with spaces.This is how i am trying to archive it, without success, i might add:#!/bin/bash prog=" test test with space " cmd=$(dmenu <<< "$prog") case ${cmd%% *} in test) notify-send "foo" ;; test with spaces) notify-send "bar" ;; *) exec "'${cmd}'" ;; esacwhat would be a better solution? Rasi https://bbs.archlinux.org/profile.php?id=12079 2013-01-12T14:38:16Z (HowTos)