Reg Ex help

Paddy paddy3118 at netscape.net
Fri May 12 01:47:28 EDT 2006


If you have strings of all the CHECKEDOUT (is this from the lsco
command?), then the following might work for you:

>>> s ="/main/parallel_branch_1/release_branch_1.0/dbg_for_python/CHECKEDOUT from /main/parallel_branch_1/release_branch_1.0/4"
>>> s.split()[0].split('/')[-2]
'dbg_for_python'
>>> 

- Paddy.




More information about the Python-list mailing list