From 9ee9cf6a7f7079548c81a6a8f1a038140ea6746d Mon Sep 17 00:00:00 2001 From: Natalie Date: Sat, 3 May 2025 17:31:41 -0700 Subject: [PATCH 1/2] remove weird redundancy --- src/util/funcs.zig | 226 -------------------------------------------- src/util/index.zig | 227 ++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 226 insertions(+), 227 deletions(-) delete mode 100644 src/util/funcs.zig diff --git a/src/util/funcs.zig b/src/util/funcs.zig deleted file mode 100644 index a483131..0000000 --- a/src/util/funcs.zig +++ /dev/null @@ -1,226 +0,0 @@ -const std = @import("std"); -const string = []const u8; -const gpa = std.heap.c_allocator; -const extras = @import("extras"); -const git = @import("git"); - -const u = @import("index.zig"); - -// -// - -pub const b = 1; -pub const kb = b * 1024; -pub const mb = kb * 1024; -pub const gb = mb * 1024; - -const ansi_red = "\x1B[31m"; -const ansi_reset = "\x1B[39m"; - -pub fn assert(ok: bool, comptime fmt: string, args: anytype) void { - if (!ok) { - std.debug.print(ansi_red ++ fmt ++ ansi_reset ++ "\n", args); - std.process.exit(1); - } -} - -pub fn fail(comptime fmt: string, args: anytype) noreturn { - assert(false, fmt, args); - unreachable; -} - -pub fn try_index(comptime T: type, array: []T, n: usize, def: T) T { - if (array.len <= n) { - return def; - } - return array[n]; -} - -pub fn split(alloc: std.mem.Allocator, in: string, delim: u8) ![]string { - var list = std.ArrayList(string).init(alloc); - errdefer list.deinit(); - - var iter = std.mem.splitScalar(u8, in, delim); - while (iter.next()) |str| { - try list.append(str); - } - return list.toOwnedSlice(); -} - -pub fn file_list(alloc: std.mem.Allocator, dpath: string) ![]const string { - var dir = try std.fs.cwd().openDir(dpath, .{ .iterate = true }); - defer dir.close(); - return try extras.fileList(alloc, dir); -} - -pub fn run_cmd_raw(alloc: std.mem.Allocator, dir: ?string, args: []const string) !std.process.Child.RunResult { - return std.process.Child.run(.{ .allocator = alloc, .cwd = dir, .argv = args, .max_output_bytes = std.math.maxInt(usize) }) catch |e| switch (e) { - error.FileNotFound => { - u.fail("\"{s}\" command not found", .{args[0]}); - }, - else => |ee| return ee, - }; -} - -pub fn run_cmd(alloc: std.mem.Allocator, dir: ?string, args: []const string) !u32 { - const result = try run_cmd_raw(alloc, dir, args); - alloc.free(result.stdout); - alloc.free(result.stderr); - return result.term.Exited; -} - -pub fn list_remove(alloc: std.mem.Allocator, input: []string, search: string) ![]string { - var list = std.ArrayList(string).init(alloc); - errdefer list.deinit(); - for (input) |item| { - if (!std.mem.eql(u8, item, search)) { - try list.append(item); - } - } - return list.toOwnedSlice(); -} - -pub fn last(in: []string) ?string { - if (in.len == 0) return null; - return in[in.len - 1]; -} - -const alphabet = "0123456789abcdefghijklmnopqrstuvwxyz"; - -pub fn random_string(comptime len: usize) [len]u8 { - const now: u64 = @intCast(std.time.nanoTimestamp()); - var rand = std.rand.DefaultPrng.init(now); - var r = rand.random(); - var buf: [len]u8 = undefined; - var i: usize = 0; - while (i < len) : (i += 1) { - buf[i] = alphabet[r.int(usize) % alphabet.len]; - } - return buf; -} - -pub fn parse_split(comptime T: type, comptime delim: u8) type { - return struct { - const Self = @This(); - - id: T, - string: string, - - pub fn do(input: string) !Self { - var iter = std.mem.splitScalar(u8, input, delim); - const start = iter.next() orelse return error.IterEmpty; - const id = std.meta.stringToEnum(T, start) orelse return error.NoMemberFound; - return Self{ - .id = id, - .string = iter.rest(), - }; - } - }; -} - -pub const HashFn = enum { - blake3, - sha256, - sha512, -}; - -pub fn validate_hash(alloc: std.mem.Allocator, input: string, file_path: string) !bool { - const hash = parse_split(HashFn, '-').do(input) catch return false; - const file = try std.fs.cwd().openFile(file_path, .{}); - defer file.close(); - const data = try file.reader().readAllAlloc(alloc, gb); - const expected = hash.string; - const actual = switch (hash.id) { - .blake3 => &try do_hash(std.crypto.hash.Blake3, data), - .sha256 => &try do_hash(std.crypto.hash.sha2.Sha256, data), - .sha512 => &try do_hash(std.crypto.hash.sha2.Sha512, data), - }; - const result = std.mem.startsWith(u8, actual, expected); - if (!result) { - std.log.info("expected: {s}, actual: {s}", .{ expected, actual }); - } - return result; -} - -pub fn do_hash(comptime algo: type, data: string) ![algo.digest_length * 2]u8 { - return extras.to_hex(extras.hashBytes(algo, data)); -} - -/// Returns the result of running `git rev-parse HEAD` -pub fn git_rev_HEAD(alloc: std.mem.Allocator, dir: std.fs.Dir) !string { - var dirg = try dir.openDir(".git", .{}); - defer dirg.close(); - const commitid = try git.getHEAD(alloc, dirg); - return if (commitid) |_| commitid.?.id else error.NotAGitRepo; -} - -pub fn slice(comptime T: type, input: []const T, from: usize, to: usize) []const T { - const f = @max(from, 0); - const t = @min(to, input.len); - return input[f..t]; -} - -pub fn detect_pkgname(alloc: std.mem.Allocator, override: string, dir: string) !string { - if (override.len > 0) { - return override; - } - const dirO = if (dir.len == 0) std.fs.cwd() else try std.fs.cwd().openDir(dir, .{}); - if (!(try extras.doesFileExist(dirO, "build.zig"))) { - return error.NoBuildZig; - } - const dpath = try std.fs.realpathAlloc(alloc, try std.fs.path.join(alloc, &.{ dir, "build.zig" })); - const splitP = try split(alloc, dpath, std.fs.path.sep); - var name = splitP[splitP.len - 2]; - name = extras.trimPrefix(name, "zig-"); - assert(name.len > 0, "package name must not be an empty string", .{}); - return name; -} - -pub fn detct_mainfile(alloc: std.mem.Allocator, override: string, dir: ?std.fs.Dir, name: string) !string { - if (override.len > 0) { - if (try extras.doesFileExist(dir, override)) { - if (std.mem.endsWith(u8, override, ".zig")) { - return override; - } - } - } - const namedotzig = try std.mem.concat(alloc, u8, &.{ name, ".zig" }); - if (try extras.doesFileExist(dir, namedotzig)) { - return namedotzig; - } - if (try extras.doesFileExist(dir, try std.fs.path.join(alloc, &.{ "src", "lib.zig" }))) { - return "src/lib.zig"; - } - if (try extras.doesFileExist(dir, try std.fs.path.join(alloc, &.{ "src", "main.zig" }))) { - return "src/main.zig"; - } - return error.CantFindMain; -} - -pub fn indexOfN(haystack: string, needle: u8, n: usize) ?usize { - var i: usize = 0; - var c: usize = 0; - while (c < n) { - i = indexOfAfter(haystack, needle, i) orelse return null; - c += 1; - } - return i; -} - -pub fn indexOfAfter(haystack: string, needle: u8, after: usize) ?usize { - for (haystack, 0..) |c, i| { - if (i <= after) continue; - if (c == needle) return i; - } - return null; -} - -pub fn find_cachepath() !string { - const haystack = try std.fs.cwd().realpathAlloc(gpa, "."); - const needle = "/.zigmod/deps"; - - if (std.mem.indexOf(u8, haystack, needle)) |index| { - return haystack[0 .. index + needle.len]; - } - return try std.fs.path.join(gpa, &.{ haystack, ".zigmod", "deps" }); -} diff --git a/src/util/index.zig b/src/util/index.zig index 8766d27..a483131 100644 --- a/src/util/index.zig +++ b/src/util/index.zig @@ -1 +1,226 @@ -pub usingnamespace @import("./funcs.zig"); +const std = @import("std"); +const string = []const u8; +const gpa = std.heap.c_allocator; +const extras = @import("extras"); +const git = @import("git"); + +const u = @import("index.zig"); + +// +// + +pub const b = 1; +pub const kb = b * 1024; +pub const mb = kb * 1024; +pub const gb = mb * 1024; + +const ansi_red = "\x1B[31m"; +const ansi_reset = "\x1B[39m"; + +pub fn assert(ok: bool, comptime fmt: string, args: anytype) void { + if (!ok) { + std.debug.print(ansi_red ++ fmt ++ ansi_reset ++ "\n", args); + std.process.exit(1); + } +} + +pub fn fail(comptime fmt: string, args: anytype) noreturn { + assert(false, fmt, args); + unreachable; +} + +pub fn try_index(comptime T: type, array: []T, n: usize, def: T) T { + if (array.len <= n) { + return def; + } + return array[n]; +} + +pub fn split(alloc: std.mem.Allocator, in: string, delim: u8) ![]string { + var list = std.ArrayList(string).init(alloc); + errdefer list.deinit(); + + var iter = std.mem.splitScalar(u8, in, delim); + while (iter.next()) |str| { + try list.append(str); + } + return list.toOwnedSlice(); +} + +pub fn file_list(alloc: std.mem.Allocator, dpath: string) ![]const string { + var dir = try std.fs.cwd().openDir(dpath, .{ .iterate = true }); + defer dir.close(); + return try extras.fileList(alloc, dir); +} + +pub fn run_cmd_raw(alloc: std.mem.Allocator, dir: ?string, args: []const string) !std.process.Child.RunResult { + return std.process.Child.run(.{ .allocator = alloc, .cwd = dir, .argv = args, .max_output_bytes = std.math.maxInt(usize) }) catch |e| switch (e) { + error.FileNotFound => { + u.fail("\"{s}\" command not found", .{args[0]}); + }, + else => |ee| return ee, + }; +} + +pub fn run_cmd(alloc: std.mem.Allocator, dir: ?string, args: []const string) !u32 { + const result = try run_cmd_raw(alloc, dir, args); + alloc.free(result.stdout); + alloc.free(result.stderr); + return result.term.Exited; +} + +pub fn list_remove(alloc: std.mem.Allocator, input: []string, search: string) ![]string { + var list = std.ArrayList(string).init(alloc); + errdefer list.deinit(); + for (input) |item| { + if (!std.mem.eql(u8, item, search)) { + try list.append(item); + } + } + return list.toOwnedSlice(); +} + +pub fn last(in: []string) ?string { + if (in.len == 0) return null; + return in[in.len - 1]; +} + +const alphabet = "0123456789abcdefghijklmnopqrstuvwxyz"; + +pub fn random_string(comptime len: usize) [len]u8 { + const now: u64 = @intCast(std.time.nanoTimestamp()); + var rand = std.rand.DefaultPrng.init(now); + var r = rand.random(); + var buf: [len]u8 = undefined; + var i: usize = 0; + while (i < len) : (i += 1) { + buf[i] = alphabet[r.int(usize) % alphabet.len]; + } + return buf; +} + +pub fn parse_split(comptime T: type, comptime delim: u8) type { + return struct { + const Self = @This(); + + id: T, + string: string, + + pub fn do(input: string) !Self { + var iter = std.mem.splitScalar(u8, input, delim); + const start = iter.next() orelse return error.IterEmpty; + const id = std.meta.stringToEnum(T, start) orelse return error.NoMemberFound; + return Self{ + .id = id, + .string = iter.rest(), + }; + } + }; +} + +pub const HashFn = enum { + blake3, + sha256, + sha512, +}; + +pub fn validate_hash(alloc: std.mem.Allocator, input: string, file_path: string) !bool { + const hash = parse_split(HashFn, '-').do(input) catch return false; + const file = try std.fs.cwd().openFile(file_path, .{}); + defer file.close(); + const data = try file.reader().readAllAlloc(alloc, gb); + const expected = hash.string; + const actual = switch (hash.id) { + .blake3 => &try do_hash(std.crypto.hash.Blake3, data), + .sha256 => &try do_hash(std.crypto.hash.sha2.Sha256, data), + .sha512 => &try do_hash(std.crypto.hash.sha2.Sha512, data), + }; + const result = std.mem.startsWith(u8, actual, expected); + if (!result) { + std.log.info("expected: {s}, actual: {s}", .{ expected, actual }); + } + return result; +} + +pub fn do_hash(comptime algo: type, data: string) ![algo.digest_length * 2]u8 { + return extras.to_hex(extras.hashBytes(algo, data)); +} + +/// Returns the result of running `git rev-parse HEAD` +pub fn git_rev_HEAD(alloc: std.mem.Allocator, dir: std.fs.Dir) !string { + var dirg = try dir.openDir(".git", .{}); + defer dirg.close(); + const commitid = try git.getHEAD(alloc, dirg); + return if (commitid) |_| commitid.?.id else error.NotAGitRepo; +} + +pub fn slice(comptime T: type, input: []const T, from: usize, to: usize) []const T { + const f = @max(from, 0); + const t = @min(to, input.len); + return input[f..t]; +} + +pub fn detect_pkgname(alloc: std.mem.Allocator, override: string, dir: string) !string { + if (override.len > 0) { + return override; + } + const dirO = if (dir.len == 0) std.fs.cwd() else try std.fs.cwd().openDir(dir, .{}); + if (!(try extras.doesFileExist(dirO, "build.zig"))) { + return error.NoBuildZig; + } + const dpath = try std.fs.realpathAlloc(alloc, try std.fs.path.join(alloc, &.{ dir, "build.zig" })); + const splitP = try split(alloc, dpath, std.fs.path.sep); + var name = splitP[splitP.len - 2]; + name = extras.trimPrefix(name, "zig-"); + assert(name.len > 0, "package name must not be an empty string", .{}); + return name; +} + +pub fn detct_mainfile(alloc: std.mem.Allocator, override: string, dir: ?std.fs.Dir, name: string) !string { + if (override.len > 0) { + if (try extras.doesFileExist(dir, override)) { + if (std.mem.endsWith(u8, override, ".zig")) { + return override; + } + } + } + const namedotzig = try std.mem.concat(alloc, u8, &.{ name, ".zig" }); + if (try extras.doesFileExist(dir, namedotzig)) { + return namedotzig; + } + if (try extras.doesFileExist(dir, try std.fs.path.join(alloc, &.{ "src", "lib.zig" }))) { + return "src/lib.zig"; + } + if (try extras.doesFileExist(dir, try std.fs.path.join(alloc, &.{ "src", "main.zig" }))) { + return "src/main.zig"; + } + return error.CantFindMain; +} + +pub fn indexOfN(haystack: string, needle: u8, n: usize) ?usize { + var i: usize = 0; + var c: usize = 0; + while (c < n) { + i = indexOfAfter(haystack, needle, i) orelse return null; + c += 1; + } + return i; +} + +pub fn indexOfAfter(haystack: string, needle: u8, after: usize) ?usize { + for (haystack, 0..) |c, i| { + if (i <= after) continue; + if (c == needle) return i; + } + return null; +} + +pub fn find_cachepath() !string { + const haystack = try std.fs.cwd().realpathAlloc(gpa, "."); + const needle = "/.zigmod/deps"; + + if (std.mem.indexOf(u8, haystack, needle)) |index| { + return haystack[0 .. index + needle.len]; + } + return try std.fs.path.join(gpa, &.{ haystack, ".zigmod", "deps" }); +} From ff95363a409b4267a1589abd62e3f0cd77b251f5 Mon Sep 17 00:00:00 2001 From: Natalie Date: Sat, 3 May 2025 17:50:06 -0700 Subject: [PATCH 2/2] renamed all references of index.zig to funcs.zig --- src/cmd/aq.zig | 2 +- src/cmd/aquila/install.zig | 2 +- src/cmd/aquila/update.zig | 2 +- src/cmd/ci.zig | 2 +- src/cmd/fetch.zig | 2 +- src/cmd/generate.zig | 2 +- src/cmd/init.zig | 2 +- src/cmd/license.zig | 2 +- src/cmd/sum.zig | 2 +- src/cmd/version.zig | 2 +- src/cmd/zpm.zig | 2 +- src/cmd/zpm/add.zig | 2 +- src/common.zig | 2 +- src/util/dep.zig | 2 +- src/util/dep_type.zig | 2 +- src/util/{index.zig => funcs.zig} | 4 +--- src/util/modfile.zig | 2 +- src/util/module.zig | 2 +- 18 files changed, 18 insertions(+), 20 deletions(-) rename src/util/{index.zig => funcs.zig} (98%) diff --git a/src/cmd/aq.zig b/src/cmd/aq.zig index d77326e..7bb7b38 100644 --- a/src/cmd/aq.zig +++ b/src/cmd/aq.zig @@ -5,7 +5,7 @@ const zfetch = @import("zfetch"); const extras = @import("extras"); const json = @import("json"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); // // diff --git a/src/cmd/aquila/install.zig b/src/cmd/aquila/install.zig index b5b27c5..e37f3ce 100644 --- a/src/cmd/aquila/install.zig +++ b/src/cmd/aquila/install.zig @@ -5,7 +5,7 @@ const knownfolders = @import("known-folders"); const extras = @import("extras"); const zigmod = @import("../../lib.zig"); -const u = @import("./../../util/index.zig"); +const u = @import("./../../util/funcs.zig"); const common = @import("./../../common.zig"); pub fn execute(self_name: []const u8, args: [][]u8) !void { diff --git a/src/cmd/aquila/update.zig b/src/cmd/aquila/update.zig index a989eda..cc66f89 100644 --- a/src/cmd/aquila/update.zig +++ b/src/cmd/aquila/update.zig @@ -5,7 +5,7 @@ const knownfolders = @import("known-folders"); const extras = @import("extras"); const zigmod = @import("../../lib.zig"); -const u = @import("./../../util/index.zig"); +const u = @import("./../../util/funcs.zig"); const common = @import("./../../common.zig"); pub fn execute(self_name: []const u8, args: [][]u8) !void { diff --git a/src/cmd/ci.zig b/src/cmd/ci.zig index 49979be..75d070a 100644 --- a/src/cmd/ci.zig +++ b/src/cmd/ci.zig @@ -2,7 +2,7 @@ const std = @import("std"); const string = []const u8; const zigmod = @import("../lib.zig"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); const common = @import("./../common.zig"); // Inspired by: diff --git a/src/cmd/fetch.zig b/src/cmd/fetch.zig index 7bdc9e0..6289ba0 100644 --- a/src/cmd/fetch.zig +++ b/src/cmd/fetch.zig @@ -4,7 +4,7 @@ const ansi = @import("ansi"); const extras = @import("extras"); const zigmod = @import("../lib.zig"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); const common = @import("./../common.zig"); const license = @import("./license.zig"); diff --git a/src/cmd/generate.zig b/src/cmd/generate.zig index 5cc18b3..7a495e3 100644 --- a/src/cmd/generate.zig +++ b/src/cmd/generate.zig @@ -3,7 +3,7 @@ const string = []const u8; const extras = @import("extras"); const zigmod = @import("../lib.zig"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); const common = @import("./../common.zig"); // diff --git a/src/cmd/init.zig b/src/cmd/init.zig index 9b262bb..c6559c5 100644 --- a/src/cmd/init.zig +++ b/src/cmd/init.zig @@ -8,7 +8,7 @@ const ini = @import("ini"); const time = @import("time"); const extras = @import("extras"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); // // diff --git a/src/cmd/license.zig b/src/cmd/license.zig index 9ba4d58..5361afe 100644 --- a/src/cmd/license.zig +++ b/src/cmd/license.zig @@ -6,7 +6,7 @@ const licenses = @import("licenses"); const extras = @import("extras"); const zigmod = @import("../lib.zig"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); const common = @import("./../common.zig"); const List = std.ArrayList(zigmod.Module); diff --git a/src/cmd/sum.zig b/src/cmd/sum.zig index da91051..301c7ce 100644 --- a/src/cmd/sum.zig +++ b/src/cmd/sum.zig @@ -2,7 +2,7 @@ const std = @import("std"); const gpa = std.heap.c_allocator; const zigmod = @import("../lib.zig"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); const common = @import("./../common.zig"); // diff --git a/src/cmd/version.zig b/src/cmd/version.zig index 4fb8d88..a262f21 100644 --- a/src/cmd/version.zig +++ b/src/cmd/version.zig @@ -2,7 +2,7 @@ const std = @import("std"); const gpa = std.heap.c_allocator; const builtin = @import("builtin"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); // // diff --git a/src/cmd/zpm.zig b/src/cmd/zpm.zig index bdbabf9..071be0b 100644 --- a/src/cmd/zpm.zig +++ b/src/cmd/zpm.zig @@ -5,7 +5,7 @@ const zfetch = @import("zfetch"); const extras = @import("extras"); const json = @import("json"); -const u = @import("./../util/index.zig"); +const u = @import("./../util/funcs.zig"); // // diff --git a/src/cmd/zpm/add.zig b/src/cmd/zpm/add.zig index b787517..4bee8c5 100644 --- a/src/cmd/zpm/add.zig +++ b/src/cmd/zpm/add.zig @@ -4,7 +4,7 @@ const zfetch = @import("zfetch"); const extras = @import("extras"); const zigmod = @import("../../lib.zig"); -const u = @import("./../../util/index.zig"); +const u = @import("./../../util/funcs.zig"); const zpm = @import("./../zpm.zig"); // diff --git a/src/common.zig b/src/common.zig index 5d83eb0..613f50c 100644 --- a/src/common.zig +++ b/src/common.zig @@ -5,7 +5,7 @@ const ansi = @import("ansi"); const extras = @import("extras"); const zigmod = @import("./lib.zig"); -const u = @import("./util/index.zig"); +const u = @import("./util/funcs.zig"); // // diff --git a/src/util/dep.zig b/src/util/dep.zig index bc5ce4a..58412a7 100644 --- a/src/util/dep.zig +++ b/src/util/dep.zig @@ -5,7 +5,7 @@ const yaml = @import("yaml"); const extras = @import("extras"); const zigmod = @import("../lib.zig"); -const u = @import("index.zig"); +const u = @import("funcs.zig"); // // diff --git a/src/util/dep_type.zig b/src/util/dep_type.zig index 865b826..1e82204 100644 --- a/src/util/dep_type.zig +++ b/src/util/dep_type.zig @@ -1,7 +1,7 @@ const std = @import("std"); const string = []const u8; -const u = @import("./index.zig"); +const u = @import("./funcs.zig"); // // diff --git a/src/util/index.zig b/src/util/funcs.zig similarity index 98% rename from src/util/index.zig rename to src/util/funcs.zig index a483131..7ca645c 100644 --- a/src/util/index.zig +++ b/src/util/funcs.zig @@ -4,8 +4,6 @@ const gpa = std.heap.c_allocator; const extras = @import("extras"); const git = @import("git"); -const u = @import("index.zig"); - // // @@ -56,7 +54,7 @@ pub fn file_list(alloc: std.mem.Allocator, dpath: string) ![]const string { pub fn run_cmd_raw(alloc: std.mem.Allocator, dir: ?string, args: []const string) !std.process.Child.RunResult { return std.process.Child.run(.{ .allocator = alloc, .cwd = dir, .argv = args, .max_output_bytes = std.math.maxInt(usize) }) catch |e| switch (e) { error.FileNotFound => { - u.fail("\"{s}\" command not found", .{args[0]}); + fail("\"{s}\" command not found", .{args[0]}); }, else => |ee| return ee, }; diff --git a/src/util/modfile.zig b/src/util/modfile.zig index e381fbb..923686f 100644 --- a/src/util/modfile.zig +++ b/src/util/modfile.zig @@ -3,7 +3,7 @@ const string = []const u8; const yaml = @import("yaml"); const zigmod = @import("../lib.zig"); -const u = @import("index.zig"); +const u = @import("funcs.zig"); // // diff --git a/src/util/module.zig b/src/util/module.zig index 61a7872..dcc4084 100644 --- a/src/util/module.zig +++ b/src/util/module.zig @@ -5,7 +5,7 @@ const yaml = @import("yaml"); const extras = @import("extras"); const zigmod = @import("../lib.zig"); -const u = @import("index.zig"); +const u = @import("funcs.zig"); const common = @import("./../common.zig"); //