• kbal@fedia.io
    link
    fedilink
    arrow-up
    9
    arrow-down
    24
    ·
    2 days ago

    Windows can do symlinks now? Watch out, they’re slowly catching up.

    • mriswith@lemmy.world
      link
      fedilink
      English
      arrow-up
      9
      ·
      edit-2
      2 days ago

      This is like seeing those php jokes in programming humor communities. Because they’re clearly made by someone who is well over a decade out of date with their information.

      For reference symbolic links were properly introduced in Vista(2006), but junction points were available before that.

      • kbal@fedia.io
        link
        fedilink
        arrow-up
        4
        arrow-down
        1
        ·
        1 day ago

        MS Windows and PHP… yeah I can see the resemblance. They’re both crufty old tools that are obsolete for more than a decade but still widely used and talked about.

      • FizzyOrange@programming.dev
        link
        fedilink
        arrow-up
        4
        arrow-down
        1
        ·
        2 days ago

        You used to need admin or something like that. It’s only since about 2017 that they are available to normal users by default.

      • kbal@fedia.io
        link
        fedilink
        arrow-up
        3
        arrow-down
        5
        ·
        2 days ago

        It seems to have been a win 7 innovation. Personally I gave up on it after XP.

    • Onomatopoeia@lemmy.cafe
      link
      fedilink
      English
      arrow-up
      14
      ·
      2 days ago

      Think I first used a Symlink in about 1998.

      Pretty sure NT had the capability, though even the docs then advised against them.

      • forrgott@lemmy.sdf.org
        link
        fedilink
        English
        arrow-up
        4
        ·
        20 hours ago

        Heh. Yes they’re similar, but on the technical side different in a very important way. It has to do with opening a file from inside another program. If you select a shortcut, the program with treat or as a separate file, so most of the time the action will fail. A link, though, you should end up with the program opening the target of the link. In other words, a shortcut is a file that points at a different file, where a symlink involves she filesystem trickery to accomplish almost the same thing.

        That’s a horrible, just terrible explanation, though - but I’m pretty sure this is the gist of it.

        • FizzyOrange@programming.dev
          link
          fedilink
          arrow-up
          2
          ·
          edit-2
          20 hours ago

          The Plan 9 solution looks better to me. At the very least if you keep them then paths should be resolved lexically. I think most people are under the false impression that they are resolved lexically (i.e. foo/bar/../baz and foo/baz are the same).

          But IMO it’s better just to not have them and use another solution where you might have used them.

          • naught101@lemmy.world
            link
            fedilink
            arrow-up
            4
            ·
            19 hours ago

            Sorry, I didn’t follow any of that… What is the plan 9 solution? I searched, but didn’t see anything obvious

            • FizzyOrange@programming.dev
              link
              fedilink
              arrow-up
              1
              ·
              10 hours ago

              Basically it uses bind mounts instead. See this page for details.

              I haven’t actually used (since Plan 9 is dead) and I doubt it covers every use case for symlinks (e.g. this wouldn’t let you commit them to a git repo), but I really think the benefits of symlinks not existing at all would far outweigh the effort of having to think of alternative solutions.

              Sadly we don’t get to live in that alternative history now… :-/

      • sudo_halt@lemmygrad.ml
        link
        fedilink
        arrow-up
        1
        arrow-down
        2
        ·
        1 day ago

        It doesn’t matter if a bunch of crusty compsci academics think something is bad if it just works™ in real life

        And I am saying this as an academic. I’ve seen my colleagues write lots of papers that faded like a fart in a fan factory while Unix is still chewing ass and kicking gum 1970s style