better dirname

[?]
Jul 6, 2022, 5:48 PM
ODRCS4NCOVGAWMYRI56DV242LFO6KY7N3O2JQ4UBZJVP7WOAXWFQC

Dependencies

  • [2] ZLEPKWDJ fork: capture frontend for a note-taking system
  • [3] VHQCNMAR several more modules

Change contents

  • replacement in file.lua at line 188
    [2.554][2.554:598]()
    return string.gsub(path, "(.*)/.*", "%1")
    [2.554]
    [2.598]
    return path:match('.*[/\\]') or './'
    end
    function test_dirname()
    check_eq(dirname('a/b'), 'a/', 'F - test_dirname')
    check_eq(dirname('x'), './', 'F - test_dirname/current')