Joined May 2011
·
Posted to
map function in shell
over 1 year
ago
@avdleeuw In this case, I don't want the ./
prefixes on the output, so yes. I wouldn't use them in an uncontrolled environment :)
Achievements
481 Karma
19,868 Total ProTip Views

Forked 100
Have a seriously badass project that's been forked at least 100 times

Forked 50
Have a project with a thriving community of users that's been forked at least 50 times

Mongoose
Have at least one original repo where Ruby is the dominant language

Raven
Have at least one original repo where some form of shell script is the dominant language

Octopussy
Have a repo followed by a member of the GitHub team

Walrus
The walrus is no stranger to variety. Use at least 4 different languages throughout all your repos

Altruist
Increase developer well-being by sharing at least 20 open source projects

Lemmings 100
Write something great enough to have at least 100 watchers of the project

Kilo of Lemmings
Establish a space in the open source hall of fame by getting at least 1000 devs to watch a project

Forked 20
Have an established project that's been forked at least 20 times

Forked
Have a project valued enough to be forked by someone else

Charity
Fork and commit to someone's open source project in need

Python 3
Have at least three original repos where Python is the dominant language

Python
Would you expect anything less? Have at least one original repo where Python is the dominant language

Bear 3
Have at least three original repos where Objective-C is the dominant language

Bear
Have at least one original repo where Objective-C is the dominant language
(1) "Once tee() has made a split, the original iterable should not be used anywhere else; otherwise, the iterable could get advanced without the tee objects being informed."
(2) tee() actually duplicates all elements from the input, making it much less memory-efficient as you need to consume both returned iterators relatively simultaneously, in order to prevent storing the complete input in memory. My version only keeps the minimum amount of input in memory.
The tee() based version keeps the full input in memory until falsey is consumed, too.