╭ changed ─╮ │src/ui.zig│ ╰──────────╯ ╭───────────────────────────────────────────────────────────────────────────────────╮ │2123 pub const RepoHandle = struct { │ │2124 location: RoutablePage.RepoLocation, │ │2125 viewer: ?Viewer = null, │ │2126 + // only a public repo can be cloned over http │ │2127 + read_access: evt.Repo.Access = .private, │ │2128 │ │2129 pub fn dupe(self: RepoHandle, allocator: std.mem.Allocator) !RepoHandle {│ │2130 var copy = self; │ ╰───────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ──────╮ │src/ui/Repo.zig│ ╰───────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────╮ │278 const handle = ui.RepoHandle{ │ │279 .location = .{ .repo = try arena.allocator().dupe(u8, repo_identity.identity) },│ │280 .viewer = try ui.Viewer.init(session, arena, role), │ │281 + .read_access = repo.event.read_access, │ │282 }; │ │283 │ │284 // open the repo once for every tab. files and changes share a ref or revision. │ ╰─────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ────────╮ │src/ui/widget.zig│ ╰─────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │2021 var ssh_index: ?usize = null; │ │2022 switch (handle.location) { │ │2023 .repo => |identity| { │ │2024 - if (session.data.git_http_port) |port| { │ │2024 + const http_port = if (handle.read_access == .public) session.data.git_http_port else null;│ │2025 + if (http_port) |port| { │ │2026 const url = try aa.print("http://localhost:{d}/{s}", .{ port, identity }); │ │2027 choices[count] = .{ │ │2028 .selector = "http", │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯