From 1a90ceb3e02e50a54bc0267571e0f4554201b579 Mon Sep 17 00:00:00 2001 From: Sol Jerome Date: Thu, 23 Apr 2009 16:33:20 +0000 Subject: More python 2to3 updates along with pylint/code cleanups Signed-off-by: Sol Jerome git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5173 ce84e21b-d406-0410-9b95-82705330c041 --- src/sbin/bcfg2-admin | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'src/sbin/bcfg2-admin') diff --git a/src/sbin/bcfg2-admin b/src/sbin/bcfg2-admin index 2023808e8..af461dfbc 100755 --- a/src/sbin/bcfg2-admin +++ b/src/sbin/bcfg2-admin @@ -1,8 +1,12 @@ #!/usr/bin/env python '''bcfg2-admin is a script that helps to administrate a bcfg2 deployment''' -import getopt, logging, sys -import Bcfg2.Server.Core, Bcfg2.Logger, Bcfg2.Options +import getopt +import logging +import sys +import Bcfg2.Server.Core +import Bcfg2.Logger +import Bcfg2.Options log = logging.getLogger('bcfg-admin') @@ -23,7 +27,7 @@ if __name__ == '__main__': try: opts, args = getopt.getopt(sys.argv[1:], 'hC:', ['help', 'configfile=']) except getopt.GetoptError, msg: - print msg + print(msg) raise SystemExit(1) @@ -38,7 +42,7 @@ if __name__ == '__main__': if len(args) < 1 or args[0] == 'help': print ("Usage: bcfg2-admin [OPTIONS] MODE [ARGS]\n\n" "Available options are:") - for (opt, arg) in avail_opts.items(): + for (opt, arg) in list(avail_opts.items()): print((" %-15s " % opt + arg)) print ("\nAvailable modes are:") if len(args) > 1: -- cgit v1.2.3-1-g7c22