Merge master into stdout2 as we need some changes from master.

This commit is contained in:
Dylan 2016-02-06 10:27:16 +11:00
commit e3fc21fd5f
3 changed files with 19 additions and 8 deletions

1
1.1.md
View File

@ -71,6 +71,7 @@ the distro ascii art and the automatic config creation.
### Info
- You can now display info without a subtitle. eg. `info memory`
- Added `--disable` which allows you to stop an info line from appearing at launch.<br \>
```sh

View File

@ -196,6 +196,10 @@ line_wrap="on"
# --bold on/off
bold="on"
# Enable/Disable Underline
# --underline on/off
underline="on"
# Underline character
# --underline_char char
underline_char="-"

16
fetch
View File

@ -216,6 +216,10 @@ line_wrap="on"
# --bold on/off
bold="on"
# Enable/Disable Underline
# --underline on/off
underline="on"
# Underline character
# --underline_char char
underline_char="-"
@ -1259,7 +1263,7 @@ getbattery () {
battery=${battery/EstimatedChargeRemaining'='}
battery=${battery//[[:space:]]/ }
battery=${battery// }
battery+="${battery}%"
battery+="%"
;;
esac
}
@ -1805,10 +1809,6 @@ info () {
string="${underline_color}${output}"
;;
linebreak | cols)
string=""
;;
*)
string="${bold}${subtitle_color}${subtitle}${clear}"
string+="${colon_color}: ${info_color}${output}"
@ -1894,8 +1894,13 @@ stdout () {
# Underline {{{
getunderline () {
case "$underline" in
"on")
underline=$(printf %"$length"s)
underline=${underline// /$underline_char}
;;
"off") underline="" ;;
esac
}
# }}}
@ -2154,6 +2159,7 @@ while [ "$1" ]; do
--info_color) info_color=$2 ;;
# Text Formatting
--underline) underline="$2" ;;
--underline_char) underline_char="$2" ;;
--line_wrap) line_wrap="$2" ;;
--bold) bold="$2" ;;