Improve output of both scripts

This commit is contained in:
Markus Fleschutz 2021-07-04 20:46:39 +02:00
parent 8733e87c4c
commit 1995c56a2a
2 changed files with 3 additions and 3 deletions

View File

@ -18,12 +18,12 @@ try {
$Folders = (get-childItem "$ParentDir" -attributes Directory)
$FolderCount = $Folders.Count
$ParentDirName = (get-item "$ParentDir").Name
"Found $FolderCount subfolders in 📂$ParentDirName..."
"Found $FolderCount subfolders in 📂$ParentDirName, cleaning from untracked files..."
[int]$Step = 1
foreach ($Folder in $Folders) {
$FolderName = (get-item "$Folder").Name
"🧹 Cleaning 📂$FolderName from untracked files (#$Step/$FolderCount)..."
"🧹 Cleaning 📂$FolderName ($Step/$FolderCount)..."
& git -C "$Folder" clean -xfd -f # force + recurse into dirs + don't use the standard ignore rules
if ($lastExitCode -ne "0") { throw "'git clean -xfd -f' failed" }

View File

@ -23,7 +23,7 @@ try {
[int]$Step = 1
foreach ($Folder in $Folders) {
$FolderName = (get-item "$Folder").Name
"🢃 Pulling 📂$FolderName (#$Step/$FolderCount)..."
"🢃 Pulling 📂$FolderName ($Step/$FolderCount)..."
& git -C "$Folder" pull --recurse-submodules --jobs=4
if ($lastExitCode -ne "0") { write-warning "'git pull' on 📂$FolderName failed" }