*: Replace ad-hoc regexes with {,l,r}strip

Signed-off-by: Niels Thykier <niels@thykier.net>