╭ changed ──────╮ │src/test/ui.zig│ ╰───────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │117 try repo.add(io, allocator, &.{name}); │ │118 head = try repo.commit(io, allocator, .{ .message = "add file" }); │ │119 } │ │120 - const route = ui.RoutablePage.repoDiffRoute("alice/project", .object, &head, 0, "", &base) orelse return error.BadRoute;│ │120 + const route = ui.RoutablePage.repoDiffRoute("alice:project", .object, &head, 0, "", &base) orelse return error.BadRoute;│ │121 const diff = try Diff.init(kind, opts, &arena, &repo, io, allocator, route.repo_diff); │ │122 const first = diff.window; │ │123 try std.testing.expectEqual(Diff.page_size, first.hunks.len); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │139 .{ .ref = .tag, .value = "tip" }, │ │140 }; │ │141 for (sources) |source| { │ │142 - const selected = ui.RoutablePage.repoDiffRoute("alice/project", source.ref, source.value, 0, "", &base) orelse return error.BadRoute;│ │142 + const selected = ui.RoutablePage.repoDiffRoute("alice:project", source.ref, source.value, 0, "", &base) orelse return error.BadRoute;│ │143 const data = try Diff.init(kind, opts, &arena, &repo, io, allocator, selected.repo_diff); │ │144 try std.testing.expectEqualDeep(first, data.window); │ │145 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │146 - const unchanged = ui.RoutablePage.repoDiffRoute("alice/project", .object, &head, 0, "", &head) orelse return error.BadRoute; │ │146 + const unchanged = ui.RoutablePage.repoDiffRoute("alice:project", .object, &head, 0, "", &head) orelse return error.BadRoute; │ │147 try std.testing.expectEqual(0, (try Diff.init(kind, opts, &arena, &repo, io, allocator, unchanged.repo_diff)).window.hunks.len);│ │148 │ │149 // a zero base includes files that were already present in the first commit │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │150 const zero = [_]u8{'0'} ** xit.hash.hexLen(opts.hash); │ │151 - const created = ui.RoutablePage.repoDiffRoute("alice/project", .object, &head, 0, "shared.txt", &zero) orelse return error.BadRoute;│ │151 + const created = ui.RoutablePage.repoDiffRoute("alice:project", .object, &head, 0, "shared.txt", &zero) orelse return error.BadRoute;│ │152 const created_diff = try Diff.init(kind, opts, &arena, &repo, io, allocator, created.repo_diff); │ │153 try std.testing.expectEqual(1, created_diff.window.hunks.len); │ │154 try std.testing.expectEqualStrings("shared.txt", created_diff.window.hunks[0].path orelse return error.MissingPath); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │155 │ │156 // standalone panes keep their comparison when filtering or paginating │ │157 const id = "11111111111111111111111111111111"; │ │158 - const fork_diff = Diff{ .route = .{ .fork = .{ .identity = "alice/project", .id = id } }, .window = first };│ │158 + const fork_diff = Diff{ .route = .{ .fork = .{ .identity = "alice:project", .id = id } }, .window = first };│ │159 for ([_]Diff{ diff, fork_diff }) |data| { │ │160 for ([_]bool{ true, false }) |terminal| { │ │161 var session = ui.Session{ .arena = &arena, .page_arena = &arena, .is_terminal = terminal }; │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │162 - session.data.current_page = if (data.route == .repo) route else ui.RoutablePage.forkDiffRoute("alice/project", id, "", "", 0, "") orelse return error.BadRoute;│ │162 + session.data.current_page = if (data.route == .repo) route else ui.RoutablePage.forkDiffRoute("alice:project", id, "", "", 0, "") orelse return error.BadRoute;│ │163 var view = try Diff.View.init(allocator, &data, &session); │ │164 defer view.deinit(allocator); │ │165 const focus = view.getFocus(); │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────╮ │189 │ │190 var arena = std.heap.ArenaAllocator.init(allocator); │ │191 defer arena.deinit(); │ │192 - const identity = "alice/ziglings"; │ │192 + const identity = "alice:ziglings"; │ │193 const oid0 = "1111111111111111111111111111111111111111"; │ │194 const next_oid = "2222222222222222222222222222222222222222";│ │195 const base_oid = "3333333333333333333333333333333333333333";│ ╰─────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │239 const base_oid = "3333333333333333333333333333333333333333"; │ │240 │ │241 // the route layer holds the value already url-encoded ("feature%2Ffoo"). │ │242 - const route = RP.repoCommitsRoute("alice/ziglings", .branch, "feature%2Ffoo", base_oid).?; │ │242 + const route = RP.repoCommitsRoute("alice:ziglings", .branch, "feature%2Ffoo", base_oid).?; │ │243 const url = try route.toUrl(&arena); │ │244 - try std.testing.expectEqualStrings("/repo/alice/ziglings/commits/branch:feature%2Ffoo/base:" ++ base_oid, url);│ │244 + try std.testing.expectEqualStrings("/alice:ziglings/commits/branch:feature%2Ffoo/base:" ++ base_oid, url); │ │245 │ │246 // parsing it back yields the same route, and the ref splits out intact. │ │247 const parsed = RP.fromUrl(url); │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ │250 try std.testing.expectEqual(RP.RefOrOid.branch, parsed_route.ref_or_oid.?); │ │251 try std.testing.expectEqualStrings("feature%2Ffoo", parsed_route.value.slice()); │ │252 try std.testing.expectEqualStrings(base_oid, parsed_route.base_oid.slice()); │ │253 - const unfiltered = RP.repoCommitsRoute("alice/ziglings", .branch, "feature%2Ffoo", "").?;│ │253 + const unfiltered = RP.repoCommitsRoute("alice:ziglings", .branch, "feature%2Ffoo", "").?;│ │254 try std.testing.expect(!RP.eql(route, unfiltered)); │ │255 } │ │256 │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯