um anyone know how i can remove comments from every file in a folder

my datapack is filled with comments which makes it not work on older versions. Going manually takes a while so idk maybe some thing where it just removes all comments //
Continue to help post