How do I create a game that will run and then delete itself?

How do I create a game that will run and then delete itself? on OSX
I want the player to be able to press a button that will delete any trace of the game

I don’t think that you could do this for Unity.
But in C++ you could create other app that should delete your content, and then close.

But if it is possible to do this in Unity, than your app should probably ask
for Administration permissions.

And BTW i think this can be made with C# in Unity (not using Unity-declared functions and etc.)