aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-01-15Fix "ps -T 1234" to show thread belonging to that PID.Rob Landley
2018-01-15Merge shared_main() back into ps_main() and top_main(), add comments.Rob Landley
2018-01-15Add more comments to ps.Rob Landley
2018-01-14Switch xgettty() -> tty_fd() (returning -1 instead of erroring out if none).Rob Landley
2018-01-10Move make help text out of Makefile.Rob Landley
2018-01-09Add the gzip/gunzip/zcat tests I wrote for toolbox gzip/gunzip/zcat.Elliott Hughes
Bringing the zlib-based gzip/gunzip/zcat over to toybox is a problem for another day, but at least the tests are easy... (These tests pass with TEST_HOST and on the toolbox versions, but the toybox toys are in pending and very broken.)
2018-01-06Move millitime() into lib.c.Rob Landley
2018-01-03Cleanup pass on gzip.c.Rob Landley
2018-01-01Promote logger, and fluff up help text a bit.Rob Landley
2018-01-01Cleanup logger.c, and move the facilitynames/prioritynames SYSLOG_NAMESRob Landley
stuff syslog.h does into lib.c and portability.h
2018-01-01xphung on github said: "config2help currently doesn't work on OS X, itRob Landley
terminates parsing of Config.in at first blank line. This is because getdelim() in portability.c returns -1 whenever the line comprises only a single linefeed character. Fixing this was a trivial change to two lines (see below), and config2help now works on OS X but I haven't regression tested this on any other commands which rely on getdelim()"
2017-12-29Promote iconv.Rob Landley
2017-12-29Cleanup iconv.Rob Landley
Implement -c, fix endless loop when illegal char happens with !outleft (don't need to check errno, just in == toybuf), refill buffer each time (less efficient handling of illegal chars but never have to worry about how long constitutes a valid sequence in unknown encoding). Fix input longer than 2k (memmove() has src/dest switched, second time through loop in starts at offset inleft...) Made it start at beginning every time. Switch iconv_open() error msg to show to/from and errno (rather than hardwired english text).
2017-12-27Promote setfattrRob Landley
2017-12-27Minor cleanup on setfattr.cRob Landley
2017-12-26Add xxd -i (and xxd -ri).Elliott Hughes
The original xxd doesn't support -r with -i. The original also outputs "unsigned char name[] = { ... };" for input other than stdin, but that actually makes it less useful --- many languages support array initializers, but far fewer support that exact declaration syntax. Also fix the -c range checking and defaulting: ><= in the argument string only works for floating point arguments. Bug: http://b/64711851
2017-12-26Fix xargs -0 with -n.Elliott Hughes
Also make -0 and -E mutually exclusive (rather than just ignore -E with -0). Bug: https://github.com/landley/toybox/issues/78
2017-12-24Add fmt.Elliott Hughes
A very simple implementation of fmt, good enough for my daily use of !!fmt in vi to reflow checkin comments like this.
2017-12-22Redo namestopid to handle more cases.Rob Landley
2017-12-19Fix make bloatcheck dependencies (pointed out by Patrick Oppenlander).Rob Landley
2017-12-19killall should kill scripts too.Elliott Hughes
Found running LTP file system tests on Android. Bug: http://b/70627145
2017-12-11An incomplete list of deviations from posix (it's a start).Rob Landley
2017-12-10Cleanup pass on stty: collate do_stty() calls for future inlining,Rob Landley
collapse flag arrays to fewer lines, factor out xtcgetattr(), strip curly brackets around single lines, don't have a separate error message for tcsetattr() return code if more thorough check is on next line, take advantage of O_RDONLY being zero, document -F.
2017-12-05Use NULL rather than 0 in vargs.Elliott Hughes
Top bits count too!
2017-12-03Commands in pending should default n.Rob Landley
2017-12-03Add stty(1).Elliott Hughes
Full POSIX stty with Linux extensions. Output and behavior match coreutils 8.26 as far as I can tell. For some reason busybox 1.22 stty always shows all the special characters, even when they match "sane". I've matched coreutils, since "shows differences from sane" is easy to describe and obviously useful. Flags in the various arrays are not in the order they're introduced in POSIX or in the Linux header file: they're in the order that they're output by coreutils' stty. The -g output matches coreutils and busybox. I implemented iuclc, xcase, and olcuc even though they've been removed from POSIX because the others implement them, and "man stty" defines "raw" and "sane" in terms of them (where POSIX doesn't define "sane" in any useful sense). This builds fine against glibc 2.24, and as far as I can tell all the constants used were in Linux 2.6 so I'm assuming that there shouldn't be any #ifdef nonsense needed for any reasonable vintage of C library.
2017-12-03Don't capitalize in the middle of a sentence.Elliott Hughes
Before: toy: Unknown option p (See "toy --help") After: toy: Unknown option p (see "toy --help")
2017-12-03Add uptime -p.Elliott Hughes
We (Android) give up trying to teach folks what "up 142 days, 1:45" means... Bug: http://b/65205261
2017-12-03Gaël PORTAY wants mdev to work when Linux has the block layer configured out.Rob Landley
2017-12-02Android has its loop devices under "block" as Elliott says "by reason ofRob Landley
historical accident", so fall back to check there. Also remove an obsolete comment TODO block, check !parent for dirtree top of tree instead of '/' in the filename, and typecast some printf arguments for 32-bit systems.
2017-11-26Recognize sh/frv fdpic, and add types for bpf and new microblaze.Rob Landley
2017-11-26Use endianness info to read executable type.Rob Landley
2017-11-23Add "time -v".Elliott Hughes
This shows the other fields in getrusage. I've chosen to only show the ones actually maintained by Linux.
2017-11-21Make find -exec + obey ARG_MAX just like xargs.Elliott Hughes
This isn't ideal, but it matches xargs and none of us is likely to have time to do the best possible thing any time soon. Bug: http://b/65818597 Test: ./toybox find /usr/local/google/ndkports/ -exec echo {} +
2017-11-16Minor tweaks.Rob Landley
2017-11-16Add "df -i".Elliott Hughes
Also switch to u64 for calculations. Some FUSE file systems have inode counts large enough to overflow s64.
2017-11-03file(1): add ogg, TrueType font, LLVM bitcode, PEM certs, and PE executables.Elliott Hughes
More of the files encountered on the Android system image (plus PE executables, which we build but which shouldn't actually make it to the system image!).
2017-10-31Add top -m, fix width truncating for narrow screens (off by one), and add ↵Rob Landley
iotop -H
2017-10-31Rename test_*.c to demo_*.c (because "make test_$CMD" means something already),Rob Landley
fluff out README, and add a comment to hostid explaining its deprecation.
2017-10-31Only show LABEL= when there is one.Rob Landley
2017-10-31Fix cut -s and -f when delimiter not found (posix says print whole line).Rob Landley
2017-10-28Web page updates.Rob Landley
2017-10-25Make -c work with unicode chars, and first stab at -C measuring columns.Rob Landley
2017-10-22Insmod dummy for ifconfig tests, and "pointopoint" only has two t's.Rob Landley
2017-10-22Add stat to index.Rob Landley
2017-10-22I ended up writing a new find from scratch, so remove old unfinished cleanup ↵Rob Landley
log.
2017-10-22Typo.Rob Landley
2017-10-21Use char for exitval and wasroot (first capped at 8 bits and second's a flag).Rob Landley
2017-10-21Use setlocale(LC_CTYPE, "C.UTF-8") for more targeted locale enable:Rob Landley
(only enable character parsing, force utf8, "C" semantics otherwise.)
2017-10-19Elliott wants to add TOYBOX_VENDOR.Rob Landley