提交 7cf88ef8 编写于 作者: M MRXLT

fix conflict

上级 f867263c
...@@ -23,7 +23,11 @@ def update_info(file_name, feature, info): ...@@ -23,7 +23,11 @@ def update_info(file_name, feature, info):
with open(file_name, "r") as f: with open(file_name, "r") as f:
for line in f.readlines(): for line in f.readlines():
if re.match(feature, line): if re.match(feature, line):
line = feature + " = \"" + info.strip() + "\"\n" if isinstance(info, str):
line = feature + " = \"" + info.strip() + "\"\n"
else:
line = feature + " = \"" + info.decode('utf-8').strip(
) + "\"\n"
new_str = new_str + line new_str = new_str + line
with open(file_name, "w") as f: with open(file_name, "w") as f:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册