包装器到configparser
pywrapper_config的Python项目详细描述
#pywrapprapper-config
wrapprapper-config
tests.conf文件:
````
[time]
pidfile\u超时=5
[server]
[ip=“127.0.0.0.0.1”
port=“8080”
```
``````
``````>
>sleep=3
[paths]>
[paths]>
==/标准输出=/dev/tty
标准输出=/dev/tty
[conex]
port=9080
```
>如何使用pywrapper配置:
```
impimpimpimpimppywrapper配置
config=pywrapper.pywrappapper.config(“./tests.conf”./tests.conf“/tests.conf”
show sections
打印打印(sections:{0}.0}.format(config.show.show\sections()))
>print(“项目服务器部分:{0}.format(config.show\u-item节(“server”))
show-ip-server
print(ip:{0}.format(config.show\u值物项(“server”,“ip”)))
show-config文件
print(config.show\u值物项(“server”,“ip”)))
show-config文件
print(config.cnffile)”.format(config.cnffile.format(config.cnffile:{0}.format(config.cnffile)
show-config文件
print(config.cnffile.conf file:{.0}.0}.format(config.cnffile))
prin
显示新的配置文件
打印(“secciones:{0}”。格式(config.show_sections()))
```
wrapprapper-config
tests.conf文件:
````
[time]
pidfile\u超时=5
[server]
[ip=“127.0.0.0.0.1”
port=“8080”
```
``````>
>sleep=3
[paths]>
[paths]>
==/标准输出=/dev/tty
标准输出=/dev/tty
[conex]
port=9080
```
>如何使用pywrapper配置:
```
impimpimpimpimppywrapper配置
config=pywrapper.pywrappapper.config(“./tests.conf”./tests.conf“/tests.conf”
show sections
打印打印(sections:{0}.0}.format(config.show.show\sections()))
>print(“项目服务器部分:{0}.format(config.show\u-item节(“server”))
show-ip-server
print(ip:{0}.format(config.show\u值物项(“server”,“ip”)))
show-config文件
print(config.show\u值物项(“server”,“ip”)))
show-config文件
print(config.cnffile)”.format(config.cnffile.format(config.cnffile:{0}.format(config.cnffile)
show-config文件
print(config.cnffile.conf file:{.0}.0}.format(config.cnffile))
prin
显示新的配置文件
打印(“secciones:{0}”。格式(config.show_sections()))
```