summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/input_handlers/input_handler.py4
-rw-r--r--modules/input_handlers/pipewire_record.py4
-rw-r--r--modules/input_handlers/stdin_input.py4
-rw-r--r--modules/intents/process.py2
-rw-r--r--modules/intents/sway.py4
5 files changed, 9 insertions, 9 deletions
diff --git a/modules/input_handlers/input_handler.py b/modules/input_handlers/input_handler.py
index 82a2830..3db042c 100644
--- a/modules/input_handlers/input_handler.py
+++ b/modules/input_handlers/input_handler.py
@@ -3,9 +3,9 @@ from abc import ABC, abstractmethod
class InputHandler(ABC):
@abstractmethod
- def get_input(self):
+ def get_input(self) -> str:
pass
@abstractmethod
- def cleanup(self):
+ def cleanup(self) -> None:
pass \ No newline at end of file
diff --git a/modules/input_handlers/pipewire_record.py b/modules/input_handlers/pipewire_record.py
index 3ad295c..ad119b6 100644
--- a/modules/input_handlers/pipewire_record.py
+++ b/modules/input_handlers/pipewire_record.py
@@ -11,12 +11,12 @@ FIFO_PATH = "/tmp/hestia-listening"
RECORD_PATH = "/tmp/hestia-record.mp3"
class PipeWireRecord(InputHandler):
- def cleanup(self):
+ def cleanup(self) -> None:
if os.path.exists(FIFO_PATH):
os.remove(FIFO_PATH)
- def get_input(self):
+ def get_input(self) -> str:
device = PipeWireRecord.get_device()
self.cleanup()
diff --git a/modules/input_handlers/stdin_input.py b/modules/input_handlers/stdin_input.py
index 5c50511..a18273f 100644
--- a/modules/input_handlers/stdin_input.py
+++ b/modules/input_handlers/stdin_input.py
@@ -4,10 +4,10 @@ from modules.input_handlers.input_handler import InputHandler
class StdinInput(InputHandler):
- def cleanup(self):
+ def cleanup(self) -> None:
pass
- def get_input(self):
+ def get_input(self) -> str:
for line in sys.stdin:
line = line.strip()
if not line:
diff --git a/modules/intents/process.py b/modules/intents/process.py
index 0bed441..48ade48 100644
--- a/modules/intents/process.py
+++ b/modules/intents/process.py
@@ -4,7 +4,7 @@ from .sway import HesNavigate
from ..config import Config
-def HesExecuteProcess(data: Dict, config: Config):
+def HesExecuteProcess(data: Dict, config: Config) -> None:
if "workspace" in data:
HesNavigate(data, config)
diff --git a/modules/intents/sway.py b/modules/intents/sway.py
index 1773363..9955b4c 100644
--- a/modules/intents/sway.py
+++ b/modules/intents/sway.py
@@ -2,8 +2,8 @@ import os
from typing import Dict
from ..config import Config
-def HesNavigate(data: Dict, config: Config):
+def HesNavigate(data: Dict, config: Config) -> None:
os.popen(f"swaymsg workspace {data["workspace"]}")
-def HesLock(data: Dict, config: Config):
+def HesLock(data: Dict, config: Config) -> None:
os.popen(config.lock) \ No newline at end of file