toolsutils.py
branchstable
changeset 7155 4bab50b02927
parent 6495 3187112bc7cc
child 7301 93e96700e0c0
--- a/toolsutils.py	Thu Mar 31 15:18:21 2011 +0200
+++ b/toolsutils.py	Thu Mar 31 17:12:27 2011 +0200
@@ -58,12 +58,12 @@
     """create a directory if it doesn't exist yet"""
     try:
         makedirs(directory)
-        print '-> created directory %s.' % directory
+        print '-> created directory %s' % directory
     except OSError, ex:
         import errno
         if ex.errno != errno.EEXIST:
             raise
-        print '-> directory %s already exists, no need to create it.' % directory
+        print '-> no need to create existing directory %s' % directory
 
 def create_symlink(source, target):
     """create a symbolic link"""
@@ -154,9 +154,9 @@
 def restrict_perms_to_user(filepath, log=None):
     """set -rw------- permission on the given file"""
     if log:
-        log('set %s permissions to 0600', filepath)
+        log('set permissions to 0600 for %s', filepath)
     else:
-        print '-> set %s permissions to 0600' % filepath
+        print '-> set permissions to 0600 for %s' % filepath
     chmod(filepath, 0600)
 
 def read_config(config_file):