Open minusf opened 3 years ago
btw it would be really nice to have the thousands separators in the terminal version as well...
The formatting is done through LC_NUMERIC
. You can try changing/setting the env variable for LC_NUMERIC
.
# export LC_NUMERIC="en_US.UTF-8"
or
# LC_NUMERIC="en_US.UTF-8" bash -c 'goaccess access.log --log-format=COMBINED'
hm. i don't have LC_NUMERIC
set. i thought LC_something
is not set, LANG
takes precedence, but i might be wrong... i give it a try, thank you.
$ LC_NUMERIC= goaccess -p .goaccessrc log.2021-05-01 -o log.2021-05-01.html
[PARSING log.2021-05-01] {2401556} @ {66860/s}
$ LC_NUMERIC=en_US.UTF-8 goaccess -p .goaccessrc log.2021-05-01 -o log.2021-05-01.html
[PARSING log.2021-05-01] {2,399,617} @ {66,656/s}
the terminal indeed printed correct thousand separators. however the generated html is the same in both cases:
4.506 (0.53%) | 30 (0.04%) |
---|
goaccess 1.5.1 macos 11.4
When generating html reports, numbers in the columns look like this:
207.286 (8.80%)
the man page does not mention locales at all, but in any case i have:
I think in this case the number should look like any of these:
207,286 (8.80%)
207 286 (8.80%)
207_286 (8.80%)
(some programming languages accept these numbers nowadays)