diff options
author | Florian Zeitz <florob@babelmonkeys.de> | 2016-09-14 08:54:47 +0200 |
---|---|---|
committer | Florian Zeitz <florob@babelmonkeys.de> | 2016-09-14 08:54:47 +0200 |
commit | 88ad03b7419f8ba64a6ee98a3d2d481b1d5b51e1 (patch) | |
tree | 74982a9e47d1acceaca1f2779be7a1a722daa499 | |
parent | f06786518f40ec6d5013a3035c9d4101a22bfa10 (diff) |
generate-cut-list example: Ident by 4 spaces (PEP 8)
-rwxr-xr-x | example-scripts/control-server/generate-cut-list.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/example-scripts/control-server/generate-cut-list.py b/example-scripts/control-server/generate-cut-list.py index 959ab58..394865b 100755 --- a/example-scripts/control-server/generate-cut-list.py +++ b/example-scripts/control-server/generate-cut-list.py @@ -6,16 +6,16 @@ import sys host = 'localhost' port = 9999 -conn = socket.create_connection( (host, port) ) +conn = socket.create_connection((host, port)) fd = conn.makefile('rw') for line in fd: - words = line.rstrip('\n').split(' ') + words = line.rstrip('\n').split(' ') - signal = words[0] - args = words[1:] + signal = words[0] + args = words[1:] - if signal == 'message' and args[0] == 'cut': - ts = datetime.datetime.now().strftime("%Y-%m-%d/%H_%M_%S") - print(ts) - sys.stdout.flush() + if signal == 'message' and args[0] == 'cut': + ts = datetime.datetime.now().strftime("%Y-%m-%d/%H_%M_%S") + print(ts) + sys.stdout.flush() |