fix(pack): consistently use "revision" instead of "state"

Problem: In some areas plugin's revision is named "state". This might be
  confusing for the users.

Solution: Consistently use "revision" to indicate "plugin's state on
  disk".
This commit is contained in:
Evgeni Chasnovski
2025-11-06 19:53:01 +02:00
parent f3f5095630
commit ee3239fcb6
5 changed files with 36 additions and 36 deletions

View File

@@ -18,7 +18,7 @@ local cur_header_hl_group = nil
local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false)
for i, l in ipairs(lines) do
local cur_group = l:match('^# (%S+)')
local cur_info = l:match('^Path: +') or l:match('^Source: +') or l:match('^State[^:]*: +')
local cur_info = l:match('^Path: +') or l:match('^Source: +') or l:match('^Revision[^:]*: +')
if cur_group ~= nil then
--- @cast cur_group string
-- Header 1
@@ -32,7 +32,7 @@ for i, l in ipairs(lines) do
local end_col = l:match('(). +%b()$') or l:len()
hi_range(i, cur_info:len(), end_col, 'DiagnosticInfo')
-- Plugin state after update
-- Plugin version after update
local col = l:match('() %b()$')
if col then
hi_range(i, col, l:len(), 'DiagnosticHint')