I wrote an bash enumerator because I was sick of xargs
141–150 of 202 posts
Re: I wrote an bash enumerator because I was sick of xargs
#142I wonder if the generation one or two before mine grew up without shells and then had to make them and had no particular preconceptions, but my generation grew up treating the way shells work as a law of physics and thus doesn't innovate. Actually I wonder how much ossification is explained by this in general.
Re: I wrote an bash enumerator because I was sick of xargs
#143In this thread: bash experts with arcane knowledge, unintentionally demonstrating how awful bash is. The obvious solution would be to use something more sane, like PowerShell or nushell, but instead old experts will always defend the skills they have honed for years, while criticizing anything that's different.
Re: I wrote an bash enumerator because I was sick of xargs
#144I lol'd, but do you think this is valid? https://github.com/wallach-game/bashumerate/pull/1/files to me looks like a right solution, even if I was also tired of writing for loops by hand usually
Re: I wrote an bash enumerator because I was sick of xargs
#145You need to establish that every program's interpretation points to the same object before processing the object through the command chain. Stopping a bad command is more important than running the good ones.
There is no tool that does this one job.
Re: I wrote an bash enumerator because I was sick of xargs
#146There's room for so much more innovation in the shell space. Microsoft did it with PowerShell - Linux seems to be stuck in the 1980s. You do have newer shells like fish, but they seem to only mess with the on-screen layout of the command prompt (while being stupid enough to still run within a terminal) and not the commands themselves. I wonder if the generation one or two before mine grew up without shells and then h…
I think the whole concept could be rewritten from the ground up to be modern, but reaching critical mass and mvp is too damn difficult, and the majority of mac/Linux users probably don’t want it.
Re: I wrote an bash enumerator because I was sick of xargs
#147There's room for so much more innovation in the shell space. Microsoft did it with PowerShell - Linux seems to be stuck in the 1980s. You do have newer shells like fish, but they seem to only mess with the on-screen layout of the command prompt (while being stupid enough to still run within a terminal) and not the commands themselves. I wonder if the generation one or two before mine grew up without shells and then h…
Shells imo are legacy on legacy, I like bash and zsh, they’re nonsensical but they work. Powershell is undoubtedly saner, but I hate it. I think the whole concept could be rewritten from the ground up to be modern, but reaching critical mass and mvp is too damn difficult, and the majority of mac/Linux users probably don’t want it.
Re: I wrote an bash enumerator because I was sick of xargs
#148In this thread: bash experts with arcane knowledge, unintentionally demonstrating how awful bash is. The obvious solution would be to use something more sane, like PowerShell or nushell, but instead old experts will always defend the skills they have honed for years, while criticizing anything that's different.
I was the kind of shell guru whose teeth itched when they saw someone doing `grep | awk`. Then I had to try and bring Windows into a Mac+Linux CI system under Jenkins groovy files that were full of `"""sh` fragments, shell scriptlets wrapping python, etc, etc, and I don't bat ( I don't groovy either). Option 1: Learn to bat and try to translate. Hmm. No. Just no Option 2: ? Pwsh core had just come out. My immediate t…
Re: I wrote an bash enumerator because I was sick of xargs
#149> Or maybe you pipe into xargs and pray your filenames don’t have spaces… Always use -0. Most gnu utilities support it. It makes them put a null byte after every filename instead of a newline. Completely eliminates the problem of dealing with whitespace in the filenames.
To support your recommendation and redress the strawman the article postulates, the post's author could have replaced: find . -name '*.log' | xargs rm With: find . -name '*.log' -print0 | xargs -0 rm
find . -name '*.log' -deleteRe: I wrote an bash enumerator because I was sick of xargs
#150I have found that the most reliable way I like is to just construct the command externally and then pass to gnu parallel (mostly for --eta and --tmuxpane). And the great thing is, as others say, xargs -I. I prefer for shortness (and few collisoins), '@' seq 1 10|xargs -I@ echo 'bash run.py @'|parallel -j 10 I know the echo is a little silly but then I can remove the |parallel and see if it's right. And if I don't wan…