in reply to regular expression for workdir

Another way:
print substr($path, index($path, $magic_word)+length($magic_word)+1);


holli, /regexed monk/