4

I have couple of scripts that run with Powershell ISE on our windows servers, we have decided to make a MAC to be the server, so I want to run scripts on the MAC.

The reason I wrote it in Powershell ISE it because I wanted to make it easier for my team to run the script just by double tap -> insert something and the script run with the parameter.

Note: I dont want to use the "Powershell for Mac"

Oleg
  • 51
  • 1
  • 1
  • 2
  • If you don't want to use some "powershell port", the best thing IMHO is to rewrite it into a macOS-compatible script, like [tag:bash] scripts. Better yet, if you are planning to use both Windows and Mac, I recommend using cross-platform scripts (ex. Python) so that you only have to write your code once and execute (ideally) in both platforms. – Gino Mempin Jan 05 '20 at 10:59
  • I will give it a try, thanks for the advice – Oleg Jan 05 '20 at 14:17

2 Answers2

4

Visual Studio Code does everything Powershell ISE does and more, you just have to get used to the layout being a little different.

https://code.visualstudio.com/download

Nick Schroeder
  • 1,340
  • 1
  • 13
  • 17
  • VS Code won't give full compatibility with PS ISE. Editor - yes, but reading code from the editor and running in shell (F8) is different. Because of the way ISE reads the code and paste it in the shell. – Oleh Tarasenko Sep 23 '20 at 16:34
4

Agree with Nick Schroeder that the freely available Visual Studio Code is the way to go, but add that you should install the Powershell Extension (from Microsoft) and then enable ISE Mode. It's the closest you'll get to the Windows ISE and I can't say I've missed anything (outside of Windows Domain/Active Directory specific modules which obviously aren't available on Mac)

enter image description here

Roy Verrips
  • 371
  • 1
  • 3