Skip to content

Commit

Permalink
Fix "bun exec" examples (#13318)
Browse files Browse the repository at this point in the history
  • Loading branch information
vktrl authored Aug 15, 2024
1 parent 3f68622 commit b70458c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/cli.zig
Original file line number Diff line number Diff line change
Expand Up @@ -2389,8 +2389,8 @@ pub const Command = struct {
\\<b><red>Note<r>: If executing this from a shell, make sure to escape the string!
\\
\\<b>Examples<d>:<r>
\\ <b>bunx exec "echo hi"<r>
\\ <b>bunx exec "echo \"hey friends\"!"<r>
\\ <b>bun exec "echo hi"<r>
\\ <b>bun exec "echo \"hey friends\"!"<r>
\\
, .{});
Output.flush();
Expand Down
2 changes: 1 addition & 1 deletion test/js/bun/shell/exec.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ describe("bun exec", () => {
TestBuilder.command`${BUN} exec`
.env(bunEnv)
.stdout(
'Usage: bun exec <script>\n\nExecute a shell script directly from Bun.\n\nNote: If executing this from a shell, make sure to escape the string!\n\nExamples:\n bunx exec "echo hi"\n bunx exec "echo \\"hey friends\\"!"\n',
'Usage: bun exec <script>\n\nExecute a shell script directly from Bun.\n\nNote: If executing this from a shell, make sure to escape the string!\n\nExamples:\n bun exec "echo hi"\n bun exec "echo \\"hey friends\\"!"\n',
)
.runAsTest("no args prints help text");

Expand Down

0 comments on commit b70458c

Please sign in to comment.