From d8131fee6462f87ee718fba9a6b46cc8b1261f98 Mon Sep 17 00:00:00 2001 From: WindSoilder Date: Wed, 15 Jan 2025 10:07:27 +0800 Subject: [PATCH] update example --- lang-guide/chapters/pipelines.md | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/lang-guide/chapters/pipelines.md b/lang-guide/chapters/pipelines.md index 68423b4323..a2fe58d168 100644 --- a/lang-guide/chapters/pipelines.md +++ b/lang-guide/chapters/pipelines.md @@ -99,6 +99,8 @@ Pipeline and redirection behavior can be hard to follow when they are used with - (^cmd1 | ^cmd2; ^cmd3 | ^cmd4) | ^cmd5 +It runs `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4)` first, then pipes *stdout* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | ---------- | | cmd1 | Piped | Terminal | @@ -108,6 +110,8 @@ Pipeline and redirection behavior can be hard to follow when they are used with - (^cmd1 | ^cmd2; ^cmd3 | ^cmd4) e>| ^cmd5 +It runs `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4)` first, then pipes *stderr* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | -------- | | cmd1 | Piped | Terminal | @@ -117,6 +121,8 @@ Pipeline and redirection behavior can be hard to follow when they are used with - (^cmd1 | ^cmd2; ^cmd3 | ^cmd4) o+e>| ^cmd5 +It runs `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4)` first, then pipes *stdout and stderr* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | -------- | | cmd1 | Piped | Terminal | @@ -163,7 +169,7 @@ def custom-cmd [] { The custom command stdio behavior is the same as the previous section. -In the examples below the body of `custom-cmd` is `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4). +In the examples below the body of `custom-cmd` is `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4)`. - custom-cmd @@ -176,6 +182,8 @@ In the examples below the body of `custom-cmd` is `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4 - custom-cmd | ^cmd5 +It runs `custom-cmd` first, then pipes *stdout* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | ---------- | | cmd1 | Piped | Terminal | @@ -185,6 +193,8 @@ In the examples below the body of `custom-cmd` is `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4 - custom-cmd e>| ^cmd5 +It runs `custom-cmd` first, then pipes *stderr* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | -------- | | cmd1 | Piped | Terminal | @@ -194,6 +204,8 @@ In the examples below the body of `custom-cmd` is `(^cmd1 | ^cmd2; ^cmd3 | ^cmd4 - custom-cmd o+e>| ^cmd5 +It runs `custom-cmd` first, then pipes *stdout and stderr* to `^cmd5`, where both stdout and stderr are directed to the Terminal. + | Command | Stdout | Stderr | | ------- | -------- | -------- | | cmd1 | Piped | Terminal |