jan-h
3/27/2015 - 3:10 PM

Fetch multiple GIT repos

Fetch multiple GIT repos

$ErrorActionPreference = "Stop" 

Function FetchRepo($directory)
{
	git -C $directory fetch
	if ($LASTEXITCODE -gt 0)
	{
		Throw "Something went wrong while fetching $directory"
	}
	Write-Host -ForegroundColor green "fetched $directory"
}

Write-Verbose "Fetching all DXA repos"

FetchRepo(".\content-management")
FetchRepo(".\dd4t-java")
FetchRepo(".\html-design")
FetchRepo(".\installation")
FetchRepo(".\web-application")
FetchRepo(".\web-application-java")