]> git.phdru.name Git - xsetbg.git/commitdiff
Fix(py3): Use `configparser` instead of `ConfigParser`
authorOleg Broytman <phd@phdru.name>
Sat, 24 Feb 2024 15:19:47 +0000 (18:19 +0300)
committerOleg Broytman <phd@phdru.name>
Sat, 24 Feb 2024 15:19:47 +0000 (18:19 +0300)
xsetbg_conf.py

index b1b6656b32d2a788a874bfe79a46eb5bf4b86765..1e54e6cccf34bbdd042eba66bca62bb651bcd870 100755 (executable)
@@ -4,7 +4,7 @@
 """
 
 import os
-from ConfigParser import SafeConfigParser
+from configparser import ConfigParser
 
 __all__ = ['xsetbg_conf']
 
@@ -23,7 +23,7 @@ config_dirs.append(xsetbg_dir)
 for d in config_dirs:
     xsetbg_conf_file = os.path.join(d, 'xsetbg.conf')
     if os.path.exists(xsetbg_conf_file):
-        xsetbg_conf = SafeConfigParser()
+        xsetbg_conf = ConfigParser(inline_comment_prefixes=(';', '#'))
         xsetbg_conf.read(xsetbg_conf_file)
         break
 else: