Merge branch 'main' of github.com:oven-sh/bun into ali/piscina

This commit is contained in:
Alistair Smith
2025-06-03 18:52:59 -07:00
5 changed files with 4 additions and 9 deletions

View File

@@ -260,7 +260,6 @@ _bun_pm_completion() {
'hash\:"generate & print the hash of the current lockfile" '
'hash-string\:"print the string used to hash the lockfile" '
'hash-print\:"print the hash stored in the current lockfile" '
'audit\:"run a security audit of dependencies in Bun'\''s lockfile"'
'cache\:"print the path to the cache folder" '
)
@@ -573,7 +572,7 @@ _bun_outdated_completion() {
'--no-progress[Disable the progress bar]' \
'--help[Print this help menu]' &&
ret=0
case $state in
config)
_bun_list_bunfig_toml

View File

@@ -416,6 +416,7 @@ extern "C" void bun_restore_stdio()
extern "C" void onExitSignal(int sig)
{
bun_restore_stdio();
signal(sig, SIG_DFL);
raise(sig);
}
#endif

View File

@@ -130,7 +130,6 @@ pub const PackageManagerCommand = struct {
\\ <b><green>bun pm<r> <blue>hash<r> generate & print the hash of the current lockfile
\\ <b><green>bun pm<r> <blue>hash-string<r> print the string used to hash the lockfile
\\ <b><green>bun pm<r> <blue>hash-print<r> print the hash stored in the current lockfile
\\ <b><green>bun pm<r> <blue>audit<r> check installed packages for vulnerabilities
\\ <b><green>bun pm<r> <blue>cache<r> print the path to the cache folder
\\ <b><green>bun pm<r> <blue>cache rm<r> clear the cache
\\ <b><green>bun pm<r> <blue>migrate<r> migrate another package manager's lockfile without installing anything

View File

@@ -7519,10 +7519,6 @@ pub const PackageManager = struct {
break :brk loader;
};
if (subcommand == .pm and cli.positionals.len >= 2 and strings.eqlComptime(cli.positionals[1], "audit")) {
env.quiet = true;
}
env.loadProcess();
try env.load(entries_option.entries, &[_][]u8{}, .production, false);

View File

@@ -39,7 +39,7 @@ for (const packageJsonPath of absolutes) {
await $`bun i`.cwd(tmp);
await spawn({
cmd: [bunExe(), "pm", "audit"],
cmd: [bunExe(), "audit"],
cwd: tmp,
env: {
...bunEnv,
@@ -50,7 +50,7 @@ for (const packageJsonPath of absolutes) {
const body = await requestBodyPromise;
const { stdout, exited } = spawn({
cmd: [bunExe(), "pm", "audit", "--json"],
cmd: [bunExe(), "audit", "--json"],
cwd: tmp,
stdout: "pipe",
stderr: "ignore",