local-etc-hosts-updater/src/main.zig
2024-05-10 20:37:25 +05:00

11 lines
324 B
Zig

const std = @import("std");
const util = @import("util.zig");
const mdns = @import("mdns.zig");
const hosts = @import("hosts.zig");
pub fn main() !void {
try util.check_perms();
const domain, const ip_ver = try util.get_input();
const ips = try mdns.get_mdns(domain, ip_ver);
try hosts.update_hosts(ips);
}