Skip to content

Instantly share code, notes, and snippets.

@JohannesHoppe
Last active August 18, 2016 20:57
Show Gist options
  • Save JohannesHoppe/8fcfa557f6a05830fd982d5f70a7b419 to your computer and use it in GitHub Desktop.
Save JohannesHoppe/8fcfa557f6a05830fd982d5f70a7b419 to your computer and use it in GitHub Desktop.
git_fetch_all.cmd
@echo off
%~d0
CD "%~dp0"
echo ##### Fetching all repositories from Git #####
for /D %%i in (*.*) do call :handlerepo %%i
EXIT /B 0
:handlerepo
echo.
cd %*
IF EXIST .git (
for %%* in (.) do echo ----- fetching %%~nx* -----
git fetch --verbose
)
cd ..
EXIT /B 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment