mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-01-14 18:08:43 +01:00
Update clean-repo.ps1 and switch-branch.ps1
This commit is contained in:
parent
4c0a77c2c7
commit
8d0522358d
@ -12,7 +12,7 @@
|
||||
⏳ (2/4) Checking local repository... 📂C:\rust
|
||||
⏳ (3/4) Removing untracked files in repository...
|
||||
⏳ (4/4) Removing untracked files in submodules...
|
||||
✔️ Cleaning repository 📂rust took 1 sec
|
||||
✔️ Cleaning repo 📂rust took 1 sec
|
||||
.LINK
|
||||
https://github.com/fleschutz/PowerShell
|
||||
.NOTES
|
||||
@ -45,7 +45,7 @@ try {
|
||||
if ($lastExitCode -ne "0") { throw "'git clean' in the submodules failed with exit code $lastExitCode" }
|
||||
|
||||
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
|
||||
"✔️ Cleaning repository 📂$RepoDirName took $Elapsed sec"
|
||||
"✔️ Cleaning repo 📂$RepoDirName took $Elapsed sec"
|
||||
exit 0 # success
|
||||
} catch {
|
||||
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
@ -52,7 +52,7 @@ try {
|
||||
if ($lastExitCode -ne "0") { throw "'git submodule update' failed with exit code $lastExitCode" }
|
||||
|
||||
[int]$Elapsed = $StopWatch.Elapsed.TotalSeconds
|
||||
"✔️ switched repo 📂$RepoDirName to branch '$BranchName' in $Elapsed sec"
|
||||
"✔️ Switching repo 📂$RepoDirName to branch '$BranchName' took $Elapsed sec"
|
||||
exit 0 # success
|
||||
} catch {
|
||||
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
Loading…
Reference in New Issue
Block a user