commit setconf for openSUSE:Factory
Hello community, here is the log from the commit of package setconf for openSUSE:Factory checked in at 2014-12-19 09:38:55 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/setconf (Old) and /work/SRC/openSUSE:Factory/.setconf.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "setconf" Changes: -------- --- /work/SRC/openSUSE:Factory/setconf/setconf.changes 2014-10-22 16:23:22.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.setconf.new/setconf.changes 2014-12-19 09:37:54.000000000 +0100 @@ -1,0 +2,6 @@ +Thu Dec 19 21:39:18 UTC 2014 - sor.alexei@meowr.ru + +- Update to 0.6.4: + * Better error messages when write permissions are denied. + +------------------------------------------------------------------- Old: ---- setconf-0.6.3.tar.xz New: ---- setconf-0.6.4.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ setconf.spec ++++++ --- /var/tmp/diff_new_pack.xdoRuy/_old 2014-12-19 09:37:56.000000000 +0100 +++ /var/tmp/diff_new_pack.xdoRuy/_new 2014-12-19 09:37:56.000000000 +0100 @@ -17,7 +17,7 @@ Name: setconf -Version: 0.6.3 +Version: 0.6.4 Release: 0 Summary: Utility to easily change settings in configuration files License: GPL-2.0+ ++++++ setconf-0.6.3.tar.xz -> setconf-0.6.4.tar.xz ++++++ Files old/setconf-0.6.3/setconf.1.gz and new/setconf-0.6.4/setconf.1.gz differ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setconf-0.6.3/setconf.py new/setconf-0.6.4/setconf.py --- old/setconf-0.6.3/setconf.py 2014-10-13 16:23:10.000000000 +0200 +++ new/setconf-0.6.4/setconf.py 2014-12-03 13:25:32.000000000 +0100 @@ -19,6 +19,7 @@ # Nov 2013 # Aug 2014 # Oct 2014 +# Dec 2014 # from sys import argv @@ -30,7 +31,7 @@ # TODO: Use optparse or argparse if shedskin is no longer a target. -VERSION = "0.6.3" +VERSION = "0.6.4" ASSIGNMENTS = ['==', '=>', '=', ':=', '::', ':'] def get_encoding(filename): @@ -171,7 +172,11 @@ changed_contents += linesep if dummyrun: return data != changed_contents - file = open(filename, "w") + try: + file = open(filename, "w") + except IOError: + print("No write permission: %s" % (filename)) + sysexit(2) file.write(changed_contents) file.close() @@ -188,7 +193,11 @@ print("Can't read %s" % (filename)) sysexit(2) # Change and write the file - file = open(filename, "w") + try: + file = open(filename, "w") + except IOError: + print("No write permission: %s" % (filename)) + sysexit(2) lines.append(line) added_data = linesep.join(lines) + linesep file.write(added_data) @@ -487,7 +496,11 @@ def create_if_missing(filename): if not exists(filename): - f = open(filename, "w") + try: + f = open(filename, "w") + except IOError: + print("No write permission: %s" % (filename)) + sysexit(2) f.close() -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org
participants (1)
-
root@hilbert.suse.de