in reply to Regex problem
#seems like the string "branch from" is not matching since $1 below prints nothing
$1 refers to text matched by the first set of capturing parens (if any). Since your regex:
if ($line =~ /branch from/)
doesn't contain any capturing parens, $1 will never be set.
|
|---|