修正素材库通知配置写入格式
This commit is contained in:
parent
1a46152cc2
commit
eda7717975
@ -220,13 +220,13 @@ for line in lines:
|
||||
if '=' in line and not line.lstrip().startswith('#'):
|
||||
key = line.split('=', 1)[0].strip()
|
||||
if key in updates:
|
||||
output.append(key + '=' + quoted(updates[key]))
|
||||
output.append(key + '=' + str(updates[key]))
|
||||
seen.add(key)
|
||||
continue
|
||||
output.append(line)
|
||||
for key, value in updates.items():
|
||||
if key not in seen:
|
||||
output.append(key + '=' + quoted(value))
|
||||
output.append(key + '=' + str(value))
|
||||
source_path.write_text('\n'.join(output) + '\n', encoding='utf-8')
|
||||
os.chmod(source_path, 0o600)
|
||||
print('通知中心与素材库适配配置已写入')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user