use regex substitution to avoid package names cut