Easy debuging is different goal and you can have infinity of such additional goals, but solution obviously can't be equally simple at everything at the same time (because of the conflict of responsilities).
3,319 karma · joined January 3, 2013
Easy debuging is different goal and you can have infinity of such additional goals, but solution obviously can't be equally simple at everything at the same time (because of the conflict of responsilities).
You can have very large number of layers, and to understand inner goings and interconnetions of all becomes very hard.
I highly doubt you can equalize "set of superb interfaces" with simplicity.
> You cannot use linux tools in PowerShell in most cases, since they aren't installed by default.
The same as jq and specific variants of tools you mention. Not like you can't install them in single line: winget/choco install awk,grep,jq,less...
> In the real world a lot of shell scripting requires parsing unstructured text from various command outputs and files.
No it doesn't. I do shell scripting for more then decade in PowerShell and I can count how many times I parsed the text. The most used one is simple split like with `$paths = $Env:PATH -split ';|:'`, but other then that no. I used select-string only couple of times in decade, on all OSes.
> but as soon as you step out of that comfort zone it becomes awkward to use.
That is true for literary anything. Actually pwsh does great with 'native' tools too, and there is even MS module to help with "native app wrapping". See [1] and [2]
Today its more or less regular to have json output which can be trivially read by pwsh ConvertFrom-Json
[1] https://devblogs.microsoft.com/powershell/native-commands-in....
[2] https://redmondmag.com/articles/2020/12/11/powershell-cresce...
Semantics. Nobody uses bash without those, and having different variants on them with different variants of regex is most troubling. Contrary to that, in pwsh it is recognized that those should be part of the shell that will behave the same on any OS. U ofcourse left out tone of those that come OTB in pwsh (like html/markdown/json/csv/sql readers and exporters vs jq,pandoc,usql,whatever)
> But, if I had to change anything about it, I would never choose objects. This is just replacing one problem with another with very little benefit.
You keep saying that without any evidence whatsoever. Its just a personal taste and you should declare it as such.
> Powershell can enfore types in function arguments
>> I know. This is awful. Especially for maintenance.
It looks to me that you dont actually have programming background, and that is the reason you say things like that. Your bash scripts the way you described them would probably be heavily reviewed and massaged where I work, for them to be accepted.
Compared to a flat list of related strings? No, its not. Its like saying that categorisation is worst then keeping everything in large bin.
> Comparing things becomes a nightmare.
Comparing objects deeply can be done in one line. If anything is nightmare, its people who judge without RTFM.
> So, it's OK to use it as a gimmick
I am amazed about lack of recognition on amount of work that MS and community have put into it (during two decades of gimmicking) :)
That is funny and shows tremendous lack of understading of shell complexity. Perhaps your own OS next ?
Obviously.
If you create pwsh script that is longer then equivalent bash script and more confusing, then you are doing it wrong. One almost never parses string in pwsh, unless string parsing is your primary task itself. Contrary, in bash, you always parse text, no matter what you want to do, which is defocusing and hard to maintain, and has cross-OS problems even in *nix land (solaris vs red had comes to mind and their respective ls/stat output which differs).
You can use both in pwsh on any OS.
Also, you can use linux tools in PowerShell, but that is not the point, it is back to stone age moment.
Shell scripts shouldn't be other name for text parsing.
Exactly. For serious projects (not to do lists) u will need humans, or equivalent (AI that is grown like one).
I will test out PowerShell. Thanks for providing links.
Mark Rusniovich's book Windows Internals is the one you want to understand architecture and kernel. Also, sysinternal tools.
For development, don't look at anything else but .NET 7+, since its FOSS, performant and cross platform. C# is also beutiful language.
For GUI, use MAUI, its the state of the art GUI framework that united all of the others U mention.
Use Windows Sandbox for testing, OTB virtual machine for single time use, and Docker Desktop for other stuff. Take a look at Sandboxie too.
Use package manager, winget, obviously, don't install anything else by hand.
Good luck, Windows is now enitrelly different beast then what you learned before
Was missing total commander but now that is solved with double commander.
More importantly its considerably larger and slower.
1. xdotool
2. sikuli
3. AHK_X11
v2 syntax and features are so much better. It was basically in development for a decade and AHK itself more then 20 years.
One is https://alerthn.com that does full text search on topics and commenets. It works great for years.
The other is http://www.hnreplies.com/ and it sends email on replies to your comments. It works good, but it stops after some time but you can subscribe again.
The project is also 15+ years old and continiously developed.
File system as db, markdown with templating and js expressions, nasting layouts, quick random endpoints, filtering of collections, named slots everything repo friendly - whats not to like. Also, great content and looking docs (particularly interactive tutorial).
Reminds me a lot of nanoc SSG framework (ruby).