From 240a6cd174d56b0d57b826ce537e4b740f509fa5 Mon Sep 17 00:00:00 2001 From: Sol Jerome Date: Thu, 15 Jan 2009 04:04:45 +0000 Subject: Revert accidental svn keyword changes and add minor pylint fixes git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5027 ce84e21b-d406-0410-9b95-82705330c041 --- src/sbin/bcfg2-info | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/sbin/bcfg2-info') diff --git a/src/sbin/bcfg2-info b/src/sbin/bcfg2-info index cf369bd4d..bd04b599a 100755 --- a/src/sbin/bcfg2-info +++ b/src/sbin/bcfg2-info @@ -1,8 +1,8 @@ #!/usr/bin/python -i '''This tool loads the Bcfg2 core into an interactive debugger''' -__revision__ = '$Revision: 5014 $' +__revision__ = '$Revision$' -import copy, logging, lxml.etree, sys, time, cmd +import copy, logging, lxml.etree, sys, cmd import Bcfg2.Logger, Bcfg2.Server.Core, os import Bcfg2.Server.Plugins.Metadata, Bcfg2.Server.Plugin import Bcfg2.Options @@ -14,7 +14,8 @@ class dummyError(Exception): def printTabular(rows): '''print data in tabular format''' - cmax = tuple([max([len(str(row[index])) for row in rows]) + 1 for index in xrange(len(rows[0]))]) + cmax = tuple([max([len(str(row[index])) for row in rows]) + 1 \ + for index in xrange(len(rows[0]))]) fstring = (" %%-%ss |" * len(cmax)) % cmax fstring = ('|'.join([" %%-%ss "] * len(cmax))) % cmax print fstring % rows[0] @@ -282,7 +283,7 @@ Usage: [quit|exit]""" [cand.remove(c) for c in cand[:] if getattr(c.specific, field)] if len(cand) != 1: - print >>sys.stderr, "Entry %s failed" % cfile.get('name') + sys.stderr.write("Entry %s failed" % cfile.get('name')) continue print cand[0].name -- cgit v1.2.3-1-g7c22