You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't think there's a way to accomplish this without adding the feature to the rule.
Yeah, that's what I was thinking. I feel like it makes sense, since the task object already has the concrete t.name that matched, to also have the matchdata.
I've not used a rule without dependencies, it gets triggered by a separate task that depends on the output (regexp)?
I.e. adding the ability to substitute in backreferences in the rule source. Currently, rule sources suffer from the same problem as the rule body: if you want to reference regex matchdata, you have to use a lambda as the dependency and re-apply the regex.
Activity
drbrain commentedon Jun 16, 2016
I think this would be a nice addition.
I don't think there's a way to accomplish this without adding the feature to the rule.
I've not used a rule without dependencies, it gets triggered by a separate task that depends on the output (regexp)?
avdi commentedon Jun 16, 2016
Yeah, that's what I was thinking. I feel like it makes sense, since the task object already has the concrete
t.namethat matched, to also have the matchdata.Yep.
avdi commentedon Jun 16, 2016
I've also thought about this:
I.e. adding the ability to substitute in backreferences in the rule source. Currently, rule sources suffer from the same problem as the rule body: if you want to reference regex matchdata, you have to use a lambda as the dependency and re-apply the regex.
yeban commentedon Dec 2, 2016
I stumbled upon this issue looking for how to access
matchdatainside a rule. This would be a great addition, imho.avdi commentedon Dec 2, 2016