I pushed my code to github not realizing I had my access token in there. Which brings me to two questions
Is there anyway to hide a commit?
Is it really that bad to have your access token there?
Thank yoou
I pushed my code to github not realizing I had my access token in there. Which brings me to two questions
Is there anyway to hide a commit?
Is it really that bad to have your access token there?
Thank yoou
I had my access token in there
OOPs.
You cant hide commits but you can delete them from history.
You should use this tool:
https://rtyley.github.io/bfg-repo-cleaner/
It the prefect tool for this kind of task
BFG Repo-Cleaner
an alternative to git-filter-branch.
The BFG is a simpler, faster alternative to git-filter-branch for cleansing bad data out of your Git repository history:
- Removing Crazy Big Files
- Removing Passwords, Credentials & other Private data
In all these examples bfg is an alias for java -jar bfg.jar.
# Delete all files named 'id_rsa' or 'id_dsa' :
bfg --delete-files id_{dsa,rsa} my-repo.git