diff options
authorVictor Lowther <>2008-03-15 17:18:17 -0500
committerVictor Lowther <>2008-03-15 17:18:17 -0500
commit40cf5324abdfa5eac08cba836ca84097849ad188 (patch)
parentde8659ed4bb5d42251ee8695fc54642dbcce0604 (diff)
Implemented sleep_method_help support.
This intergrates sleep modules into the help system.
2 files changed, 10 insertions, 1 deletions
diff --git a/pm/HOWTO.modules b/pm/HOWTO.modules
index 0237d0e..09c3d78 100644
--- a/pm/HOWTO.modules
+++ b/pm/HOWTO.modules
@@ -57,4 +57,12 @@ OTHER STUFF:
If you define a function named "before_hook", that function will be executed
just before the sleep/resume hooks are executed. If you need to disable a hook,
-this is the place to do it.
+this is the place to do it.
+If you define a function named "sleep_method_help", that function will be
+executed whenever any of the pm-utils scripts is called with the "--help"
+option. If the behaviour of your sleep method can be changes by command-line
+parameters passed to pm-action or by a configuration file setting, you
+SHOULD define a sleep_method_help function and that function SHOULD explain
+how the command-line paramaters and configuration file settings can change its
diff --git a/src/ b/src/
index 204c0e5..c1a0b35 100644
--- a/src/
+++ b/src/
@@ -35,6 +35,7 @@ help()
echo "Options can change how suspend or hibernate is done."
run_hooks sleep help
+ command_exists sleep_method_help && sleep_method_help
exit 0