╭ changed ────────╮ │src/serve_ssh.zig│ ╰─────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │13 pub const SessionHandler = struct { │ │14 admin_repo_path: []const u8, │ │15 repo_root_path: []const u8, │ │16 - // test mode serves repos directly by path instead of resolving them as │ │17 - // <owner>/<repo> through the event store │ │18 - is_test: bool, │ │16 err: *std.Io.Writer, │ │17 │ │18 pub fn handleSession(self: *const SessionHandler, sess: *ssh.SessionCtx, request: ssh.Request) !void {│ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │213 const any_repo_opts: rp.AnyRepoOpts(.xit) = .{}; │ │214 │ │215 // authenticate pushes: the authenticated key must be registered to the │ │219 - // repo's owner. skipped in test mode, which serves repos directly by path. │ │220 - if (create_if_missing and !handler.is_test) { │ │216 + // repo's owner. │ │217 + if (create_if_missing) { │ │218 const owner_repo = evt.parseOwnerRepoPath(parsed.dir) orelse return writeError(sess, "repo path must be <owner>/<repo>");│ │219 if (!try isKeyAuthorized(io, allocator, handler.admin_repo_path, owner_repo.owner, &sess.fingerprint)) │ │220 return writeError(sess, "unauthorized: this SSH key is not registered to the repo owner"); │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │221 } │ │222 │ │226 - const repo_path = switch (try serve_common.resolveRepoPath(io, allocator, handler.is_test, handler.repo_root_path, handler.admin_repo_path, parsed.dir, create_if_missing)) {│ │223 + const repo_path = switch (try serve_common.resolveRepoPath(io, allocator, handler.repo_root_path, handler.admin_repo_path, parsed.dir, create_if_missing)) { │ │224 .ok => |p| p, │ │225 .invalid => return writeError(sess, "repo path must be <owner>/<repo>"), │ │226 .not_found => return writeError(sess, "repo not found"), │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯