In interpolation patterns, it could be useful to support a new modifier syntax for eg handling excludes in the target space:
dep = "./src/##.ts"
targets = "lib/##[~(index|module)].js"
where if a dependency resulted in the invalid target, it would be automatically ignored, and conversely if building a target in the exclude space, it wouldn't match the interpolation.
Ideally we should use some sensible existing pattern system.
#[name] has been talked about for named parameters in some interpolation use cases, perhaps we just disambiguate via syntax eg via #{name} for that instead.
Effectively this syntax just allows providing a custom pattern instead of the default of **/* to match. The hard part as always with interpolation is handling bi-directional mapping support.
In interpolation patterns, it could be useful to support a new modifier syntax for eg handling excludes in the target space:
where if a dependency resulted in the invalid target, it would be automatically ignored, and conversely if building a target in the exclude space, it wouldn't match the interpolation.
Ideally we should use some sensible existing pattern system.
#[name]
has been talked about for named parameters in some interpolation use cases, perhaps we just disambiguate via syntax eg via#{name}
for that instead.Effectively this syntax just allows providing a custom pattern instead of the default of
**/*
to match. The hard part as always with interpolation is handling bi-directional mapping support.