summaryrefslogtreecommitdiff
path: root/alot
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2017-06-16 15:57:25 -0700
committerDylan Baker <dylan@pnwbakers.com>2017-07-10 17:04:06 -0700
commitb4cb1bd2692277b3d722733dfcca1322ffb6d45a (patch)
treec51bf988965fcda546ea97547d49e026b5887665 /alot
parent86186a242c11fcbc501e7afc791a50187e0dd574 (diff)
Add a reload command
This command allows the configuration to be reloaded while alot is running. Fixes #1046
Diffstat (limited to 'alot')
-rw-r--r--alot/commands/globals.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/alot/commands/globals.py b/alot/commands/globals.py
index fcd92e97..8e8c4fde 100644
--- a/alot/commands/globals.py
+++ b/alot/commands/globals.py
@@ -955,3 +955,12 @@ class MoveCommand(Command):
else:
ui.notify('unknown movement: ' + self.movement,
priority='error')
+
+
+@registerCommand(MODE, 'reload', help='Reload all configuration files')
+class ReloadCommand(Command):
+
+ """Reload configuration."""
+
+ def apply(self, ui):
+ settings.reload()