oven-sh/bun

when passing arguments to `bun run` it escapes double quotes

クローズ

#7,667 opened on 2023/12/15

 (4 件のコメント) (3 件のリアクション) (0 人の担当者)Rust (4,486 件のフォーク)batch import
bugbun installgood first issue

Repository metrics

Stars
 (90,348 個のスター)
PR merge metrics
 (平均マージ 1d 17h) (30d で 357 merged PRs)

説明

What version of Bun is running?

1.0.18+36c316a24

What platform is your computer?

Linux 5.15.0-58-generic x86_64 x86_64

What steps can reproduce the bug?

  1. add a command containing double quotes to package.json scripts
{
  "scripts": {
    "foo": "echo \"ONE\" TWO",
  }
}
  1. call bun run foo
  2. call bun run foo THREE

What is the expected behavior?

> bun run foo 
$ echo "ONE" TWO
ONE TWO
> bun run foo THREE
$ echo "ONE" TWO THREE
ONE TWO THREE
> 

What do you see instead?

> bun run foo 
$ echo "ONE" TWO
ONE TWO
> bun run foo THREE
$ echo \"ONE\" TWO THREE
"ONE" TWO THREE
>

コントリビューターガイド