refactor: remove file token feature (#50)
* refactor: remove file token feature Problem: The file metadata token (file:<path>:<line>) was implemented but is no longer wanted. Solution: Remove all traces — parse.lua token parsing, diff.lua reconciliation, views.lua LineMeta field, buffer.lua virtual text and PendingFile highlight, complete.lua omnifunc trigger, init.lua goto_file/add_here functions and -file edit token, plugin keymaps <Plug>(pending-goto-file) and <Plug>(pending-add-here), config.lua goto_file keymap field, vimdoc FILE TOKEN section, and spec/file_spec.lua. * ci: format
This commit is contained in:
parent
41bda24570
commit
103e2036c8
10 changed files with 6 additions and 598 deletions
|
|
@ -416,7 +416,7 @@ end
|
|||
|
||||
---@param text string
|
||||
---@return string description
|
||||
---@return { due?: string, cat?: string, rec?: string, rec_mode?: 'scheduled'|'completion', file?: string? } metadata
|
||||
---@return { due?: string, cat?: string, rec?: string, rec_mode?: 'scheduled'|'completion' } metadata
|
||||
function M.body(text)
|
||||
local tokens = {}
|
||||
for token in text:gmatch('%S+') do
|
||||
|
|
@ -481,18 +481,7 @@ function M.body(text)
|
|||
metadata.rec = raw_spec
|
||||
i = i - 1
|
||||
else
|
||||
local file_path_val, file_line_val = token:match('^file:(.+):(%d+)$')
|
||||
if file_path_val and file_line_val then
|
||||
if metadata.file then
|
||||
break
|
||||
end
|
||||
metadata.file = file_path_val .. ':' .. file_line_val
|
||||
i = i - 1
|
||||
elseif token:match('^file:') then
|
||||
break
|
||||
else
|
||||
break
|
||||
end
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -510,7 +499,7 @@ end
|
|||
|
||||
---@param text string
|
||||
---@return string description
|
||||
---@return { due?: string, cat?: string, rec?: string, rec_mode?: 'scheduled'|'completion', file?: string? } metadata
|
||||
---@return { due?: string, cat?: string, rec?: string, rec_mode?: 'scheduled'|'completion' } metadata
|
||||
function M.command_add(text)
|
||||
local cat_prefix = text:match('^(%S.-):%s')
|
||||
if cat_prefix then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue