I'm using the Groovy Postbuild Plugin in Jenkins on Windows 7. I was trying 
to match strings in a file but when that failed, I reduced it to the point 
where I am just searching for a string in another string. It will never 
find a match. I must be misunderstanding how Groovy works or else it just 
isn't working in this plugin. Please tell me what I am doing wrong.

def txt = "slkd Cskk sdwo Csks swkdCsksl"
def matcher = txt  =~ /Cs/ 
if(matcher.matches()){
   manager.addShortText("match")
}
else {
   manager.addShortText("no match")
}

Thanks,
Rob

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/cbc1569e-959d-45a2-9ce2-f3acf3f021ec%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to