REM Find the latest Discord app directory for /d %%a in ("%baseDir%\app-*") do set…
- User
REM Find the latest Discord app directory for /d %%a in ("%baseDir%\app-*") do set "latestAppDir=%%a"
if defined latestAppDir ( echo Opening latest Discord directory: "%latestAppDir%" explorer "%latestAppDir%"
codeREM Create a shortcut on the desktop set "shortcutName=Discord.lnk" set "targetPath=%latestAppDir%\Discord.exe") using the script provided, modify it so it uses powershell to create a discord.exe shortcut
- Assistant
To modify your batch script to use PowerShell for creating a Discord shortcut, you can use the following code snippet. This code identifies the latest Discord app directory, and then it creates a shortcut to
Discord.exeon the desktop using PowerShell.Here’s the modified script:
batch