From 38fcd221d8fe03208abdafe0f01a6e54a601b71a Mon Sep 17 00:00:00 2001 From: jak1 Date: Sun, 19 Jun 2022 09:34:16 +0200 Subject: updated all leftover scripts to py3 --- hercules/code/servertoclient/groups.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'hercules/code/servertoclient/groups.py') diff --git a/hercules/code/servertoclient/groups.py b/hercules/code/servertoclient/groups.py index 99424e5..6372c31 100644 --- a/hercules/code/servertoclient/groups.py +++ b/hercules/code/servertoclient/groups.py @@ -49,7 +49,7 @@ def readCommands(f): value = value[idx1 + 1: idx2 - idx1] parts = comaSplit.split(value) commands[name] = (parts[0].strip(), parts[1].strip()) - print "command: {0}, {1}".format(name, commands[name]) + print("command: {0}, {1}".format(name, commands[name])) return commands def readPermissions(f): @@ -63,7 +63,7 @@ def readPermissions(f): name = parts[0].strip() value = parts[1].strip() permissions[name] = value - print "permission: {0}, {1}".format(name, value) + print("permission: {0}, {1}".format(name, value)) return permissions def readInherit(data): @@ -98,26 +98,26 @@ def readGroup(groups, f): continue name = parts[0].strip() value = parts[1].strip() - print "line: {0}, {1}".format(name, value) + print("line: {0}, {1}".format(name, value)) if name == "id": fields["id"] = value elif name == "name": fields["name"] = value elif name == "commands": commands = readCommands(f) - print "Commands: {0}".format(commands) + print("Commands: {0}".format(commands)) elif name == "permissions": permissions = readPermissions(f) - print "Permissions: {0}".format(permissions) + print("Permissions: {0}".format(permissions)) elif name == "inherit": inherit = readInherit(value) - print "Inherit: {0}".format(inherit) + print("Inherit: {0}".format(inherit)) def getCommandType(data): if data[0] == "false" and data[1] == "false": return "false" elif data[0] == "false" and data[1] == "true": - return "other"; + return "other" elif data[0] == "true" and data[1] == "false": return "self" elif data[0] == "true" and data[1] == "true": -- cgit v1.2.3-60-g2f50