Merge pull request #37 from ImperadorSid/coherent-design

Coherent spacing
This commit is contained in:
Dane Williams 2020-05-30 16:37:45 -07:00 committed by GitHub
commit 2e7b5476a1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 7 deletions

View file

@ -35,7 +35,8 @@ battery_percent()
# Check OS # Check OS
case $(uname -s) in case $(uname -s) in
Linux) Linux)
linux_acpi percent percent=$(linux_acpi percent)
[ -n "$percent" ] && echo " $percent"
;; ;;
Darwin) Darwin)
@ -74,7 +75,7 @@ battery_status()
if [ $status = 'discharging' ] || [ $status = 'Discharging' ]; then if [ $status = 'discharging' ] || [ $status = 'Discharging' ]; then
echo '' echo ''
else else
echo 'AC ' echo 'AC'
fi fi
} }

View file

@ -99,17 +99,17 @@ main()
powerbg=${gray} powerbg=${gray}
if $show_battery; then # battery if $show_battery; then # battery
tmux set-option -g status-right "#[fg=${pink},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${pink}] #($current_dir/battery.sh) " tmux set-option -g status-right "#[fg=${pink},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${pink}] #($current_dir/battery.sh)"
powerbg=${pink} powerbg=${pink}
fi fi
if $show_network; then # network if $show_network; then # network
tmux set-option -ga status-right "#[fg=${cyan},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${cyan}]#($current_dir/network.sh) " tmux set-option -ga status-right "#[fg=${cyan},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${cyan}] #($current_dir/network.sh)"
powerbg=${cyan} powerbg=${cyan}
fi fi
if $show_weather; then # weather if $show_weather; then # weather
tmux set-option -ga status-right "#[fg=${orange},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${orange}] #(cat $current_dir/../data/weather.txt)" tmux set-option -ga status-right "#[fg=${orange},bg=${powerbg},nobold,nounderscore,noitalics] ${right_sep}#[fg=${dark_gray},bg=${orange}] #(cat $current_dir/../data/weather.txt)"
powerbg=${orange} powerbg=${orange}
fi fi

View file

@ -58,7 +58,7 @@ forecast_unicode()
display_weather() display_weather()
{ {
if [ $country = 'US' ]; then if [ $country = 'US' ]; then
echo "$(forecast_unicode)$(get_temp)°" echo "$(forecast_unicode)$(get_temp)° "
else else
echo '' echo ''
fi fi
@ -75,7 +75,7 @@ main()
fi fi
# process should be cancelled when session is killed # process should be cancelled when session is killed
if ping -q -c 1 -W 1 ipinfo.io &>/dev/null; then if ping -q -c 1 -W 1 ipinfo.io &>/dev/null; then
echo "$(display_weather) $city, $(get_region_code)" echo "$(display_weather)$city, $(get_region_code)"
else else
echo "Location Unavailable" echo "Location Unavailable"
fi fi