Update fetch-repos.ps1 and pull-repos.ps1

This commit is contained in:
Markus Fleschutz 2022-09-19 19:43:17 +02:00
parent c35c7b2786
commit 28a33e074c
2 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ try {
if (-not(Test-Path "$ParentDir" -pathType container)) { throw "Can't access folder: $ParentDir" }
$Folders = (Get-ChildItem "$ParentDir" -attributes Directory)
$NumFolders = $Folders.Count
"Found $NumFolders subfolders."
"Found $NumFolders subfolders, fetching one by one..."
[int]$Step = 3
foreach ($Folder in $Folders) {
@ -41,7 +41,7 @@ try {
}
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
"✔️ fetched $NumFolders Git repos at 📂$ParentDirName in $Elapsed sec"
"✔️ fetched $NumFolders Git repos in 📂$ParentDirName, it took $Elapsed sec"
exit 0 # success
} catch {
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"

View File

@ -27,7 +27,7 @@ try {
if (-not(Test-Path "$ParentDir" -pathType container)) { throw "Can't access folder: $ParentDir" }
$Folders = (Get-ChildItem "$ParentDir" -attributes Directory)
$NumFolders = $Folders.Count
"Found $NumFolders subfolders."
"Found $NumFolders subfolders, pulling one by one..."
[int]$Step = 3
[int]$Failed = 0
@ -45,7 +45,7 @@ try {
}
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
"✔️ pulled $NumFolders Git repos at 📂$ParentDirName in $Elapsed sec ($Failed failed)"
"✔️ pulled $NumFolders Git repos in 📂$ParentDirName ($Failed failed, it took $Elapsed sec)"
exit 0 # success
} catch {
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"