Skip to content

Instantly share code, notes, and snippets.

View lawrence-jeff's full-sized avatar

lawrence-jeff

View GitHub Profile
@lawrence-jeff
lawrence-jeff / SaveLinestoWav.ps1
Last active March 28, 2018 18:19
Takes a text file of statements and converts each to a wav file via speech synthesis
#Based on https://gist.github.com/lazywinadmin/51619a0e47f4c8e7a8b7
Add-Type -AssemblyName System.speech
mkdir C:\users\$env:username\Desktop\Compliments
#Populate list of statements/compliments to read
$Statements=Get-Content "C:\users\$env:username\Desktop\Compliments.txt"
$FileName= 1
foreach ($Statement in $Statements)
{
$speak = New-Object System.Speech.Synthesis.SpeechSynthesizer
$speak.SelectVoice('Microsoft Zira Desktop')
@lawrence-jeff
lawrence-jeff / gist:f5a2b62606bb5340593403db86c07272
Created March 23, 2018 18:27
Take a file of one line statements - save each as a voice wav file
#Based on https://gist.github.com/lazywinadmin/51619a0e47f4c8e7a8b7
Add-Type -AssemblyName System.speech
mkdir C:\users\$env:username\Desktop\Compliments
#Populate list of statements/compliments to read
$Statements=Get-Content "C:\users\$env:username\Desktop\Compliments.txt"
$FileName= 1
foreach ($Statement in $Statements)
{
$speak = New-Object System.Speech.Synthesis.SpeechSynthesizer
$speak.SelectVoice('Microsoft Zira Desktop')