summary refs log tree commit diff
diff options
context:
space:
mode:
authorClayton G. Hobbs <clay@lakeserv.net>2016-02-03 23:43:42 -0500
committerClayton G. Hobbs <clay@lakeserv.net>2016-02-03 23:43:42 -0500
commitb04dbd12cd00b495065606f40aa14c150df48b98 (patch)
treec7047198235bc2764e42acad19c76defee01729b
parent31731113b6a5000a4e0ce78da013b79cd8c26c80 (diff)
Wrap long lines in kaylee.py
-rwxr-xr-xkaylee.py15
1 files changed, 9 insertions, 6 deletions
diff --git a/kaylee.py b/kaylee.py
index 4293777..5f5b611 100755
--- a/kaylee.py
+++ b/kaylee.py
@@ -114,9 +114,10 @@ class Kaylee:
         numt, nums = self.number_parser.parse_all_numbers(t)
         # Is there a matching command?
         if t in self.commands:
-            # Run the valid_sentence_command if there is a valid sentence command
+            # Run the valid_sentence_command if it's set
             if self.options['valid_sentence_command']:
-                subprocess.call(self.options['valid_sentence_command'], shell=True)
+                subprocess.call(self.options['valid_sentence_command'],
+                                shell=True)
             cmd = self.commands[t]
             # Should we be passing words?
             if self.options['pass_words']:
@@ -124,9 +125,10 @@ class Kaylee:
             self.run_command(cmd)
             self.log_history(text)
         elif numt in self.commands:
-            # Run the valid_sentence_command if there is a valid sentence command
+            # Run the valid_sentence_command if it's set
             if self.options['valid_sentence_command']:
-                subprocess.call(self.options['valid_sentence_command'], shell=True)
+                subprocess.call(self.options['valid_sentence_command'],
+                                shell=True)
             cmd = self.commands[numt]
             cmd = cmd.format(*nums)
             # Should we be passing words?
@@ -135,9 +137,10 @@ class Kaylee:
             self.run_command(cmd)
             self.log_history(text)
         else:
-            # Run the invalid_sentence_command if there is an invalid sentence command
+            # Run the invalid_sentence_command if it's set
             if self.options['invalid_sentence_command']:
-                subprocess.call(self.options['invalid_sentence_command'], shell=True)
+                subprocess.call(self.options['invalid_sentence_command'],
+                                shell=True)
             print("no matching command {0}".format(t))
         # If there is a UI and we are not continuous listen
         if self.ui: