From b29ed0b265683702646eb209eafcc9a92b317b3b Mon Sep 17 00:00:00 2001 From: Joe Date: Fri, 27 Dec 2024 14:41:35 +0100 Subject: up --- .local/bin/dmsearch | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to '.local/bin/dmsearch') diff --git a/.local/bin/dmsearch b/.local/bin/dmsearch index 22ad2d7..9e76bbd 100755 --- a/.local/bin/dmsearch +++ b/.local/bin/dmsearch @@ -6,7 +6,7 @@ use Sys::Hostname; use constant { BROWSER => '/bin/firefox', - HOSTNAME => (split /\./, hostname()) + HOSTNAME => (split /\./, hostname())[0] }; sub main @@ -15,12 +15,17 @@ sub main my $url; my $pid; my $prefix; + my $color; + $color = '#cc241d'; + if (@ARGV == 1) { + $color = $ARGV[0]; + } $prefix = '/usr'; if (HOSTNAME eq "mars") { $prefix += '/local'; } - $choice = `printf "" | dmenu -i -p 'search:'`; + $choice = `printf "" | dmenu -i -p 'search:' -sb '$color' -shb '$color'`; if (not $choice) { return; } -- cgit v1.2.3