From 81f2da600ac742d733c8ede9000c0599815bd7d2 Mon Sep 17 00:00:00 2001 From: Markus Fleschutz Date: Thu, 18 Nov 2021 07:38:28 +0100 Subject: [PATCH] Add good-evening.ps1 and good-night.ps1 --- Scripts/good-evening.ps1 | 20 ++++++++++++++++++++ Scripts/good-night.ps1 | 20 ++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 Scripts/good-evening.ps1 create mode 100644 Scripts/good-night.ps1 diff --git a/Scripts/good-evening.ps1 b/Scripts/good-evening.ps1 new file mode 100644 index 00000000..03d8fdab --- /dev/null +++ b/Scripts/good-evening.ps1 @@ -0,0 +1,20 @@ +<# +.SYNOPSIS + Say an answer to 'good evening' +.DESCRIPTION + This script answers "good evening" by text-to-speech (TTS). +.EXAMPLE + PS> ./good-evening +.NOTES + Author: Markus Fleschutz · License: CC0 +.LINK + https://github.com/fleschutz/PowerShell +#> + +try { + & "$PSScriptRoot/speak-english.ps1" "And a special good evening to you too" + exit 0 # success +} catch { + "⚠️ Error: $($Error[0]) ($($MyInvocation.MyCommand.Name):$($_.InvocationInfo.ScriptLineNumber))" + exit 1 +} diff --git a/Scripts/good-night.ps1 b/Scripts/good-night.ps1 new file mode 100644 index 00000000..691abac6 --- /dev/null +++ b/Scripts/good-night.ps1 @@ -0,0 +1,20 @@ +<# +.SYNOPSIS + Say an answer to 'good night' +.DESCRIPTION + This script answers "good night" by text-to-speech (TTS). +.EXAMPLE + PS> ./good-night +.NOTES + Author: Markus Fleschutz · License: CC0 +.LINK + https://github.com/fleschutz/PowerShell +#> + +try { + & "$PSScriptRoot/speak-english.ps1" "Good night to you, my friend." + exit 0 # success +} catch { + "⚠️ Error: $($Error[0]) ($($MyInvocation.MyCommand.Name):$($_.InvocationInfo.ScriptLineNumber))" + exit 1 +}