dbar(1)
β¨ dbar(1) β¨
okay so bestie, welcome to the User Commands section of the manual, page dbar(1). sit down, grab a boba, we're doing progress bars today π«Ά
πΈ NAME πΈ
dbar β it's an ASCII progresbar π
(yes, that's the spelling in the source, we are not discussing it, the bar itself is iconic regardless)
π SYNOPSIS π
echo <percentage> | dbar [options] <indicator text>
literally just pipe a number in and watch the little bar go brrr β¨
π DESCRIPTION π
so here's the tea: dbar lets you define static 0% and 100% marks, or you can define those marks dynamically at runtime. and get this β static and dynamic marks can be mixed, no cap. in that case, the value you specify at runtime wins, it has higher priority, main character energy π
you can specify ranges of numbers, negative, positive, or ranges with a negative min value and a positive max value. all of it. we contain multitudes π¦
and the best part: all numbers are treated as double precision floating point, meaning the input is NOT limited to integers. decimals welcome, they're invited to the party π
β¨ OPTIONS β¨
-lβ the label to be prepended to the bar (default:""). your little name tag for the bar π-nonlβ no new line, i.e. don't put'\n'at the end of the bar (default: do print"\n"). use this when you want the bar to stay on the same line and vibe with whatever comes next π«Ά-maxβ the value to be considered 100% (default:100). the ceiling, the limit, the final boss π§-minβ the value to be considered 0% (default:0). the floor, the starting line, the "we begin" π-sβ the symbol representing the percentage value in the meter (default:"="). swap it out if=isn't your aesthetic β¨-wβ number of charcaters to be considered 100% in the meter (default:25). that's how wide the whole thing stretches, adjust to taste π
π EXAMPLES π
static 100% mark or single value input πΈ
echo 25 | dbar -max 100 -l text
Output: text 25% [====== ]
look at her go. text, then 25%, then the bar doing its little thing π
if your 100% mark changes dynamically, or 2-values input π«
echo "50 150" | dbar
| |
| |__ max value
|
|__ value to display
Output: 33% [======== ]
so you feed it two numbers, and the diagram above is literally telling you which one is which. first one = the value to display, second one = the max value. iykyk π§
if your value range is not between [0, maxval], or 3-values input π
echo "50 -25 150" | dbar
| | |
| | |__ max value 100% mark
| |
| |_____ min value 0% mark
|
|________ value to display
Output: 43% [=========== ]
three numbers, three jobs. value to display, then the min value (0% mark), then the max value (100% mark). and now your range can go negative, slay π
multiple runs π₯
for i in 2 20 50 75 80; do echo $i; sleep 1; done | dbar | dzen2
Output: Find out yourself.
ngl the manual literally said find out yourself and honestly? respect. run it, bestie, it's giving suspense π
π ENVIRONMENT π
None. nothing here. empty. the void. π
π¦ FILES π¦
None. also nothing. she's self-contained, she doesn't need files, she's low maintenance π«Ά
π SEE ALSO π
π AUTHORS π
the program itself was written by Robert Manea <rob.manea@gmail.com> β thank you for this icon, king π«‘
this manual page was written by Jari Aalto <jari.aalto@cante.net> for the Debian GNU system (but may be used by others, sharing is caring). released under license GNU GPL version 2 or (at your option) any later version. for more information about the license, visit <http://www.gnu.org/copyleft/gpl.html> π
okay that's the whole page, you're basically a dbar expert now, go forth and pipe things π
dbar Β· version/date stamp: 2022-06-04 Β· page dbar(1) β mwah, take care bestie π
β¨
π¦ where this page comes from
- debian bookworm: dbar 0.0.20100524-7 Β· GPL-2.0-or-later
- debian trixie: dbar 0.0.20100524-7 Β· GPL-2.0-or-later
- ubuntu noble: dbar 0.0.20100524-7 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms