Get-configs.gmp.py: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
(Die Seite wurde neu angelegt: „<pre> import sys res = gmp.get_configs() for i, conf in enumerate(res.xpath('config')): id = conf.xpath('@id')[0] name = conf.xpath('name/text()')[0]…“) |
(kein Unterschied)
|
Aktuelle Version vom 21. September 2020, 10:07 Uhr
import sys
res = gmp.get_configs()
for i, conf in enumerate(res.xpath('config')):
id = conf.xpath('@id')[0]
name = conf.xpath('name/text()')[0]
print('\n({0}) {1}: ({2})'.format(i, name, id))