diff options
author | 2021-12-28 03:15:53 -0800 | |
---|---|---|
committer | 2021-12-28 03:15:53 -0800 | |
commit | 6c867c34d73f348675eec286eb2b745bebe3eab9 (patch) | |
tree | 200aa432bd9891a6b7f5748cf7d54aa7b7e15481 /src | |
parent | 70a56028b62a2645d436e21b9731cf8fe3f12dd4 (diff) | |
download | bun-6c867c34d73f348675eec286eb2b745bebe3eab9.tar.gz bun-6c867c34d73f348675eec286eb2b745bebe3eab9.tar.zst bun-6c867c34d73f348675eec286eb2b745bebe3eab9.zip |
Fix edgecase in `bun create` tasks
Diffstat (limited to 'src')
-rw-r--r-- | src/cli/create_command.zig | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/cli/create_command.zig b/src/cli/create_command.zig index 7672ce9b9..4430bd52b 100644 --- a/src/cli/create_command.zig +++ b/src/cli/create_command.zig @@ -116,12 +116,8 @@ fn execTask(allocator: *std.mem.Allocator, task_: string, cwd: string, PATH: str } if (strings.startsWith(task, "bun ")) { - // TODO: use self exe - if (bun_path orelse which(&bun_path_buf, PATH, cwd, "bun")) |bun_path_| { - bun_path = bun_path_; - argv = argv[npm_args..]; - argv[0] = std.mem.span(bun_path_); - } + argv[1] = argv[0]; + argv = argv[1..]; } Output.pretty("\n<r><d>$<b>", .{}); |