mnix: Nix binary-cache client PoC in MoonBit (install hello from cache.nixos.org) (#1)

This commit was merged in pull request #1.
This commit is contained in:
nandi committed 2026-11-24 22:12:02 +00:00
1 parent 4e7ce11973
commit fa70164336
48 files changed
+3112 -2

No files matched your search

+55
View File
@@ -0,0 +1,55 @@
// Generated using `moon info`, DON'T EDIT IT
package "experiments/moon-nix/store"
import {
"moonbitlang/core/debug",
}
// Values
pub fn base32_len(Int32) -> Int32
pub let default_store_dir : String
pub fn hello_probe() -> Int32
pub fn nixbase32_decode(StringView, Int32) -> Bytes raise NixError
pub fn nixbase32_encode(BytesView) -> String
pub fn parse_sha256(String) -> Bytes raise
pub fn[T] raises(() -> T raise) -> Bool
pub fn sha256(BytesView) -> Bytes
pub fn sha256_nix32(BytesView) -> String
pub fn to_hex(BytesView) -> String
// Errors
pub(all) suberror NixError {
Parse(String)
Verify(String)
Network(String)
Io(String)
Unsupported(String)
}
pub impl Show for NixError
// Types and methods
#derive(Eq, @debug.Debug)
pub(all) struct StorePath {
store_dir : String
hash : String
name : String
}
pub fn StorePath::base_name(Self) -> String
pub fn StorePath::logical(Self) -> String
pub fn StorePath::parse(String) -> Self raise NixError
pub fn StorePath::parse_base(String, store_dir? : String) -> Self raise NixError
pub fn StorePath::to_string(Self) -> String
pub fn StorePath::with_store_dir(Self, String) -> Self
// Type aliases
// Traits