refactor(git): rename refresh event to change, gate on actual diff

This commit is contained in:
2026-05-19 10:42:13 +02:00
parent 085216a406
commit ab9b70c70a
7 changed files with 25 additions and 16 deletions
+2 -2
View File
@@ -233,7 +233,7 @@ t.test("refresh emits change.paths listing structurally-changed paths", function
t.write(dir, "a", "2")
---@type ow.Git.Repo.Change?
local change_seen
local unsub = r:on("refresh", function(change)
local unsub = r:on("change", function(change)
change_seen = change
end)
r:refresh()
@@ -263,7 +263,7 @@ t.test("submodule: eagerly creates child Repos and subscribes by default", funct
t.write(outer_path .. "/sub", "a", "modified\n")
---@type ow.Git.Repo.Change?
local outer_change
local unsub = outer:on("refresh", function(change)
local unsub = outer:on("change", function(change)
outer_change = change
end)
inner:refresh()