mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-04-23 18:38:19 +02:00
Update play-happy-birthday.ps1
This commit is contained in:
parent
7501f71794
commit
e73e26f9e7
@ -4,36 +4,42 @@
|
|||||||
.DESCRIPTION
|
.DESCRIPTION
|
||||||
This PowerShell script plays the famous Happy Birthday song.
|
This PowerShell script plays the famous Happy Birthday song.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./play-happy-birthday
|
PS> ./play-happy-birthday.ps1
|
||||||
|
(listen and enjoy)
|
||||||
.LINK
|
.LINK
|
||||||
https://github.com/fleschutz/PowerShell
|
https://github.com/fleschutz/PowerShell
|
||||||
.NOTES
|
.NOTES
|
||||||
Author: Markus Fleschutz | License: CC0
|
Author: Markus Fleschutz | License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
[System.Console]::Beep(1059.274, 300)
|
try {
|
||||||
[System.Console]::Beep(1059.274, 200)
|
[System.Console]::Beep(1059.274, 300)
|
||||||
[System.Console]::Beep(1188.995, 500)
|
[System.Console]::Beep(1059.274, 200)
|
||||||
[System.Console]::Beep(1059.274, 500)
|
[System.Console]::Beep(1188.995, 500)
|
||||||
[System.Console]::Beep(1413.961, 500)
|
[System.Console]::Beep(1059.274, 500)
|
||||||
[System.Console]::Beep(1334.601, 950)
|
[System.Console]::Beep(1413.961, 500)
|
||||||
[System.Console]::Beep(1059.274, 300)
|
[System.Console]::Beep(1334.601, 950)
|
||||||
[System.Console]::Beep(1059.274, 200)
|
[System.Console]::Beep(1059.274, 300)
|
||||||
[System.Console]::Beep(1188.995, 500)
|
[System.Console]::Beep(1059.274, 200)
|
||||||
[System.Console]::Beep(1059.274, 500)
|
[System.Console]::Beep(1188.995, 500)
|
||||||
[System.Console]::Beep(1587.117, 500)
|
[System.Console]::Beep(1059.274, 500)
|
||||||
[System.Console]::Beep(1413.961, 950)
|
[System.Console]::Beep(1587.117, 500)
|
||||||
[System.Console]::Beep(1059.274, 300)
|
[System.Console]::Beep(1413.961, 950)
|
||||||
[System.Console]::Beep(1059.274, 200)
|
[System.Console]::Beep(1059.274, 300)
|
||||||
[System.Console]::Beep(2118.547, 500)
|
[System.Console]::Beep(1059.274, 200)
|
||||||
[System.Console]::Beep(1781.479, 500)
|
[System.Console]::Beep(2118.547, 500)
|
||||||
[System.Console]::Beep(1413.961, 500)
|
[System.Console]::Beep(1781.479, 500)
|
||||||
[System.Console]::Beep(1334.601, 500)
|
[System.Console]::Beep(1413.961, 500)
|
||||||
[System.Console]::Beep(1188.995, 500)
|
[System.Console]::Beep(1334.601, 500)
|
||||||
[System.Console]::Beep(1887.411, 300)
|
[System.Console]::Beep(1188.995, 500)
|
||||||
[System.Console]::Beep(1887.411, 200)
|
[System.Console]::Beep(1887.411, 300)
|
||||||
[System.Console]::Beep(1781.479, 500)
|
[System.Console]::Beep(1887.411, 200)
|
||||||
[System.Console]::Beep(1413.961, 500)
|
[System.Console]::Beep(1781.479, 500)
|
||||||
[System.Console]::Beep(1587.117, 500)
|
[System.Console]::Beep(1413.961, 500)
|
||||||
[System.Console]::Beep(1413.961, 900)
|
[System.Console]::Beep(1587.117, 500)
|
||||||
exit 0 # success
|
[System.Console]::Beep(1413.961, 900)
|
||||||
|
exit 0 # success
|
||||||
|
} catch {
|
||||||
|
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user