mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-08-10 05:17:44 +02:00
Improve the scripts
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/pwsh
|
||||
<#
|
||||
.SYNTAX speak-countdown.ps1 [start-number]
|
||||
.DESCRIPTION speaks a countdown by text-to-speech (TTS)
|
||||
.DESCRIPTION starts a countdown by text-to-speech (TTS)
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
#>
|
||||
@ -11,8 +11,9 @@ param([int]$StartNumber = 10)
|
||||
try {
|
||||
for ([int]$i = $StartNumber; $i -gt 0; $i--) {
|
||||
& "$PSScriptRoot/speak-english.ps1" $i
|
||||
start-sleep -milliseconds 1000
|
||||
start-sleep -milliseconds 200
|
||||
}
|
||||
& "$PSScriptRoot/speak-english.ps1" "zero"
|
||||
exit 0
|
||||
} catch {
|
||||
write-error "ERROR: line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||
|
Reference in New Issue
Block a user