Gitlab How To Cleanup Repository old history and keep the lasted version

hi I can using CI/CD and I find out my usage page my repository will keep increase.

how I can cleanup old repository and keep the lasted version only?

thanks for help.