╭──────────╮ │← previous│ ╰──────────╯ ╭ changed ──────────╮ │src/event/Issue.zig│ ╰───────────────────╯ ╭─────────────────────────────────────────────────────────────╮ │198 repo: *rp.Repo(repo_kind, repo_opts), │ │199 id_bytes: *const [evt.event_id_size]u8, │ │200 change: Update, │ │201 - author_email: []const u8, │ │201 + author: evt.CommitAuthor, │ │202 ) !void { │ │203 var arena = std.heap.ArenaAllocator.init(allocator);│ │204 defer arena.deinit(); │ ╰─────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │225 try evt.consume(repo_kind, repo_opts, io, allocator, repo, evt.events_ref, &[_]evt.EventWithId{.{│ │226 .id = std.fmt.bytesToHex(id_bytes.*, .lower), │ │227 .timestamp = @intCast(std.Io.Timestamp.now(io, .real).toSeconds()), │ │228 - .author_email = author_email, │ │228 + .author = author, │ │229 .event = .{ .issue = updated }, │ │230 }}); │ │231 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────╮ │src/event/User.zig│ ╰──────────────────╯ ╭────────────────────────────────────────────╮ │ 6 const bcrypt = std.crypto.pwhash.bcrypt;│ │ 7 │ │ 8 name: []const u8, │ │ 9 -display_name: []const u8, │ │ 9 email: []const u8, │ │10 password_hash: []const u8, │ │11 enable_ansi: bool = true, │ ╰────────────────────────────────────────────╯ ╭───────────────────────────────────────────────╮ │27 // the subset of a user that anyone may see│ │28 pub const Public = struct { │ │29 name: []const u8, │ │31 - display_name: []const u8, │ │30 }; │ │31 │ │32 const Self = @This(); │ ╰───────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────╮ │282 try evt.consume(.xit, repo_opts, io, allocator, repo, evt.events_ref, &[_]evt.EventWithId{.{│ │283 .id = std.fmt.bytesToHex(user_id[0..evt.event_id_size].*, .lower), │ │284 .timestamp = @intCast(std.Io.Timestamp.now(io, .real).toSeconds()), │ │287 - .author_email = user.event.email, │ │285 + .author = .{ .name = user.event.name, .email = user.event.email }, │ │286 .event = .{ .user = updated }, │ │287 }}); │ │288 } │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ───╮ │src/main.zig│ ╰────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────╮ │12 pub const RunOpts = struct { │ │13 out: *std.Io.Writer, │ │14 err: *std.Io.Writer, │ │15 + // the user's global git config, used for the commit identity in local mode.│ │16 + // null by default so tests and the server paths never read it. │ │17 + global_config_path: ?[]const u8 = null, │ │18 }; │ │19 │ │20 pub fn main(init: std.process.Init) !u8 { │ ╰────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────╮ │38 │ │39 var stdout_writer = std.Io.File.stdout().writer(io, &.{}); │ │40 var stderr_writer = std.Io.File.stderr().writer(io, &.{}); │ │38 - const run_opts = RunOpts{ .out = &stdout_writer.interface, .err = &stderr_writer.interface };│ │41 + │ │42 + var environ_map = try std.process.Environ.createMap(init.minimal.environ, allocator); │ │43 + defer environ_map.deinit(); │ │44 + const global_config_path = try xit.config.globalConfigPath(io, allocator, &environ_map); │ │45 + defer if (global_config_path) |path| allocator.free(path); │ │46 + │ │47 + const run_opts = RunOpts{ │ │48 + .out = &stdout_writer.interface, │ │49 + .err = &stderr_writer.interface, │ │50 + .global_config_path = global_config_path, │ │51 + }; │ │52 │ │53 const cwd_path = try std.process.currentPathAlloc(io, allocator); │ │54 defer allocator.free(cwd_path); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │106 }; │ │107 const found_len = if (found) |f| f.path.len else 0; │ │108 if (work_path.len > found_len) { │ │ 96 - found = .{ .path = try session_arena.allocator().dupe(u8, work_path), .repo_kind = probe_kind };│ │109 + found = .{ │ │110 + .path = try session_arena.allocator().dupe(u8, work_path), │ │111 + .repo_kind = probe_kind, │ │112 + .global_config_path = run_opts.global_config_path, │ │113 + }; │ │114 } │ │115 } else |err| switch (err) { │ │116 error.RepoNotFound => {}, │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────╮ │src/test/event.zig│ ╰──────────────────╯ ╭────────────────────────────────────────────────────────────────────────────╮ │ 5 const rf = xit.ref; │ │ 6 const hash = xit.hash; │ │ 7 │ │ 8 -const author_email = "user@haxy"; │ │ 8 +const author = evt.CommitAuthor{ .name = "haxy", .email = "user@haxy" };│ │ 9 │ │10 test "rebase" { │ │11 const io = std.testing.io; │ ╰────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────╮ │48 const events_to_consume = [_]evt.EventWithId{ │ │49 .{ │ │50 .id = std.fmt.bytesToHex(first_event_id, .lower), │ │51 - .author_email = author_email, │ │51 + .author = author, │ │52 .event = .{ │ │53 .issue = .{ │ │54 .title = "Login form clears password on validation error",│ ╰──────────────────────────────────────────────────────────────────────────────────╯ ╭──────╮ │next →│ ╰──────╯