gen: patch skeleton builder for more graceful template/section handling