r/tinycode • u/soveran • Mar 14 '18
Map is hopefully an improvement upon the ergonomics of tools like xargs, find -exec and shell for-loops
https://github.com/soveran/map#map
34
Upvotes
r/tinycode • u/soveran • Mar 14 '18
View all comments
Show parent comment
3
u/soveran Mar 15 '18
Indeed, and it also allows you to configure the max number of processes to run concurrently.
Often you can send the task to the background to run it in parallel.
For example:
If you run it that way, you will hear "done" after one second, "done" after two seconds, and "done" after three seconds.
Instead:
This way you will probably hear a single, superimposed "done".
If you want to download files, you can take the same approach:
It will download the files in parallel.