Adonis icon indicating copy to clipboard operation
Adonis copied to clipboard

IO pipe syntax

Open ccuser44 opened this issue 11 months ago • 3 comments

What part of Adonis is this related to?

Command

What are you suggesting?

Adonis currently has the pipe syntax which allows to run multiple commands.

I propose we should have an IO pipe syntax in which some commands can put their output to another commands input.

Unix uses | for their io pipe operations but Adonis already uses it so we need another syntax.

My idea is |%d>%d. The first %d would take the nth return argument of the command return and replace the nth arg of the next command being ran. You should also be able to have multiple input and output args (an equal amount on both sides of course) seperated by a coma |%d,%d,%d>%d,%d,%d.

ccuser44 avatar Mar 06 '24 06:03 ccuser44

How would this be implemented

Dimenpsyonal avatar Mar 06 '24 12:03 Dimenpsyonal

How would this be implemented

Very simple to implement

If a commands function returns values then they are input args of the new function are replaced with the old ones return values

ccuser44 avatar Mar 09 '24 15:03 ccuser44

excellent

Dimenpsyonal avatar Mar 11 '24 22:03 Dimenpsyonal