diff options
author | Dylan Baker <baker.dylan.c@gmail.com> | 2017-01-26 13:43:18 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-26 13:43:18 -0800 |
commit | ae8a61509043c360628c76d3a35535c3f90b76bd (patch) | |
tree | 7c150de01bc2e60c3194381475d124e2d582f765 /docs | |
parent | a941aaa0de6981da8bdf2481601ae482817cbdae (diff) | |
parent | 0511526d97cb6a74282c5f4dd334be1f5f355ea0 (diff) |
Merge pull request #1005 from dcbaker/pr/fix-522
Add a hook that runs periodically
Diffstat (limited to 'docs')
-rw-r--r-- | docs/source/configuration/alotrc_table | 10 | ||||
-rw-r--r-- | docs/source/configuration/hooks.rst | 7 |
2 files changed, 17 insertions, 0 deletions
diff --git a/docs/source/configuration/alotrc_table b/docs/source/configuration/alotrc_table index 9e27b206..6929a665 100644 --- a/docs/source/configuration/alotrc_table +++ b/docs/source/configuration/alotrc_table @@ -385,6 +385,16 @@ :default: 2 +.. _periodic-hook-frequency: + +.. describe:: periodic_hook_frequency + + The number of seconds to wait between calls to the loop_hook + + :type: integer + :default: 300 + + .. _prefer-plaintext: .. describe:: prefer_plaintext diff --git a/docs/source/configuration/hooks.rst b/docs/source/configuration/hooks.rst index 6e7162e8..352701c3 100644 --- a/docs/source/configuration/hooks.rst +++ b/docs/source/configuration/hooks.rst @@ -205,3 +205,10 @@ Apart from command pre- and posthooks, the following hooks will be interpreted: :type suffix: str :returns: tuple of `prefix` and `suffix` :rtype: (str, str) + +.. py:function:: loop_hook(ui=None) + + Run on a period controlled by :ref:`_periodic_hook_frequency <periodic-hook-frequency>` + + :param ui: the main user interface + :type ui: :class:`alot.ui.UI` |