Last active
September 28, 2022 14:28
-
-
Save pradyumnac/4aaf21781f013b3997252a78c846fdf1 to your computer and use it in GitHub Desktop.
How to delete multi repositories in github ( Windows)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Deleting multi repositories from github in windows | |
1. Download & Install github CLI | |
2. Authenticate using `gh auth login` in windows command prompt ( Browser window will open) | |
3. Add extra permitions ( for delete) using `gh auth refresh -h github.com -s delete_repo ` from cmd | |
4. Ensure all your repos to be deleted are saved in a file `repos.txt` current folder in format "username":"reponame" | |
5. run the above batch file from same folder |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REm Make sure your current folder has the file repos.txt | |
for /f "tokens=*" %%f in (repos.txt) do ( | |
"C:\Program Files\GitHubCLI\gh" repo delete %%f --confirm | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment