]> git.armaanb.net Git - asd-repo.git/blob - extra/zzz/files/zzz.8
Adapt for asd linux
[asd-repo.git] / extra / zzz / files / zzz.8
1 .Dd July 25, 2014
2 .Dt ZZZ 8
3 .Os Linux
4 .Sh NAME
5 .Nm zzz ,
6 .Nm ZZZ
7 .Nd suspend or hibernate your computer
8 .Sh SYNOPSIS
9 .Nm zzz
10 .Op Fl nSzZRH
11 .Nm ZZZ
12 .Op Fl nSzZRH
13 .Sh DESCRIPTION
14 .Nm
15 is a simple script to suspend or hibernate your computer.
16 It supports hooks before and after suspending.
17 .Bl -tag -width indent
18 .It Fl n
19 dry-run mode.
20 Instead of performing an ACPI action,
21 .Nm
22 will just sleep for a few seconds.
23 .It Fl S
24 Enter low-power idle mode (ACPI S0, kernel name "freeze").
25 .It Fl z
26 Enter suspend to RAM mode (ACPI S3, kernel name "mem").
27 This is the default for
28 .Nm zzz .
29 .It Fl Z
30 Enter hibernate to disk mode (ACPI S4, kernel name "disk") and power off.
31 This is the default for
32 .Nm ZZZ .
33 .It Fl R
34 Enter hibernate to disk mode and reboot.
35 This can be used to switch operating systems.
36 .It Fl H
37 Enter hibernate to disk mode and suspend.
38 This is also know as suspend-hybrid.
39 .El
40 .Sh FILES
41 Before suspending,
42 .Nm zzz
43 runs the executable files in
44 .Pa /etc/zzz.d/suspend
45 in alphanumeric order.
46 After suspending,
47 .Nm zzz
48 runs the executable files in
49 .Pa /etc/zzz.d/resume
50 in alphanumeric order (not in reverse order!).
51 .Pp
52 The environment variable
53 .Ev ZZZ_MODE
54 can be used in these hooks to differentiate between
55 .Ic standby ,
56 .Ic suspend ,
57 and
58 .Ic resume .
59 .Sh DIAGNOSTICS
60 .Bl -tag -width indent
61 .It suspend/hibernate not supported
62 The hardware does not support ACPI S3/S4 with this kernel.
63 .It sleep permission denied
64 You lack sufficent privilege to write to
65 .Pa /sys/power/state .
66 .It another instance of zzz is running
67 .Nm
68 locks
69 .Pa /sys/power
70 during operation.
71 Perhaps a hook is stuck?
72 .It Zzzz... yawn.
73 The system has woken up again.
74 Everything is fine.
75 You feel refreshed.
76 .Sh SEE ALSO
77 .Xr pm-action 8 ,
78 .Xr s2disk 8 ,
79 .Xr s2ram 8 ,
80 OpenBSD's
81 .Xr apm 8
82 .Sh HISTORY
83 A similar
84 .Nm apm
85 command appeared in
86 .Nx 1.3
87 and
88 .Ox 1.2 .
89 .Sh AUTHOR
90 .An Leah Neukirchen ,
91 .Mt leah@vuxu.org .
92 .Sh LICENSE
93 .Nm
94 is in the public domain.