[liboping-changes] octo's ping library: Changes to 'ab/prettyping'
Florian Forster
octo at verplant.org
Wed Dec 4 16:22:55 CET 2013
New branch 'ab/prettyping' available with the following commits:
commit 58fd85d1d65fc770fa6895d21ffb2973cb8e10fc
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Tue Dec 3 00:33:39 2013 -0500
switch to ncursesw in the build chain
commit 59786b990da7a6c6593cd94ef3384d143940ff91
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 23:15:13 2013 -0500
better wrapping: add a cursor and respect inner borders
commit faa01e58cd5b3863bc5891c25176ea0ae2d71679
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:57:00 2013 -0500
rework scaling algorithm so it covers the whole range
i did this after some stress testing, now it covers the whole range on input
commit 3885683edb804a976b89b95d8e5adf041e8912d7
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:32:46 2013 -0500
cleanup safety checks
make sure that if we go beyond the max ratio, we just mark it as one
commit 00c587beea7459830100c3d7beffdebb6ee316dc
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:32:15 2013 -0500
wrap around the window once the histogram grows too big
commit d5a3fc99f5587e63e0c80e8a29f8d59430f3b7b9
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:29:53 2013 -0500
remove a little quirk i introduced by mistake
this was breaking the border
commit f379d7a19072d3fde41b760c5148313cdc210919
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:29:24 2013 -0500
make histogram colors with a nicer background
commit 36037039417eee9a7feebb723a2272a64438a22a
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:10:41 2013 -0500
restore usual ping display, now that histograms are in a different window
commit d64c11378cef748cc6697f8e54c0051432153e6d
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 22:06:26 2013 -0500
put histograms into the independent window, to eventually restore ping times display
commit 68d713ec1a7027113f1fa20df598a63539511593
Author: Antoine Beaupré <anarcat at koumbit.org>
Date: Mon Dec 2 20:45:58 2013 -0500
implement some prettyping-inspired display instead of textual
this is a first stab at porting "prettyping.sh" into noping. the idea
is to show a histogram of ping times instead of numerical values. with
some work, we could actually show both, but this focuses on
implementing the hard part (the histogram) properly.
it is very rudimentary for now:
* the math may be wrong for the size of the bar, I was mostly in a
rush to make unicode work and have something pretty quickly.
* all hosts are on the same line: each should have its own line
* the histogram should be displayed in a separate window
* it should use background colors as well
* it should fallback when the terminal is not unicode-capable
* the scaling logic is fully automatic, which necessarily gives weird
results at first
this requires switching to the ncursesw library and other unicode
ncurses hackery described in this post:
http://newsgroups.derkeiler.com/Archive/Rec/rec.games.roguelike.development/2010-09/msg00050.html
pretty ping is a awk/bash script, MIT-licensed, available here:
https://bitbucket.org/denilsonsa/small_scripts/src/tip/prettyping.sh
More information about the liboping-changes
mailing list