summaryrefslogtreecommitdiffstats
path: root/usr.sbin/lastlogin
Commit message (Collapse)AuthorAgeFilesLines
* Allow custom files to be opened and allow sorting by timestamp.ed2011-06-062-18/+60
| | | | | | | | While implementing a tool to import lastlog entries into utmpx, I noticed lastlogin doesn't allow custom database files to be opened. Add a -f switch to support this. Also, add -r and -t similar to ls(1), ruptime(1), etc. where you can sort entries by timestamp and reverse them. This allows you to spot active/idle users more easily.
* Don't forget to catch realloc() errors.ed2010-04-111-1/+4
|
* Alphabetically sort the output of lastlogin(8).ed2010-04-112-4/+22
| | | | | | | | | According to the manpage, the entries have to be sorted by uid. This is no longer possible, since our utmpx implementation is completely unaware of user IDs. You can safely add entries for multiple users sharing the same uid. Make the output less random by sorting everything by name.
* Chop off excessive long hostnames to keep the table structure intact.ed2010-03-201-1/+1
| | | | This makes lastlogin(8) use exactly the same printf format as last(1).
* Remove unneeded setpassent() calls.ed2010-01-241-4/+0
| | | | lastlogin no longer requires the use of the passwd database.
* Remove stale references to utmp(5) and its corresponding filenames.ed2010-01-211-3/+3
| | | | I removed utmp and its manpage, but not other manpages referring to it.
* Port lastlogin(8) to utmpx.ed2010-01-132-17/+14
| | | | | | While there, fix a bug I introduced previously. We must reopen the database for each username passed on the command line. We must rewind the database and search from the beginning.
* The last big commit: let usr.sbin/ use WARNS=6 by default.ed2010-01-021-2/+0
|
* ANSIfy almost all applications that use WARNS=6.ed2009-12-291-4/+2
| | | | | | | I was considering committing all these patches one by one, but as discussed with brooks@, there is no need to do this. If we ever need/want to merge these changes back, it is still possible to do this per application.
* Several refinements to libulog's API.ed2009-12-261-1/+1
| | | | | | | | | - Only set the fields in the ulog_utmpx structure that are valid for the command in question. This means that strings like "shutdown" or "~" are not visible to the user anymore. - Rename UTXF_* to UTXI_*, indicating the indexation, instead of using the `antique' filename. If we ever get rid of utmp, it makes little sense calling it by its old name.
* Port lastlogin(1) to libulog.ed2009-12-092-43/+21
| | | | | Just use ulog_getutxuser() to obtain lastlog records or ulog_getutxent() to browse through all of them.
* Mechanically kill hard sentence breaks.ru2004-07-021-2/+4
|
* The .Nm utilitycharnier2002-07-141-2/+4
|
* de-__P()alfred2002-07-111-3/+3
|
* Fixed some world breakage caused by not updating clients when <timeconv.h>bde2002-07-081-0/+1
| | | | | was split off from <time.h>. This became fatal here when -Werror was reenabled.
* Don't depend on <pwd.h> to bogusly include <sys/types.h>.mike2002-06-091-0/+1
|
* I've been meaning to do this for a while. Add an underscore to thedillon2002-01-191-1/+1
| | | | | | | | time_to_xxx() and xxx_to_time() functions. e.g. _time_to_xxx() instead of time_to_xxx(), to make it more obvious that these are stopgap functions & placemarkers and not meant to create a defacto standard. They will eventually be replaced when a real standard comes out of committee.
* Fix ctime(&int) due to change to lastlog->ll_timedillon2001-10-291-1/+2
|
* Perform a major cleanup of the usr.sbin Makefiles.obrien2001-07-201-1/+2
| | | | | These are not perfectly in agreement with each other style-wise, but they are orders of orders of magnitude more consistent style-wise than before.
* Set WARNS=2 on programs that compile cleanly with it; add $FreeBSD$dd2001-06-301-1/+1
| | | | | | where necessary. Submitted by: Mike Barcroft <mike@q9media.com>
* Include stdlib.h for exit(3).dd2001-06-241-0/+1
| | | | Submitted by: Mike Barcroft <mike@q9media.com>
* - Backout botched attempt to introduce MANSECT feature.ru2001-03-261-0/+1
| | | | - MAN[1-9] -> MAN.
* Set the default manual section for usr.sbin/ to 8.ru2001-03-201-1/+0
|
* mdoc(7) cosmetics.ru2000-12-111-6/+6
| | | | Submitted by: sheldonh
* Remove unused #includes, duplicate $FreeBSD$ and $NetBSD$ definitions.charnier2000-12-101-7/+1
| | | | Reviewed by: Ruslan Ermilov <ru@FreeBSD.org>
* Added the lastlogin utility.ru2000-11-143-0/+219
Obtained from: NetBSD
OpenPOWER on IntegriCloud