0

I have shortcut which under the hood performs something like that:

C:\Windows\System32\cmd.exe /C "powershell D:\ssh.ps1"

it executes ssh.ps1 script which inside opens SSH to ssh user@$ip where $ip comes from variable

but it executes inside cmd, meanwhile I'd want to start it inside Windows Terminal - how can I achieve that?

Axelly
  • 589
  • 3
  • 7
  • 26

1 Answers1

2

Assuming you have Window Terminal installed to the default location, it will be located here where USERNAME is your username: C:\Users\USERNAME\AppData\Local\Microsoft\WindowsApps\wt.exe

Create your shortcut with the starting location set to something like this: C:\Users\USERNAME\AppData\Local\Microsoft\WindowsApps\wt.exe powershell.exe -ExecutionPolicy Bypass -File D:\ssh.ps1

apena
  • 2,091
  • 12
  • 19
  • thanks, it worked! I previously used path like that: `C:\Program Files\WindowsApps\Microsoft.WindowsTerminal_1.0.1401.0_x64__8w...d8bbwe` – Axelly May 28 '20 at 17:48