topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Sunday December 15, 2024, 6:00 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Powershell problems  (Read 5689 times)

soulwanderer

  • Supporting Member
  • Joined in 2012
  • **
  • default avatar
  • Posts: 9
    • View Profile
    • Donate to Member
Powershell problems
« on: September 08, 2021, 07:15 AM »
Hello everybody, I am having a weird problem.

I want to create a list of aliases to use ssh on powershell ( because security reasons, there are systems I need to use via local port tunneled via SSH). The problem is I have quite a few and thougth about ordering them in an alias.

As an example, let's think I wanna run this:
powershell -noExit -Command "ssh"

If I run it (Windows + R, run) it works and shows the screen where ssh informs me that I need to enter some options.
If I open FARR, and type
run powershell -noExit -Command "ssh"
I get a command not found error.... (this also happens on an alias, using shellexec)

Any ideas? I am quite lost with this behaviour....

soulwanderer

  • Supporting Member
  • Joined in 2012
  • **
  • default avatar
  • Posts: 9
    • View Profile
    • Donate to Member
Re: Powershell problems
« Reply #1 on: September 08, 2021, 07:24 AM »
Sooooo yesterday I could not do it and today, five minutes after writing the post, I find a solution.....

I looked for powershell and run it from farr, and it worked, so I rigth clicked to create an alias and added the command afterwards.
It works like a charm!

I just type the solution in case someone finds this problem!

Nod5

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,169
    • View Profile
    • Donate to Member
Re: Powershell problems
« Reply #2 on: September 09, 2021, 09:56 AM »
If you have the new Windows Terminal you can also do
C:\Users\<username>\AppData\Local\Microsoft\WindowsApps\wt.exe powershell ssh

soulwanderer

  • Supporting Member
  • Joined in 2012
  • **
  • default avatar
  • Posts: 9
    • View Profile
    • Donate to Member
Re: Powershell problems
« Reply #3 on: September 10, 2021, 04:37 AM »
Thanks!