]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
top(1): move command mapping to commands.c
authoreadler <eadler@FreeBSD.org>
Tue, 12 Jun 2018 06:53:31 +0000 (06:53 +0000)
committereadler <eadler@FreeBSD.org>
Tue, 12 Jun 2018 06:53:31 +0000 (06:53 +0000)
commit5246c095ced8f1eae2e146ecf9df74b723e1bd10
tree2a390496d03ac01ff7d2f6489d97d18a5bbcbc6c
parent4a3b73bc53e286b022fbe1edf92d9c90e97ac63f
top(1): move command mapping to commands.c

This eliminates the difficult to follow mapping of a string list. It
moves numbers from "#define" into (more) debuggable enums. More
generally, it follows the trend of moving more data into a more central
mechanism.

The help output is a little worse: " " is not rendered well, and there
are duplicate entries, but that will be fixed in a followup.
usr.bin/top/commands.c
usr.bin/top/commands.h
usr.bin/top/screen.c
usr.bin/top/top.c