Re:Bashing the Bash – Replacing Shell Scripts with Python (2...
by derekbaker783 on Saturday March 26, 2022 @12:41AM
(#30809280)
What is Powershell
Re:Bashing the Bash – Replacing Shell Scripts with Python (2...
by DyslexicAtheist on Saturday March 26, 2022 @05:44AM
(#30810503)
I just added powershell support to my Debian.
$> ll /bin/powershell
lrwxrwxrwx 1 root root 9 Mar 26 14:40 /bin/powershell -> /bin/dash
$> cat ~/pwr_to_the_people.sh
#!/bin/powershell
echo "Hello Powershell"
$> powershell ~/pwr_to_the_people.sh
Hello Powershell
Works like a charm!
Good news, they did! Even better news: it doesn't require python, it's cross platform, and supports an easy-to-read verbose style for scripts but a quick-to-write terse style for interactive usage. It's an absolute joy to use for nested data structures, everything is an object and it has full native tab completion.
Unfortunately it came out of Microsoft so a lot of people haven't given it the time of day yet. It's honestly one of the joys of modern CLI usage though.