Determine a method of download files using native Zig
tristanisham opened this issue · comments
Currently, ZVM uses a cURL binding which makes it platform exclusive. I'd like to find a native Zig solution so ZVM can be compiled with minimal effort on the end user's part.
This is referring to https://github.com/tristanisham/zvm/blob/909f4f3db936019184ac869e354dcdd1d9ee0e6a/install.sh, correct? In other words, you'd want a cross-platform tool which:
1 - Figures out the host's target
Lines 7 to 8 in 909f4f3
2 - Downloads the GitHub release for the host's target (https://github.com/tristanisham/zvm/releases/latest/download/$PLATFORM
)
Line 26 in 909f4f3
3 - Extracts it afterwards
Line 27 in 909f4f3
Is that it? Apologies if I have misunderstood the intent here.
Zig now has a native http module in the standard library.