Files
CODEtomaste/Tool_Scripts/Whisper_Transcript/create_shortcut.ps1

26 lines
931 B
PowerShell
Raw Normal View History

# Create Desktop Shortcut for Voice Recorder
# Run this script once to create the shortcut
$scriptDir = Split-Path -Parent $MyInvocation.MyCommand.Definition
$batPath = Join-Path $scriptDir "VoiceRecorder.bat"
$icoPath = Join-Path $scriptDir "voice_recorder.ico"
$desktopPath = [Environment]::GetFolderPath("Desktop")
$shortcutPath = Join-Path $desktopPath "Voice Recorder.lnk"
# Create WScript Shell object
$WshShell = New-Object -ComObject WScript.Shell
$Shortcut = $WshShell.CreateShortcut($shortcutPath)
# Configure shortcut
$Shortcut.TargetPath = $batPath
$Shortcut.WorkingDirectory = $scriptDir
$Shortcut.IconLocation = $icoPath
$Shortcut.Description = "Voice Recorder - Record and transcribe voice memos to Obsidian"
$Shortcut.WindowStyle = 1 # Normal window
# Save shortcut
$Shortcut.Save()
Write-Host "Desktop shortcut created: $shortcutPath" -ForegroundColor Green
Write-Host "Icon: $icoPath" -ForegroundColor Cyan