feat: More robust and faster shell escaping (#8904)

* wip

* Proper escaping algorithm

* Don't use `$` for js obj/string referencs

* [autofix.ci] apply automated fixes

* Changes

* Changes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
This commit is contained in:
Zack Radisic
2024-02-16 04:09:34 -08:00
committed by GitHub
parent 2b335d72e7
commit ebaeafbc89
5 changed files with 489 additions and 99 deletions

View File

@@ -1884,7 +1884,7 @@ pub fn convertUTF16ToUTF8Append(list: *std.ArrayList(u8), utf16: []const u16) !v
return;
}
list.items.len = result.count;
list.items.len += result.count;
}
pub fn toUTF8AllocWithType(allocator: std.mem.Allocator, comptime Type: type, utf16: Type) ![]u8 {