Skip to content

tpl: Create functions to inspect the union file system #12321

@jmooring

Description

@jmooring

Reference: https://discourse.gohugo.io/t/methods-to-traverse-the-virtual-filesystem/49058/

{{ ufs.ReadDir }}
{{ ufs.FileExists }}

Why not just modify os.ReadDir and os.FileExists?

  1. We wouldn't have to worry about breaking existing sites
  2. We're not inspecting the OS file system; we're inspecting the union file system

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions