.\" Hey, EMACS: -*- nroff -*- .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) .TH ON_AC_POWER 1 "9 March 2002" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: .\" .nh disable hyphenation .\" .hy enable hyphenation .\" .ad l left justify .\" .ad b justify to both left and right margins .\" .nf disable filling .\" .fi enable filling .\" .br insert line break .\" .sp insert n+1 empty lines .\" for manpage-specific macros, see man(7) .SH NAME on_ac_power \- test whether computer is running on AC power .SH SYNOPSIS .B on_ac_power .SH DESCRIPTION .B on_ac_power checks whether the system is running on AC power (i.e., mains power) as opposed to battery power. .SH OPTIONS None. .SH "EXIT STATUS" .br .nf \fB0\fR (true) System is on mains power \fB1\fR (false) System is not on mains power \fB255\fR (false) Power status could not be determined .SH FILES .br .nf .ta \w'/proc/apm 'u \fI/proc/apm\fR APM status information file .nf .ta \w'/proc/acpi/ 'u \fI/proc/acpi\fR ACPI status information directory .SH AUTHOR This manual page was written by Steve Dodd and was updated by Thomas Hood.