freebsd-dev/usr.bin/mktemp
Kyle Evans ac6f924e1c mktemp: add -p/--tmpdir argument
This matches other mktemp implementations, including OpenBSD and GNU.
The -p option can be used to provide a tmpdir prefix for specified
templates.  Precedence works out like so:

-t flag:
- $TMPDIR
- -p directory
- /tmp

Implied -t flag (no arguments or only -d flag):
- -p directory
- $TMPDIR
- /tmp

Some tests have been added for mktemp(1) in the process.

Reviewed by:	imp (earlier version), wosch
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D37121
2022-10-30 22:55:46 -05:00
..
tests mktemp: add -p/--tmpdir argument 2022-10-30 22:55:46 -05:00
Makefile mktemp: add -p/--tmpdir argument 2022-10-30 22:55:46 -05:00
Makefile.depend
mktemp.1 mktemp: add -p/--tmpdir argument 2022-10-30 22:55:46 -05:00
mktemp.c mktemp: add -p/--tmpdir argument 2022-10-30 22:55:46 -05:00