We use git together with our iOS app, and we're now planning to make the app's code open source. The problem is we don't want people to have access to our API keys because the API itself shouldn't be accessible by the public.
The API keys are all in APIConstants.h
and .m
. I'm thinking of unstaging them in future commits, but I understand that people can still check out older commits. Is there any way I can disable the checking out of those two files even from older commits?
The other solution I can think of is deleting the .git
folder altogether, add APIConstants
to the .gitignore
, and doing git init
again at the expense of deleting all of our commit history.