1
0
mirror of https://gitee.com/coder-xiaomo/gitee2github synced 2025-09-10 22:11:40 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee

单一py文件拆分为py文件模块,功能完成

This commit is contained in:
2022-03-17 01:16:26 +08:00
parent 91268f3bba
commit 876936e036
12 changed files with 685 additions and 377 deletions

13
assets/readConfigFile.py Normal file
View File

@@ -0,0 +1,13 @@
import configparser
def readConfigFile(configFilePath):
# 可以不考虑配置文件不存在的情况
# 实例化configParser对象
config = configparser.ConfigParser()
# -read读取ini文件
config.read(configFilePath, encoding='UTF-8') # GB18030
# -sections得到所有的section并以列表的形式返回
# configSections = config.sections()
return config
print("[info] 配置文件读取完成")