Project

dorian-all

0.0
The project is in a healthy, maintained state
Evaluates some code on all lines of the input e.g. `ls -l | each "puts l.split[4]" | all "puts lines.map(&:to_i).sum"`
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
 Dependencies
 Project Readme

dorian-all

Evaluates some code on all lines of the input

e.g. ls -l | each "puts l.split[4]" | all "puts lines.map(&:to_i).sum"

Install

gem install dorian-all

Or as part of my other gems:

gem install dorian

Usage

From my history:

pbpaste | all "puts lines.map(&:strip).join(', ')"
printf 'Clément\nDorian\nMadiha\nRémi\nRayane\nMélanie\nJade' | all "puts lines.sample"
pbpaste | grep '*' | each "puts '\"' + line.split[1] + '\"'" | all "puts lines.map(&:strip).join(', ')"
cat a.txt | grep -v NEW | all "puts lines.map(&:strip).each_slice(2).map { |l| l.join(' '))"