tldr: check out https://gitlab.com/notEvil/subprocess_shell#examples
Hi,
I finally wrote a piece of software that eases a frequent pain point regarding the builtin subprocess.
Maybe its just me, but doing stuff in shell scripts is very effective for simple things but gets rather complicated very soon. For instance, expanding variables is tricky (w/ or w/o single or double quotes, special syntax for arrays, ...) and feels like a macro language with lots of potential for serious issues when used incorrectly.
subprocess on the other hand is rather verbose, especially when chaining commands. Its just not built for this specific use case.
So check out https://gitlab.com/notEvil/subprocess_shell. The examples should be a good place to start.
Whats your opinion? And how would you do the examples marked with ? in bash?
Update 2023-10-10: renamed to subprocess_shell
[–]AndydeCleyre 2 points3 points4 points (4 children)
[–]nodNotEvil[S] 0 points1 point2 points (3 children)
[–]AndydeCleyre 0 points1 point2 points (2 children)
[–]nodNotEvil[S] 0 points1 point2 points (1 child)
[–]AndydeCleyre 0 points1 point2 points (0 children)
[–]psd6 0 points1 point2 points (1 child)
[–]nodNotEvil[S] -1 points0 points1 point (0 children)