Skip to content

Commit

Permalink
#667 added --terse_show_extensions option for avail
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcawood committed Jan 19, 2024
1 parent a9876ac commit 067d1e9
Showing 1 changed file with 4 additions and 16 deletions.
20 changes: 4 additions & 16 deletions src/Hub.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1166,18 +1166,13 @@ function M.terse_avail(self, mpathA, availA, alias2modT, searchA, showSN, defaul
local extA = {}
self:buildExtA(searchA, mpathA, providedByT, extA)


a[#a+1] = "TEST"

for i =1,#extA do
a[#a+1] = extA[i]
for i=1,#extA do
a[#a+1] = "#"
a[#a+1] = extA[i][1]
a[#a+1] = "\n"
end
end




dbg.fini("Hub:terse_avail")
return a
end
Expand Down Expand Up @@ -1245,7 +1240,7 @@ function M.avail(self, argA)
searchA.n = argA.n
end

if (optionTbl.terse) then
if (optionTbl.terse or optionTbl.terseShowExtensions) then
--------------------------------------------------
-- Terse output
local spiderT = false
Expand Down Expand Up @@ -1392,13 +1387,6 @@ function M.avail(self, argA)
local extA = {}
self:buildExtA(searchA, mpathA, providedByT, extA)


for i=1,#extA do
a[#a+1] = "#"
a[#a+1] = extA[i]
a[#a+1] = "\n"
end

if (next(extA) ~= nil) then
legendT['E'] = i18n("Extension")
numFound = numFound + #extA
Expand Down

0 comments on commit 067d1e9

Please sign in to comment.