It’s the “path of traversal” on a graph

  • gedaliyah@lemmy.world
    link
    fedilink
    arrow-up
    5
    arrow-down
    1
    ·
    5 days ago

    Is there a file system graph that’s not a tree? Like a folder that contains a folder that contains itself?

    • Aniki@feddit.org
      link
      fedilink
      arrow-up
      10
      ·
      5 days ago

      symbolic links come to mind. there’s soft and hard symbolic links. soft links you probably know, it’s just one item in the tree that points to another. hard links are more intricate because you (the user) cannot easily differentiate them from an ordinary file / directory. it’s basically hacking the file system to lead you in circles. this way, a directory can contain itself, which means that it’s not a tree anymore.

      • forestbeasts@pawb.social
        link
        fedilink
        arrow-up
        1
        ·
        edit-2
        3 days ago

        Which is probably why Unix tends to disallow hardlinks to directories.

        They’re not physically impossible; on Mac, Time Machine even creates them (there’s some kind of special thing it has to do to be allowed to do that, I think). The system design people just went “yeah, that’s a bad idea”.

        Which is slightly impressive coming from the people who decided newlines in filenames were perfectly fine, on a system where it’s very common practice to sling data around as a list of lines.

        (I like the fact that literally every other character is allowed. Including spaces. Dealing with spaces isn’t too terrible! It’d just be way easier to deal with things in a guaranteed correct fashion if newlines in filenames weren’t allowed.)

        – Frost

    • whaleross@lemmy.world
      link
      fedilink
      arrow-up
      1
      ·
      edit-2
      5 days ago

      I’ve talked before about my old idea about a tag based file system but it is purely theoretical yet afaik. Basically it is an object database where it doesn’t matter how you order the relevant tags. /a/b/file and /b/a/file are the same thing.

        • whaleross@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          5 days ago

          Thanks!

          Starting in around 2004, a new wave of implementations centered on manual tagging of files and folders.

          Wow, this was about the time I came up with the idea. Then again it was the time of blogs and tag clouds, so…

    • 4am@lemmy.zip
      link
      fedilink
      arrow-up
      1
      ·
      5 days ago

      Does object storage count? Those are usually identified by a single key; although I guess you could count cloud tenancy and buckets as “folders”

      • Lysergid@lemmy.ml
        link
        fedilink
        arrow-up
        1
        ·
        edit-2
        5 days ago

        Wouldn’t same be the case for normal files systems? I think, technically, files on disk stored as flat structure plus tree structure which tracks physical files bytes location on the disk. Is there a file system which actually stores dirs/files data as tree? Adding something into folder would mean moving data of next folder to create “room” for new stuff

  • Karu 🐲@lemmy.ml
    link
    fedilink
    arrow-up
    3
    arrow-down
    1
    ·
    5 days ago

    Semantic file systems are very much not tree-shaped. The idea of a semantic file system is that files don’t have a single parent or container, like a folder in a traditional hierarchical file system, and instead a file’s location is represented by a combination of tags. As expected, you don’t traverse a path to reach a file, but rather, you perform a query not unlike operators in a search engine.