> >>>> {'struct': 'data_block', 'log_file': '/var/1000111/test18.log', 'loc': > '0', 'size': '8'} > > MARB, as usual the solution you you look nice, Thanks for the excellent solutions
>>> regex = re.compile (r"--(struct|loc|size|mirror|l og_file)\s*=\s*([^\s]+)") >>> regex.findall (line) [('struct', 'data_block'), ('log_file', '/var/1000111/test18.log'), ('loc', '0'), ('mirror', '10')] Frederic , this look great, thanks for your response -- https://mail.python.org/mailman/listinfo/python-list