-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add --filter
and package pattern arguments to bun outdated
#13557
Conversation
} | ||
|
||
const length = bun.simdutf.length.utf32.from.utf8.le(arg); | ||
const convert_buf = bun.default_allocator.alloc(u32, length) catch bun.outOfMemory(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seems crazy to me that we have to drop down to simdutf here
else => unreachable, | ||
}; | ||
|
||
const abs_res_path = path.joinAbsString(FileSystem.instance.top_level_dir, &[_]string{res_path}, .posix); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably should use joinAbsStringBuf incase something else is making use of the shared string buffer?
} | ||
|
||
// move all matched workspaces to front of array | ||
var i: usize = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
var i: usize = 0; | |
var i: usize = 0; | |
var abs_res_path_buf: bun.PathBuffer = undefined; |
else => unreachable, | ||
}; | ||
|
||
const abs_res_path = path.joinAbsString(FileSystem.instance.top_level_dir, &[_]string{res_path}, .posix); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const abs_res_path = path.joinAbsString(FileSystem.instance.top_level_dir, &[_]string{res_path}, .posix); | |
const abs_res_path = path.joinAbsStringBuf(&abs_res_path_buf, FileSystem.instance.top_level_dir, &[_]string{res_path}, .posix); |
This is mergeable so I'm going to merge it I do think that we should have some canonical way to "get a validated UTF-8 string from bytes" that doesn't directly involve simdutf |
What does this PR do?
bun outdated
through--filter
. You can glob for workspace package names or workspace paths. Examples:--filter
. Example:bun outdated
tableHow did you verify your code works?
Added tests for
--filter
and args