Ansible is like Python but for scripting (orchestration). They used a YAML format and with all the curly braces and quoting, made it just as bad as shell.
Re:Pure Sh Bible
by wirthjason on Monday May 01, 2023 @08:05AM
(#35771644)
What would make Python better for command line use? Better alternatives to argparse in the standard library?
Sorry, I was sloppy. I meant using it as the system shell. So, processing arguments, I guess, would be less of a big deal.
Convenience features, like ls and other classic shell commands being run without parentheses would have to be handled… I’m not breaking any new ground here, actually this has gotten me to look into xonsh and it looks pretty decent.
Re:Pure Sh Bible
by awaythrow98765 on Monday May 01, 2023 @05:33PM
(#35779481)
Easier, lightweight syntax for shell-like pipes, command execution and catching stdin/stdout/stderr.
Something like Perl's IPC::Run.
Also, more shell-relevant stuff in the default distribution, so that one doesn't need to care about any modules (which is the primary reason for using bash or even sh, those are installed practically everywhere along with at least coreutils and stuff).
But the sister comment clarified it in another way, so this maybe irrelevant.
But, every time I see examples of how to write sh scripts properly, it makes me wonder if this is just the wrong way to look at the world. Maybe it would be easier to extend Python down to make it better for command line use. Xonsh or something.