From 593672fd88755e9cb3e1ef691b78501e1a4d5ab0 Mon Sep 17 00:00:00 2001 From: Verayth Date: Sun, 28 Apr 2019 18:08:29 -0400 Subject: [PATCH] 2013.03.07 saveSettings: Clear ReadOnly flag if set 2019.04.28: is still a problem for Fallout.INI if set RO by Nexus Mod Manager --- Mopy/bash/bosh.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Mopy/bash/bosh.py b/Mopy/bash/bosh.py index 18457ce..6eeff7b 100644 --- a/Mopy/bash/bosh.py +++ b/Mopy/bash/bosh.py @@ -10781,6 +10781,11 @@ def saveSettings(self, ini_settings): reComment = self.reComment reSection = self.reSection reSetting = self.reSetting + # Clear ReadOnly flag if set + cmd = r'attrib -R "%s" /S /D' % (self.path) + cmd = Encode(cmd) + ins, err = Popen(cmd, stdout=PIPE, stdin=PIPE, + startupinfo=startupinfo).communicate() # --Read init, write temp iniFile = self.path.open('r') tmpFile = self.path.temp.open('w')