aboutsummaryrefslogtreecommitdiff
path: root/src/string_immutable.zig
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-12-22 23:38:56 -0800
committerGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-12-22 23:38:56 -0800
commit3da9c728d6756de9e3280ac8f8fce8a7515d641f (patch)
tree2c08b87c8d210ce212419b58ef711c09960d31d9 /src/string_immutable.zig
parent85733abe79d27e69a29b036c318e4f8e733958ce (diff)
downloadbun-3da9c728d6756de9e3280ac8f8fce8a7515d641f.tar.gz
bun-3da9c728d6756de9e3280ac8f8fce8a7515d641f.tar.zst
bun-3da9c728d6756de9e3280ac8f8fce8a7515d641f.zip
Make `bun pm ls` only show top-level by default
Diffstat (limited to 'src/string_immutable.zig')
-rw-r--r--src/string_immutable.zig9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/string_immutable.zig b/src/string_immutable.zig
index 76b8b7073..f3a7cdf5e 100644
--- a/src/string_immutable.zig
+++ b/src/string_immutable.zig
@@ -3983,3 +3983,12 @@ pub fn cloneNormalizingSeparators(
return buf[0 .. @ptrToInt(remain.ptr) - @ptrToInt(buf.ptr)];
}
+
+pub fn leftHasAnyInRight(to_check: []const string, against: []const string) bool {
+ for (to_check) |check| {
+ for (against) |item| {
+ if (eqlLong(check, item, true)) return true;
+ }
+ }
+ return false;
+}