mirror of
https://github.com/oven-sh/bun
synced 2026-02-16 05:42:43 +00:00
fix(windows): install bugfixes for workspaces, tarballs, and relative paths (#8813)
* more tests * update migration.zig * fix up paths * update tests * update tests * test * test * update registry tests * comments * early exit if stream is invalid * dont pass invalid_fd to openFileAtWindows * fix merge * misc crash fix * make this use optional pointers instead of 0xaa * ensure absolute paths are propagated properly * package.json expects forward slash * this assert was invalid * add panic checks * pass bun-remove * more panic checks * test: pass bun-add * querying these hangs outside bun too * fix compile error from merge conflict resolution * use compileError instead of comptime unreachable * tidy * bunx: check for the .exe bin extension * bunx: another route to make cache path if it doesnt exist * install: another case of FolderResolution.getOrPut expecting absolute path * fix a bun install crash * dont print zig stack trace if bun install fails * test: pass bun-link * test: bunx: add more expects * test: bun-install-registry: pass * test: bun-install: pass * test: bun-pm: pass * fix merge main error * fix posix tests * fix last failing test in bun-install.test.ts symlink difference between platforms * bun-install-registry.test.ts fix * bun-run.test.ts: remove stray console log --------- Co-authored-by: Meghan Denny <meghan@bun.sh> Co-authored-by: Meghan Denny <hello@nektro.net> Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
This commit is contained in:
@@ -326,7 +326,7 @@ pub const PackageManagerCommand = struct {
|
||||
const package_id = lockfile.buffers.resolutions.items[dependency_id];
|
||||
if (package_id >= lockfile.packages.len) continue;
|
||||
const name = dependencies[dependency_id].name.slice(string_bytes);
|
||||
const resolution = resolutions[package_id].fmt(string_bytes);
|
||||
const resolution = resolutions[package_id].fmt(string_bytes, .auto);
|
||||
|
||||
if (index < sorted_dependencies.len - 1) {
|
||||
Output.prettyln("<d>├──<r> {s}<r><d>@{any}<r>\n", .{ name, resolution });
|
||||
@@ -421,7 +421,7 @@ fn printNodeModulesFolderStructure(
|
||||
}
|
||||
}
|
||||
}
|
||||
const directory_version = try std.fmt.bufPrint(&resolution_buf, "{}", .{resolutions[id].fmt(string_bytes)});
|
||||
const directory_version = try std.fmt.bufPrint(&resolution_buf, "{}", .{resolutions[id].fmt(string_bytes, .auto)});
|
||||
if (std.mem.indexOf(u8, path, "node_modules")) |j| {
|
||||
Output.prettyln("{s}<d>@{s}<r>", .{ path[0 .. j - 1], directory_version });
|
||||
} else {
|
||||
@@ -496,7 +496,7 @@ fn printNodeModulesFolderStructure(
|
||||
}
|
||||
|
||||
var resolution_buf: [512]u8 = undefined;
|
||||
const package_version = try std.fmt.bufPrint(&resolution_buf, "{}", .{resolutions[package_id].fmt(string_bytes)});
|
||||
const package_version = try std.fmt.bufPrint(&resolution_buf, "{}", .{resolutions[package_id].fmt(string_bytes, .auto)});
|
||||
Output.prettyln("{s}<d>@{s}<r>", .{ package_name, package_version });
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user