diff options
author | Rasmus Steinke <rasi@xssn.at> | 2016-01-03 15:32:43 +0100 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2016-01-03 15:32:43 +0100 |
commit | 79a7dc91f8c905b49c39994314dbd411b3203bc5 (patch) | |
tree | 7ab5b8677a0b57474b2aeb0854829cbcbda95b27 /clerk | |
parent | 6032e265d452548686bdb51009f7e6b90afa130b (diff) | |
download | perl-app-clerk-79a7dc91f8c905b49c39994314dbd411b3203bc5.tar.gz perl-app-clerk-79a7dc91f8c905b49c39994314dbd411b3203bc5.tar.xz |
reuse dmenu_t command for color detection
Diffstat (limited to 'clerk')
-rwxr-xr-x | clerk | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -2,6 +2,10 @@ shopt -s globstar +function dmenu_t () { + rofi -dmenu $(echo "$rofiopts") "$@" +} + # load default settings # custom rofi settings (rofi reads settings from ~/.Xresources) # but you can override settings here. @@ -116,8 +120,8 @@ fi # set help color if [[ $help_color == "" ]]; then - help_color=$(rofi -dump-xresources | grep 'rofi.color.normal' | awk -F ', ' '{ print $2 }') - help_separator_color=$(rofi -dump-xresources | grep 'rofi.color.normal' | awk -F ', ' '{ print $2 }') + help_color=$(dmenu_t -dump-xresources | grep -P '^rofi.color.normal' | awk -F ',' '{ print $2 }') + help_separator_color=$(dmenu_t -dump-xresources | grep -P 'rofi.color.normal' | awk -F ',' '{ print $2 }') fi fix_date_format() { @@ -1879,9 +1883,6 @@ getAlbumsFromPlaylist () { ################################################################################ -function dmenu_t () { - rofi -dmenu $(echo "$rofiopts") "$@" -} while :; do case $1 in |