r/sysadmin • Systems Engineer • Aug 18 '16

PowerShell is open source, available for Linux and OS X

https://github.com/PowerShell/PowerShell
1.3k Upvotes

369 comments sorted by

View all comments

Show parent comments

12

u/masta Aug 18 '16 edited Aug 18 '16

This has been mentioned before, and shot down again and again.

Every blue-sky scripting language seems to have some form of interactive interpreter along-side the byte-code compiler & runtime.

One of the problems here is these advanced scripting languages were not designed to be interactive shells, with scripting as secondary. They are scripting first, and interactive last. For example, python has a great set of built-in commands, and datatypes. But running external commands still means you have to system('foo','bar-arg','blah-arg') your way out... But that is an implementation details really... it could be made to work, but it's not the only issue to solve.

I'm not saying python is a bad choice, but it's not the right choice, else it would be the Posix shell already (or Perl would have, etc)

6

u/theevilsharpie Jack of All Trades Aug 18 '16

I'm not advocating for the use of Python as a shell. I'm saying that Python is available if your scripting needs require more advanced data structures than what Shell provides.

Shell's design has always been optimized for fast interactive performance. Adding features to the core language necessarily makes the language more verbose, which makes it more difficult to use interactively from a UX perspective. PowerShell is a perfect example of that trade-off in action.