mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-08-10 13:27:41 +02:00
Updated check-repos.ps1
This commit is contained in:
@ -8,9 +8,9 @@
|
|||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./check-repos.ps1 C:\Repos
|
PS> ./check-repos.ps1 C:\Repos
|
||||||
⏳ Checking parent folder 📂C:\Repos... 16 subfolders
|
⏳ Checking parent folder 📂C:\Repos... 16 subfolders
|
||||||
⏳ Checking 📂rust repository (1/16)...
|
⏳ Checking repo 'rust' (1/16)...
|
||||||
...
|
...
|
||||||
✅ Checked all 16 Git repos in 📂C:\Repos in 356s.
|
✅ 16 Git repos checked at 📂C:\Repos in 356s.
|
||||||
.LINK
|
.LINK
|
||||||
https://github.com/fleschutz/PowerShell
|
https://github.com/fleschutz/PowerShell
|
||||||
.NOTES
|
.NOTES
|
||||||
@ -31,13 +31,13 @@ try {
|
|||||||
|
|
||||||
[int]$step = 1
|
[int]$step = 1
|
||||||
foreach ($folder in $folders) {
|
foreach ($folder in $folders) {
|
||||||
"`n⏳ Checking 📂$folder repository ($step/$numFolders)..."
|
"`n⏳ Checking repo '$folder' ($step/$numFolders)..."
|
||||||
& "$PSScriptRoot/check-repo.ps1" "$folder"
|
& "$PSScriptRoot/check-repo.ps1" "$folder"
|
||||||
$step++
|
$step++
|
||||||
}
|
}
|
||||||
|
|
||||||
[int]$elapsed = $stopWatch.Elapsed.TotalSeconds
|
[int]$elapsed = $stopWatch.Elapsed.TotalSeconds
|
||||||
"✅ Checked all $numFolders Git repos in 📂$parentDir in $($elapsed)s."
|
"✅ $numFolders Git repos checked at 📂$parentDir in $($elapsed)s."
|
||||||
exit 0 # success
|
exit 0 # success
|
||||||
} catch {
|
} catch {
|
||||||
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||||
|
Reference in New Issue
Block a user