feat(config): add forge config defaults and %l eol specifier
Problem: no configuration surface for forge link rendering, icons, issue format, or self-hosted instances. Solution: add `pending.ForgeConfig` class with per-forge `token`, `icon`, `issue_format`, and `instances` fields. Add `%l` to the default `eol_format` so forge labels render in virtual text.
This commit is contained in:
parent
6c6e62a2e2
commit
46b87e8f30
1 changed files with 30 additions and 1 deletions
|
|
@ -33,6 +33,17 @@
|
|||
---@field profile? string
|
||||
---@field region? string
|
||||
|
||||
---@class pending.ForgeInstanceConfig
|
||||
---@field token? string
|
||||
---@field icon? string
|
||||
---@field issue_format? string
|
||||
---@field instances? string[]
|
||||
|
||||
---@class pending.ForgeConfig
|
||||
---@field github? pending.ForgeInstanceConfig
|
||||
---@field gitlab? pending.ForgeInstanceConfig
|
||||
---@field codeberg? pending.ForgeInstanceConfig
|
||||
|
||||
---@class pending.SyncConfig
|
||||
---@field remote_delete? boolean
|
||||
---@field gcal? pending.GcalConfig
|
||||
|
|
@ -90,6 +101,7 @@
|
|||
---@field view pending.ViewConfig
|
||||
---@field max_priority? integer
|
||||
---@field sync? pending.SyncConfig
|
||||
---@field forge? pending.ForgeConfig
|
||||
---@field icons pending.Icons
|
||||
|
||||
---@class pending.config
|
||||
|
|
@ -106,7 +118,7 @@ local defaults = {
|
|||
max_priority = 3,
|
||||
view = {
|
||||
default = 'category',
|
||||
eol_format = '%c %r %d',
|
||||
eol_format = '%l %c %r %d',
|
||||
category = {
|
||||
order = {},
|
||||
folding = true,
|
||||
|
|
@ -141,6 +153,23 @@ local defaults = {
|
|||
priority_down = '<C-x>',
|
||||
},
|
||||
sync = {},
|
||||
forge = {
|
||||
github = {
|
||||
icon = '',
|
||||
issue_format = '%i %o/%r#%n',
|
||||
instances = {},
|
||||
},
|
||||
gitlab = {
|
||||
icon = '',
|
||||
issue_format = '%i %o/%r#%n',
|
||||
instances = {},
|
||||
},
|
||||
codeberg = {
|
||||
icon = '',
|
||||
issue_format = '%i %o/%r#%n',
|
||||
instances = {},
|
||||
},
|
||||
},
|
||||
icons = {
|
||||
pending = ' ',
|
||||
done = 'x',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue