Remove prompr_height
This commit is contained in:
parent
c6c0b78d04
commit
6f8dc8ad64
2 changed files with 31 additions and 45 deletions
|
@ -223,12 +223,6 @@ underline_enabled="on"
|
||||||
# --underline_char char
|
# --underline_char char
|
||||||
underline_char="-"
|
underline_char="-"
|
||||||
|
|
||||||
# Prompt height
|
|
||||||
# You should only have to change this if your
|
|
||||||
# prompt is greater than 2 lines high.
|
|
||||||
# --prompt_height num
|
|
||||||
prompt_height=1
|
|
||||||
|
|
||||||
|
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
|
70
neofetch
70
neofetch
|
@ -42,38 +42,38 @@ export LANG=C
|
||||||
# See this wiki page for more info:
|
# See this wiki page for more info:
|
||||||
# https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
|
# https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
|
||||||
printinfo () {
|
printinfo () {
|
||||||
info title
|
# info title
|
||||||
info underline
|
# info underline
|
||||||
|
|
||||||
info "OS" distro
|
# info "OS" distro
|
||||||
info "Kernel" kernel
|
# info "Kernel" kernel
|
||||||
info "Uptime" uptime
|
# info "Uptime" uptime
|
||||||
info "Packages" packages
|
# info "Packages" packages
|
||||||
info "Shell" shell
|
# info "Shell" shell
|
||||||
info "Resolution" resolution
|
# info "Resolution" resolution
|
||||||
info "DE" de
|
# info "DE" de
|
||||||
info "WM" wm
|
# info "WM" wm
|
||||||
info "WM Theme" wmtheme
|
# info "WM Theme" wmtheme
|
||||||
info "Theme" theme
|
# info "Theme" theme
|
||||||
info "Icons" icons
|
# info "Icons" icons
|
||||||
info "Terminal" term
|
# info "Terminal" term
|
||||||
info "Terminal Font" termfont
|
# info "Terminal Font" termfont
|
||||||
info "CPU" cpu
|
# info "CPU" cpu
|
||||||
info "GPU" gpu
|
# info "GPU" gpu
|
||||||
info "Memory" memory
|
# info "Memory" memory
|
||||||
|
|
||||||
# info "Disk" disk
|
# # info "Disk" disk
|
||||||
# info "Battery" battery
|
# # info "Battery" battery
|
||||||
# info "Font" font
|
# # info "Font" font
|
||||||
# info "Song" song
|
# # info "Song" song
|
||||||
# info "Local IP" localip
|
# # info "Local IP" localip
|
||||||
# info "Public IP" publicip
|
# # info "Public IP" publicip
|
||||||
# info "Users" users
|
# # info "Users" users
|
||||||
# info "Birthday" birthday
|
# # info "Birthday" birthday
|
||||||
|
|
||||||
info linebreak
|
# info linebreak
|
||||||
info cols
|
# info cols
|
||||||
info linebreak
|
# info linebreak
|
||||||
info linebreak
|
info linebreak
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -248,12 +248,6 @@ underline_enabled="on"
|
||||||
# --underline_char char
|
# --underline_char char
|
||||||
underline_char="-"
|
underline_char="-"
|
||||||
|
|
||||||
# Prompt height
|
|
||||||
# You should only have to change this if your
|
|
||||||
# prompt is greater than 2 lines high.
|
|
||||||
# --prompt_height num
|
|
||||||
prompt_height=1
|
|
||||||
|
|
||||||
|
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
@ -2991,8 +2985,6 @@ usage () { cat << EOF
|
||||||
--underline_char char Character to use when underlining title
|
--underline_char char Character to use when underlining title
|
||||||
--line_wrap on/off Enable/Disable line wrapping
|
--line_wrap on/off Enable/Disable line wrapping
|
||||||
--bold on/off Enable/Disable bold text
|
--bold on/off Enable/Disable bold text
|
||||||
--prompt_height num Set this to your prompt height to fix issues with
|
|
||||||
the text going off screen at the top
|
|
||||||
|
|
||||||
|
|
||||||
Color Blocks:
|
Color Blocks:
|
||||||
|
@ -3139,7 +3131,6 @@ while [ "$1" ]; do
|
||||||
--underline_char) underline_char="$2" ;;
|
--underline_char) underline_char="$2" ;;
|
||||||
--line_wrap) line_wrap="$2" ;;
|
--line_wrap) line_wrap="$2" ;;
|
||||||
--bold) bold="$2" ;;
|
--bold) bold="$2" ;;
|
||||||
--prompt_height) prompt_height="$2" ;;
|
|
||||||
|
|
||||||
# Color Blocks
|
# Color Blocks
|
||||||
--color_blocks) color_blocks="$2" ;;
|
--color_blocks) color_blocks="$2" ;;
|
||||||
|
@ -3352,11 +3343,12 @@ printinfo
|
||||||
if [ "$image" != "off" ]; then
|
if [ "$image" != "off" ]; then
|
||||||
# Get cursor position
|
# Get cursor position
|
||||||
info_height="$(stty -echo; IFS=';' read -rdR -t 1 -d c -p $'\033[6n\033[c' ROW COL; printf "%s" "${ROW#*[}"; stty echo)"
|
info_height="$(stty -echo; IFS=';' read -rdR -t 1 -d c -p $'\033[6n\033[c' ROW COL; printf "%s" "${ROW#*[}"; stty echo)"
|
||||||
|
lines="$((${width:-1} / ${font_width:-1} / 2 + 3))"
|
||||||
|
|
||||||
# Set cursor position dynamically based on height of ascii/text.
|
# Set cursor position dynamically based on height of ascii/text.
|
||||||
[ "${lines:-0}" -lt "${info_height:-0}" ] && lines="$info_height"
|
[ "${lines:-0}" -lt "${info_height:-0}" ] && lines="$info_height"
|
||||||
|
|
||||||
printf "%b%s" "\033[${lines}H\033[${prompt_height}A"
|
printf "%b%s" "\033[${lines}H"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Re-enable line wrap
|
# Re-enable line wrap
|
||||||
|
|
Loading…
Reference in a new issue