refactor: dry duplicated code for getting tmux status-left
This commit is contained in:
parent
28eed454f7
commit
dd1c215631
10 changed files with 17 additions and 10 deletions
|
@ -33,7 +33,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=colour241,fg=colour248] #S #[bg=colour237,fg=colour241,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -34,7 +34,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=colour241,fg=colour248] #S #[bg=colour237,fg=colour241,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -33,7 +33,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=#665c54,fg=#bdae93] #S #[bg=#3c3836,fg=#665c54,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -34,7 +34,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=#665c54,fg=#bdae93] #S #[bg=#3c3836,fg=#665c54,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -33,7 +33,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=colour239,fg=colour223] #S #[bg=colour250,fg=colour239,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$()
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -34,7 +34,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=colour239,fg=colour223] #S #[bg=colour250,fg=colour239,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -33,7 +33,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=#bdae93,fg=#665c54] #S #[bg=#ebdbb2,fg=#bdae93,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -34,7 +34,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=#bdae93,fg=#665c54] #S #[bg=#ebdbb2,fg=#bdae93,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
|
@ -36,7 +36,7 @@ EOF
|
|||
|
||||
# check if left side match
|
||||
_status_left_expected="#[bg=colour241,fg=colour248] #S #[bg=colour237,fg=colour241,nobold,noitalics,nounderscore]"
|
||||
_status_left_current=$(tmux show-option -gqv status-left)
|
||||
_status_left_current=$(tmux_get_statusleft)
|
||||
if [[ "$_status_left_current" != "$_status_left_expected" ]]; then
|
||||
helper_print_fail "status-left did not match" "$_status_left_current" "$_status_left_expected"
|
||||
helper_teardown
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue