commit:     70adaeef4a48570f7a27e845c6e4c81256a202f3
Author:     Devan Franchini <twitch153 <AT> gentoo <DOT> org>
AuthorDate: Wed May 14 18:54:56 2014 +0000
Commit:     Devan Franchini <twitch153 <AT> gentoo <DOT> org>
CommitDate: Wed May 14 18:54:56 2014 +0000
URL:        
http://git.overlays.gentoo.org/gitweb/?p=proj/layman.git;a=commit;h=70adaeef

layman/{output, version}.py: Updates print() functions

---
 layman/output.py  | 16 ++++++++--------
 layman/version.py |  2 +-
 2 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/layman/output.py b/layman/output.py
index 48b44a1..ea98894 100644
--- a/layman/output.py
+++ b/layman/output.py
@@ -133,7 +133,7 @@ class Message(MessageBase):
             return
 
         for i in info.split('\n'):
-            print  >> self.std_out, self.color_func('yellow', 'DEBUG: ') + i
+            print(self.color_func('yellow', 'DEBUG: ') + i, file=self.std_out)
 
 
     def notice (self, note, level = NOTE_LEVEL):
@@ -141,7 +141,7 @@ class Message(MessageBase):
         if level > self.note_lev:
             return
 
-        print >> self.std_out, note
+        print(note, file=self.std_out)
 
 
     def info (self, info, level = INFO_LEVEL):
@@ -153,7 +153,7 @@ class Message(MessageBase):
             return
 
         for i in info.split('\n'):
-            print  >> self.std_out, " %s %s" % (self.color_func('green', 
'*'),i)
+            print(" %s %s" % (self.color_func('green', '*'),i), 
file=self.std_out)
 
 
     def status (self, message, status, info = 'ignored'):
@@ -167,7 +167,7 @@ class Message(MessageBase):
             return
 
         for i in lines[0:-1]:
-            print >> self.std_out, " %s %s" % (self.color_func('green', '*'),i)
+            print(" %s %s" % (self.color_func('green', '*'),i), 
file=self.std_out)
 
         i = lines[-1]
 
@@ -181,8 +181,8 @@ class Message(MessageBase):
         else:
             result = '[' + self.color_func('yellow', info) + ']'
 
-        print >> " %s %s %s %S" % (self.color_func('green', '*'), i,
-            ('.' * (58 - len(i))), result)
+        print(file=" %s %s %s %S" % (self.color_func('green', '*'), i,
+            ('.' * (58 - len(i))), result))
 
 
     def warn (self, warn, level = WARN_LEVEL):
@@ -194,7 +194,7 @@ class Message(MessageBase):
             return
 
         for i in warn.split('\n'):
-            print >> self.std_out, " %s %s" % (self.color_func('yellow', 
'*'),i)
+            print(" %s %s" % (self.color_func('yellow', '*'),i), 
file=self.std_out)
 
 
     def error (self, error):
@@ -208,7 +208,7 @@ class Message(MessageBase):
             # "layman -L |& less".
             self.std_out.flush()
             self.error_out.flush()
-            print >> self.std_out, " %s %s" % (self.color_func('red', '*'), i)
+            print(" %s %s" % (self.color_func('red', '*'), i), 
file=self.std_out)
             self.std_out.flush()
         self.do_error_callback(error)
 

diff --git a/layman/version.py b/layman/version.py
index 90c7412..276ee86 100644
--- a/layman/version.py
+++ b/layman/version.py
@@ -25,4 +25,4 @@ __version__ = "$Id: version.py 309 2007-04-09 16:23:38Z 
wrobel $"
 VERSION = '2.0.0-git'
 
 if __name__ == '__main__':
-    print VERSION
+    print(VERSION)

Reply via email to