1
0
Fork 0

various changes I don't remember.. again, lol

This commit is contained in:
Peter Domínguez 2026-02-28 13:39:46 -04:00
parent 06508d53ac
commit a3faa34f5e
13 changed files with 425 additions and 485 deletions

View file

@ -1,4 +1,4 @@
--- @since 25.5.31
--- @since 25.12.29
local WINDOWS = ya.target_family() == "windows"
@ -125,12 +125,7 @@ local add = ya.sync(function(st, cwd, repo, changed)
st.repos[repo][path] = code
end
end
-- TODO: remove this
if ui.render then
ui.render()
else
ya.render()
end
ui.render()
end)
---@param cwd string
@ -142,12 +137,7 @@ local remove = ya.sync(function(st, cwd)
return
end
-- TODO: remove this
if ui.render then
ui.render()
else
ya.render()
end
ui.render()
st.dirs[cwd] = nil
if not st.repos[repo] then
return
@ -189,8 +179,12 @@ local function setup(st, opts)
}
Linemode:children_add(function(self)
if not self._file.in_current then
return ""
end
local url = self._file.url
local repo = st.dirs[tostring(url.base)]
local repo = st.dirs[tostring(url.base or url.parent)]
local code
if repo then
code = repo == CODES.excluded and CODES.ignored or st.repos[repo][tostring(url):sub(#repo + 2)]
@ -208,7 +202,7 @@ end
---@type UnstableFetcher
local function fetch(_, job)
local cwd = job.files[1].url.base
local cwd = job.files[1].url.base or job.files[1].url.parent
local repo = root(cwd)
if not repo then
remove(tostring(cwd))