Skip to content

Support piped commands  #346

Open
Open

Description

@lstocchi

Describe the enhancement
Support pipes | to redirect stdout of first toolrunner to the next one.

Code Snippet
An idea could be to have a method that connects a list of ToolRunners and start executing them ToolRunner.execWithPiping(trs: ToolRunner[])

Additional information
If i have a sequence of commands like tr1 | tr2 | tr3 i would like to redirect stdout through all tollrunners. (e.g. kubectl create deployment my-dep -o yaml --dry-run | kubectl label --local -f - environment=qa -o yaml | kubectl create -f - )

I am also available to contribute on this if there is no workaround to achieve this and you want to add this feature.

Activity

  1. sittie82 commented on Feb 28, 2020

    @sittie82

    An idea could be to have a method that connects a list and start executing them ToolRunner.execWithPiping(trs: ToolRunne)

  2. rickstaa commented on Dec 12, 2020

    @rickstaa

    Related to #461, #359. This would be a very nice feature to have! 🚀 I currently use the following workaround that was given in #359 by @hrueger.

    LINUX/MAC:

    exec.exec(`/bin/bash -c "my command"`)

    WINDOWS:

    exec.exec(`cmd /c "my command"`)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions