Improve the scripts

This commit is contained in:
Markus Fleschutz
2021-05-17 19:53:40 +02:00
parent 61900ec1d9
commit 6ee8ea905f
6 changed files with 11 additions and 10 deletions

View File

@ -22,10 +22,10 @@ try {
$URL = $Row.URL
$DirName = $Row.Directory
if (test-path "$ParentDir/$DirName" -pathType container) {
"Skipping 📂$DirName because it exists already ..."
"Skipping 📂$DirName (exists already)..."
continue
}
"⏳ Cloning $URL to 📂$DirName ..."
"⏳ Cloning $URL to 📂$($DirName)..."
& git clone --recurse-submodules "$URL" "$ParentDir/$DirName"
if ($lastExitCode -ne "0") { throw "'git clone $URL' failed" }
$Count++

View File

@ -1,6 +1,6 @@
<#
.SYNTAX build-repo.ps1 [<repo-dir>]
.DESCRIPTION builds a Git repository (supporting cmake,configure,autogen,Imakefile,Makefile)
.SYNTAX make-repo.ps1 [<repo-dir>]
.DESCRIPTION builds a Git repository supporting cmake,configure,autogen,Imakefile,Makefile
.LINK https://github.com/fleschutz/PowerShell
.NOTES Author: Markus Fleschutz / License: CC0
#>

View File

@ -1,5 +1,5 @@
<#
.SYNTAX build-repos.ps1 [<parent-dir>]
.SYNTAX make-repos.ps1 [<parent-dir>]
.DESCRIPTION builds all Git repositories under the current/given directory
.LINK https://github.com/fleschutz/PowerShell
.NOTES Author: Markus Fleschutz / License: CC0
@ -17,7 +17,7 @@ try {
"Building $($Folders.Count) Git repositories at 📂$ParentDirName..."
foreach ($Folder in $Folders) {
& "$PSScriptRoot/build-repo.ps1" "$Folder"
& "$PSScriptRoot/make-repo.ps1" "$Folder"
}
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds