summaryrefslogtreecommitdiffstats
path: root/bin
Commit message (Collapse)AuthorAgeFilesLines
* Note early appearence of some commands. These actually appeared in PWB, butjmallett2002-06-101-0/+5
| | | | | it seems we don't have a macro for that yet, so list them in the first UNIX release since then that we have a .At for: v7.
* Use socklen_t for the length of a socket structure instead of `int'.keramida2002-06-091-1/+2
| | | | Reviewed by: mike
* Replace <strings.h> with <string.h>. No functions from the former arekeramida2002-06-091-1/+1
| | | | | | | used in this file, and strlen() needs to be prototyped by the latter, for this to compile without warnings. Reviewed by: mike
* Check the return value of getcwd() to avoid printf()ing a NULL. Markmike2002-06-091-4/+5
| | | | | | usage() as __dead2 to avoid a GCC warning. Spotted by: keramida
* Allow whitespace to act as a delimiter in the keywords list given to the -o,jmallett2002-06-082-5/+14
| | | | | | | | again, but also allow it in the user-specified header, too. This is far more backwards compatible and SUSv3-happy than allowing only comma to seperate the keywords list. Submitted by: tjr
* Fixed unsorting.bde2002-06-081-1/+1
|
* Don't say that the list of formats can be space delimited, it no longer can be.jmallett2002-06-081-2/+5
| | | | | | Mention that more than one -o will concatenate formats. Submitted by: Jun Kuriyama <kuriyama@imgsrc.co.jp>
* Back out previous back out of previously correct code.jmallett2002-06-071-2/+1
| | | | | Double-plus-pointy-hat to: jmallett Submitted by: bde
* Remove tunables to hide warnings that no longer exist.jmallett2002-06-071-2/+0
|
* Cast to long to match format. Hidden by revision 1.18 of Makefile.jmallett2002-06-071-1/+2
|
* Use a global `now' variable for the current time, and initialise it atjmallett2002-06-063-6/+5
| | | | startup, right after calling setlocale(3).
* Implement a SUSv3-ignorant but "time"-similar format for "etime", elapsedjmallett2002-06-064-0/+21
| | | | | run time (NOT cpu time). cputime() and elapsed() both need to honour SUSv3 now.
* sysctlbyname(3) returns -1 on failure, not any other value < 0.jmallett2002-06-061-3/+3
|
* Support the SUSv3 `rgroup' format.jmallett2002-06-064-5/+24
| | | | Clean up some local style bogons.
* Cast arg_max to size_t when comparing it (times 4, plus 1) against SIZE_MAX. Ijmallett2002-06-061-1/+2
| | | | | | | | was worried about truncation of arg_max by this cast, but if it gets truncated, we know it'll obviously be greater than SIZE_MAX anyway. Big pointy hat to: jmallett Submitted by: keramida
* SUSv3 conform on the "comm" and "args" formats, and make correct the "command"jmallett2002-06-064-4/+41
| | | | format, since it's BSDlike, and "comm" is actually different.
* Refer to the command format by its SUSv3 name (comm), and list command as anjmallett2002-06-061-2/+2
| | | | alias.
* As per behaviour on SVR4 systems, to allow any desirable type of header in thejmallett2002-06-061-2/+4
| | | | | | | | | | | | | | | | override, seperate by comma (',') only, rather than any type of whitespace (the literal space character (' ') had already been removed from this list). This allows things like: miamivice# ps -opid='Process > Identifier' Process Identifier 1350 1445 1450 To work.
* Document the -f and -v options of the unset builtin.tjr2002-06-061-5/+15
|
* Quote the output of the no-argument form of the `set' builtin for re-inputtjr2002-06-061-2/+8
| | | | to the shell.
* Add the SUSv3 -p ("portable") option to both the export and readonlytjr2002-06-062-3/+47
| | | | | builtins. This makes export/readonly print lines in the form "export name=value".
* Don't modify output that is to be quoted if it contains no IFS characterstjr2002-06-061-0/+7
| | | | or shell metacharacters.
* Widen the scope of fmt.c::1.19 and consistently use errx(3) if malloc(3) [orjmallett2002-06-053-10/+8
| | | | | | | | | | realloc(3)] happens to fail, everywhere in ps(1). Discussed with: bde, charnier (a while ago) fmt_argv() can no longer return NULL, so don't bother checking. Submitted by: bde
* Comma seperate format lists, since space is no longer up to the task.jmallett2002-06-051-6/+6
| | | | | Poked by: David Wolfskill <david@catwhisker.org> Pointy hat to: jmallett
* Support the 'comm' keyword, which is equivalent to our 'command', butjmallett2002-06-051-0/+2
| | | | specified by SUSv3.
* A space cannot be a header string seperator it appears given the SUSv3jmallett2002-06-051-1/+1
| | | | | description of ps(1), which uses them. I question whether newline and tab can be either, but I'm not touching them. Yet.
* To comply with SUSv3, duplicate the variable contents for each given format,jmallett2002-06-051-1/+4
| | | | | | | | | | | | so that multiple -ovar=header lines do not overwrite eachother. This means that ps -ouser=USERNAME -ouser=WHO would now possibly print: USERNAME WHO juli juli Whereas before it would be: WHO WHO juli juli
* Returning NULL here if malloc(3) fails is silly, at this point in the codepathjmallett2002-06-051-1/+1
| | | | | we have't malloc(3)'d nearly as much as we probably will, so errx(3) away, instead of waiting for something to fail yet again later on.
* Remove an XXX comment that seems to be a tiny bit no longer pertinent. Thisjmallett2002-06-051-4/+0
| | | | | | function seems to do the right thing, and is not a "stub", and whoever "marc" is, he's had plenty of time to do "the real one", so don't wait around for him any longer.
* Use of zero here meant many things, NULL, '\0' (NUL), and 0. Sort it out.jmallett2002-06-051-5/+5
|
* Use a const char * where it is meant to be used. There's no reason to tryjmallett2002-06-051-1/+2
| | | | to discard the const qualifier here.
* Duplicate the pointer to the string containing the header so it does not getjmallett2002-06-051-1/+1
| | | | frobbed when/if the pointer it is actually a part of gets freed.
* Display job status correctly when a pipeline is suspended.tjr2002-06-041-6/+8
|
* Describe finished jobs as "Done", not "Exit" (SUSv3)tjr2002-06-041-1/+5
|
* Don't output `state' and `current' fields for processes that aren'ttjr2002-06-041-3/+5
| | | | leaders in -l option to jobs(1).
* Missing prototypes from previous commit.tjr2002-06-041-0/+3
|
* Correct minor spacing problem in output of jobs -l for pipelines.tjr2002-06-041-1/+1
|
* Quote alias values in the output of the alias(1) builtin so they aretjr2002-06-043-5/+44
| | | | suitable for re-input to the shell (SUSv3)
* Respect setting of the COLUMNS environment variable (SUSv3)tjr2002-06-042-1/+14
|
* Ignore empty COLUMNS environment variable. COLUMNS should take precedencetjr2002-06-041-5/+5
| | | | over TTY width found via ioctl() (SUSv3)
* Correct history (again): V3 had a kill command, only it was in section 8,tjr2002-06-031-1/+1
| | | | not 1.
* Correct History: sync(8) appeared in V4.tjr2002-06-031-1/+1
|
* Correct History section: kill(1) appeared in V4, not V6.tjr2002-06-031-1/+1
|
* Fix typo causing ``fc -e'' to not work correctly. getopt() sets optarg,tjr2002-06-021-1/+1
| | | | not shoptarg.
* Adding an entry to the history with H_ENTER moves libedit's internaltjr2002-06-021-0/+9
| | | | | history cursor. Reset the cursor after adding the entry to the history when doing ``fc -s'' so the output is correct.
* Implement $PPID, the parent process ID of the shell.tjr2002-06-012-0/+9
|
* Support the remaining job ID formats required by SUSv3:tjr2002-06-011-2/+21
| | | | | | %+ (current job, same as %%), %- (previous job), %?str (job with "str" in its command name).
* Add -s (output PID's only) and -l (show PID's) options to the jobs(1)tjr2002-05-314-18/+85
| | | | builtin. Modify the output format to match what SUSv3 requires.
* #if JOBS around a job control-related statement to allow compilation withtjr2002-05-311-0/+2
| | | | job control disabled.
* Break the code to display status info for one job out from showjobs() intotjr2002-05-311-63/+52
| | | | | showjob(), use it inside dowait() to display status info for consistency, and in a format closer to what the standard requires.
OpenPOWER on IntegriCloud