Use -theme for rofi commands
This commit is contained in:
parent
4093c0345b
commit
0c151e6d2c
6
qb
6
qb
|
@ -42,10 +42,6 @@ define_vars() { # {{{
|
||||||
## List of process pattern to monitor
|
## List of process pattern to monitor
|
||||||
qutebrowser_proc_pattern="(qutebrowser)"
|
qutebrowser_proc_pattern="(qutebrowser)"
|
||||||
|
|
||||||
## Rofi colors
|
|
||||||
black="#000000"
|
|
||||||
blue="#0094cc"
|
|
||||||
|
|
||||||
## Store selected content to a temp file
|
## Store selected content to a temp file
|
||||||
choice_temp_file="$(mktemp -t ${PROGNAME}-XXXXXX.tmp)"
|
choice_temp_file="$(mktemp -t ${PROGNAME}-XXXXXX.tmp)"
|
||||||
|
|
||||||
|
@ -223,7 +219,7 @@ goto_qutebrowser_content() { # {{{
|
||||||
debug_message "goto_qutebrowser_content − \
|
debug_message "goto_qutebrowser_content − \
|
||||||
Search in Qutebrowser's content ${QUTEBROWSER_GLOBAL_CONTENT} file."
|
Search in Qutebrowser's content ${QUTEBROWSER_GLOBAL_CONTENT} file."
|
||||||
|
|
||||||
rofi -dmenu -location 6 -lines 15 -width 80 -p 'Qutebrowser' -color-enabled -color-normal "${black},${blue},${black},${blue},${black}" -color-window "${black},${black}" > "${choice_temp_file}" < "${QUTEBROWSER_GLOBAL_CONTENT}"
|
rofi -theme solarized_alternate -dmenu -location 6 -lines 15 -width 80 -p 'Qutebrowser' > "${choice_temp_file}" < "${QUTEBROWSER_GLOBAL_CONTENT}"
|
||||||
|
|
||||||
if [ -s "${choice_temp_file}" ]; then
|
if [ -s "${choice_temp_file}" ]; then
|
||||||
debug_message "goto_qutebrowser_content − \
|
debug_message "goto_qutebrowser_content − \
|
||||||
|
|
|
@ -13,9 +13,6 @@ readonly NBARGS="${#}"
|
||||||
## Current tasks temp file
|
## Current tasks temp file
|
||||||
readonly TASKW_CURRENT_LIST="/tmp/rofi-task.sh-current.tasks"
|
readonly TASKW_CURRENT_LIST="/tmp/rofi-task.sh-current.tasks"
|
||||||
|
|
||||||
## Rofi colors
|
|
||||||
black="#000000"
|
|
||||||
blue="#0094cc"
|
|
||||||
# }}}
|
# }}}
|
||||||
usage() { # {{{
|
usage() { # {{{
|
||||||
|
|
||||||
|
@ -84,7 +81,7 @@ display_current_task() { # {{{
|
||||||
task +ACTIVE export | jq -r 'sort_by( -.urgency )[] | [ (.id|tostring), .description ] | join(" ")' >> "${TASKW_CURRENT_LIST}"
|
task +ACTIVE export | jq -r 'sort_by( -.urgency )[] | [ (.id|tostring), .description ] | join(" ")' >> "${TASKW_CURRENT_LIST}"
|
||||||
|
|
||||||
## Display active tasks list and get title from the choosen one
|
## Display active tasks list and get title from the choosen one
|
||||||
TITLE=$(rofi -location 2 -lines 5 -no-auto-select -i -dmenu -p "RUNNING task(s)" -color-enabled -color-normal "${blue},${black},${blue},${black},${blue}" -color-window "${blue},${blue}" < "${TASKW_CURRENT_LIST}" |
|
TITLE=$(rofi -theme solarized_alternate -location 2 -lines 5 -no-auto-select -i -dmenu -p "RUNNING task(s)" < "${TASKW_CURRENT_LIST}" |
|
||||||
cut --delimiter=" " --field=2 |
|
cut --delimiter=" " --field=2 |
|
||||||
sed "s/[0-9]//g")
|
sed "s/[0-9]//g")
|
||||||
ID=$(task "${TITLE}" simpleid | grep --after-context=2 -- ID | tail --lines=1 || return 0)
|
ID=$(task "${TITLE}" simpleid | grep --after-context=2 -- ID | tail --lines=1 || return 0)
|
||||||
|
@ -127,7 +124,7 @@ ID var: ${RED}${ID}${RESET}."
|
||||||
select_task() { # {{{
|
select_task() { # {{{
|
||||||
## Display pending tasks list and get title from the choosen one
|
## Display pending tasks list and get title from the choosen one
|
||||||
TITLE=$(task status:pending export | jq -r 'sort_by( -.urgency )[] | [ (.id|tostring), .description ] | join(" ")' | sort --numeric-sort --reverse |
|
TITLE=$(task status:pending export | jq -r 'sort_by( -.urgency )[] | [ (.id|tostring), .description ] | join(" ")' | sort --numeric-sort --reverse |
|
||||||
rofi -location 2 -no-auto-select -i -dmenu -p "Task" -color-enabled -color-normal "${black},${blue},${black},${blue},${black}" -color-window "${black},${black}" |
|
rofi -theme solarized_alternate -location 2 -no-auto-select -i -dmenu -p "Task" |
|
||||||
cut --delimiter=" " --field=2)
|
cut --delimiter=" " --field=2)
|
||||||
|
|
||||||
[ -z "${TITLE}" ] && echo "Cancelled." && exit 0
|
[ -z "${TITLE}" ] && echo "Cancelled." && exit 0
|
||||||
|
|
Loading…
Reference in New Issue