fix pattern injection for build task.