can repos get deleted with redact in bulk?
redact mass deletes comments, stars, follows, and gists. if you want to delete your repos read this guide.
If youāre trying to wipe a bunch fast, youāve got a few real options:
-
Archive instead (way safer) makes them basically āgoneā from view but you can undo it if you panic later lol
-
GitHub CLI: easiest way to bulk manage stuff without clicking 200 times
-
API script: if you want rules like ādelete everything with prefix
test-ā or āolder than 2022ā or whatever
Before you go full send:
-
if any of these are org repos you might not even have permission or the org can block deletes
-
maybe do an archive pass first and then wait a day then delete once youāre sure you didnāt just yeet something important
you ever heard of repo reaper? Iāve never used it but have heard good things about it, itās made specifically to remove repos in bulk: https://reporeaper-frontend.onrender.com/
it was just released in Aug of 25ā, so not much feedback about it yet. if you decide to use it report back on how you like it, I am curious.
doesnt github allow for mass repo delting, like as a native feature within github admin? I believe they do. although, the fact someone made repo reaper maybe points to the contrary. I donāt know, Iām not a big github user.
No, @D-Mag is wrong actually. There are no mass delete options within github, you gotta use a 3rd party app.
I have personally used https://reposweeper.com/ and it worked as intended. They also have repo reaper, linked up above in triggerās post.
Read this: Bulk delete github repos Ā· GitHub
Use this trick to bulk delete your old repos or old forks
(Inspired by https://medium.com/@icanhazedit/clean-up-unused-github-rpositories-c2549294ee45#.3hwv4nxv5)
Open in a new tab all to-be-deleted github repositores (Use the mouseās middle click or Ctrl + Click) https://github.com/username?tab=repositories
Use one tab https://chrome.google.com/webstore/detail/onetab/chphlpgkkbolifaimnlloiipkdnihall to shorten them to a list.
Save that list to some path
The list should be in the form of āur_username\repo_nameā per line. Use regex search (Sublime text could help). Search for ā |.*ā and replace by empty.
Register a new personal access token with a ādelete_repo permā https://github.com/settings/tokens/new
Copy the access_token and run the following line replacing xxx with your access token.
Linux and OS X :
while read r;do curl -XDELETE -H 'Authorization: token xxx' "https://api.github.com/repos/$r ";done < reposWindows:
get-content D:\repolist.txt | ForEach-Object { Invoke-WebRequest -Uri https://api.github.com/repos/$_ -Method āDELETEā -Headers @{"Authorization"="token xxx"} }Caution
I have only tested this script on Linux.
fyi there is also a browser extension for deleting the repos https://chromewebstore.google.com/detail/npleadnddajjokllpjmpkekijopogeci?utm_source=item-share-cb
Iāve used that browser extension, it does what it says it does.