showhelp: sort options allowed values
This commit is contained in:
parent
9a094b1a6b
commit
a37b45ec01
@ -50,6 +50,11 @@
|
||||
|
||||
printf(" --%-" .. length .. "s %s", trigger, description)
|
||||
if (option.allowed) then
|
||||
local function compareValue(a, b)
|
||||
return a[1] < b[1]
|
||||
end
|
||||
table.sort(option.allowed, compareValue)
|
||||
|
||||
for _, value in ipairs(option.allowed) do
|
||||
printf(" %-" .. length-1 .. "s %s", value[1], value[2])
|
||||
end
|
||||
|
Reference in New Issue
Block a user