[BusyBox] Hi all
David Douthitt
ssrat at mailbag.com
Wed Apr 18 15:56:49 UTC 2001
Erik Andersen wrote:
> For example, if each applet included its own APPLET("name", name_main, DIR)
> stuff, we could basically grep for that stuff at compile time, sort it,
> and create the master applet list dynamically.
How about using the "new" UNIX /opt model? I'm refering to where the
system PATH is huge, and each additional package adds a new dir to the
path, like so:
/opt/netscape/bin:/opt/openview/bin:/opt/ns-fasttrack/bin:/opt/ARCserve/bin
etc. etc. etc. To wit, using in busybox would be having directories
like so:
busybox/
busybox/contrib/
busybox/contrib/myapplet/
applet.h
usage.h
main.c
[...etc...]
Thus, sorting the applet code (with the exception of the busybox apps)
would be:
ls -1d busybox/contrib/* | sed 's/$/\/applet.h/'
...or maybe even...
ls -1d busybox/contrib/*/applet.h
...if ls sorts completely.
You could even sort the busybox applets this way in another directory
other than ./contrib/
One thing: I was trying to implement some *aliases* and found that
near impossible without duplicating the help entirely - not a pleasant
thing when you're trying to alias ls to about three others :O
More information about the busybox
mailing list