support viewing dotfile docs; closes #104

This commit is contained in:
ed 2024-10-11 22:06:43 +00:00
parent 1d68acf8f0
commit 9ccd8bb3ea

View file

@ -5467,7 +5467,11 @@ class HttpCli(object):
if doc: if doc:
j2a["docname"] = doc j2a["docname"] = doc
doctxt = None doctxt = None
if next((x for x in files if x["name"] == doc), None): dfn = lnames.get(doc.lower())
if dfn and dfn != doc:
# found Foo but want FOO
dfn = next((x for x in files if x["name"] == doc), None)
if dfn:
docpath = os.path.join(abspath, doc) docpath = os.path.join(abspath, doc)
sz = bos.path.getsize(docpath) sz = bos.path.getsize(docpath)
if sz < 1024 * self.args.txt_max: if sz < 1024 * self.args.txt_max: