chore: add type hints for git.yazi (#111)

Co-authored-by: sxyazi <sxyazi@gmail.com>
This commit is contained in:
PFiS
2025-07-05 19:01:07 +08:00
committed by GitHub
parent e5f00e2716
commit cbc4450a6c
2 changed files with 37 additions and 2 deletions

12
git.yazi/types.lua Normal file
View File

@@ -0,0 +1,12 @@
---@class State
---@field dirs table<string, string|CODES> Mapping between a directory and its corresponding repository
---@field repos table<string, Changes> Mapping between a repository and the status of each of its files
---@class Options
---@field order number The order in which the status is displayed
---@field renamed boolean Whether to include renamed files in the status (or treat them as modified)
-- TODO: move this to `types.yazi` once it's get stable
---@alias UnstableFetcher fun(self: unknown, job: { files: File[] })
---@alias Changes table<string, CODES>