Shameless plug: I am the author.

  • dinckel
    link
    fedilink
    742 months ago

    Golang puts shit specifically in $HOME/go. Not even .go. Just plain go.

    Why is it so difficult to follow industry standards

    • Eager Eagle
      link
      fedilink
      English
      52 months ago

      off the shelf go was too annoying for me

      Nowadays I set GOENV_ROOT to an XDG location and use goenv instead.

    • @[email protected]
      link
      fedilink
      English
      5
      edit-2
      2 months ago

      Go pisses me off with that. I separate projects the way I want but go wants every project written in go in one big directory?

      • dinckel
        link
        fedilink
        22 months ago

        I really didn’t like this either. It’s quite surprising, because the rest of Go tooling is quite nice. Not having a venv, or at least something like pnpm-style node_modules is weird

        • @[email protected]
          link
          fedilink
          12 months ago

          Why would go have a virtual environment or dep tree like node_modules equivalent, it’s not interpreted or dynamically linked.

          With modules, dependencies can be vendored.

          • dinckel
            link
            fedilink
            12 months ago

            Obviously it’s not, but you have to download all this shit somewhere before compilation. That’s the whole point

    • Bobby Turkalino
      link
      English
      32 months ago

      Google

      following industry standards

      pick one

  • @[email protected]
    link
    fedilink
    29
    edit-2
    2 months ago

    100% agree and I also despise devs who do this on windows, instead of using %appdata% they’re using c:\users\username\.myappisimportantandtotallydeservesthisdir

    • @[email protected]
      link
      fedilink
      22 months ago

      Not to mention - this isn’t necessarily the correct place for Windows anyway. That is exactly why they standardized stuff around Vista.

      Plus - what about apps that store an ungodly amount data in there? Personally, I only keep the OS and basic app data (such as configs and cache) on the partition and nothing else.

      Then something like Minecraft comes along and it’s like “humpty dumpty I’m crapping a lumpty” and stores all its data in “.minecraft” right there in your user directory.

      Then you gotta symlink stuff around and it becomes a mess…

  • @[email protected]
    link
    fedilink
    English
    122 months ago

    Here is a more concise way to achieve the same thing:

    ls -ACd ~/.??*/ | sed -e "s#$HOME/##g"
    
    • @[email protected]
      link
      fedilink
      22 months ago

      ls -A | grep "^\."

      I had to make a dummy .dotfile to test because I don’t have hidden files in my home.

    • @[email protected]
      link
      fedilink
      32 months ago

      Whoa I’m a stickler for getting as much as I can out but even I have .zshenv and some other too hard to figure out things in there. How’d you manage a total wipeout?

      • @[email protected]
        link
        fedilink
        3
        edit-2
        2 months ago

        zsh is actually easy and it is detailed in the archwiki

        You have to set $ZDOTDIR in /etc/zsh/zshenv and iirc that was the only location that required root to edit.

        For the rest of stuff, here is how I fix steam for example and you can check the rest of my dotfiles for how I configured zsh and all of that.

        Although I haven’t updated them, I still had a .local directory back then, it was 1 week ago that I changed .local for Local and that let to an issue with distrobox which I made a PR fixing it that’s still open though.

      • @[email protected]
        link
        fedilink
        12 months ago

        It’s empty lol, it’s a directory on tmpfs that i use to build programs and similar stuff to not be hammering my ssd with unnecessary writes.

        I have $XDG_CACHE_HOME in tmp as well and I moved the mesa sharer caches to $XDG_STATE_HOME as that’s really the only thing so far I’ve needed to preserve.

        • @[email protected]
          link
          fedilink
          English
          1
          edit-2
          2 months ago

          tmpfs (…) to build programs (…) to not be hammering my ssd with unnecessary writes

          Sounds useful. How did you setup the directory?

          Running df tells me “tmpfs” is mounted on /run. If I build in that that directory then would it be stored in RAM, or do I need to do something else?

          • @[email protected]
            link
            fedilink
            22 months ago

            I have /tmp in my fstab with these mount options.

            tmpfs /tmp tmpfs rw,noatime,size=20G 0 0

            And the rest of the setup is done in my zprofile

            • @[email protected]
              link
              fedilink
              English
              2
              edit-2
              2 months ago

              I think I should be able to get this working following your zprofile file. Thanks!

  • Mactan
    link
    fedilink
    72 months ago

    there’s no place like 127.0.0.1

    there’s no place like XDG_CONFIG_HOME.

  • wvstolzing
    link
    fedilink
    32 months ago

    vim now has an option to put the .vim folder in ~/.config; though I’m not sure if the default plugin/package & syntax folders can be set under ~/.local/share.

  • davel [he/him]
    link
    fedilink
    English
    -62 months ago

    This would just further complicate things for me. It assumes that 1) the system even has a windowing system/desktop environment or 2) all the installed software is XDG-aware. Most of the time I’m fiddling with headless environments.

    • Eager Eagle
      link
      fedilink
      English
      8
      edit-2
      2 months ago

      The spec doesn’t make those assumptions at all, idk where that’s coming from.

      I have headless machines with XDG vars configured and ones without them. XDG compliant software works in either case, but I’m less likely to use a piece of software that clutters my $HOME.

  • @[email protected]
    link
    fedilink
    -102 months ago

    But what’s the difference? It’ll be in /home anyways and I heard BSD had some issues with something that could be XDG.

    • @[email protected]
      link
      fedilink
      122 months ago

      Better organization and backup / restore. For example if you want to restore config files but don’t want to move over the large “.local” folder, applications that write to $HOME will create diifculty.

    • @[email protected]
      link
      fedilink
      92 months ago

      Because, like /etc, you know there is a designated place for config files. It’s already set for you right there, and there is a standard for it.

      • @[email protected]
        link
        fedilink
        -2
        edit-2
        2 months ago

        /etc is a standard, defined in the filesystem hierarchy standard. This is not:

        freedesktop.org produces specifications for interoperability, but we are not an official standards body. There is no requirement for projects to implement all of these specifications, nor certification.

        Below are some of the specifications we have produced, many under the banner of ‘XDG’, which stands for the Cross-Desktop Group.

        Its nit-picking, but this is a specification, i.e a preference, not an official standard. It would be great if everyone would agree on just one of these to use, but that isn’t a foregone conclusion. Even the actual standard, the FHS, isn’t followed by popular OS’s like NixOS.

          • @[email protected]
            link
            fedilink
            -2
            edit-2
            2 months ago

            All specifications exist for a reason, and they all have a clear purpose.

            What happens when you have 15 that are different and all overlap? When any of 15 is “right?”

            • @[email protected]
              link
              fedilink
              English
              12 months ago

              I’ve only ever heard of FHS or XDG. Due to the free nature of linux distros, there is no central authority on how they are to be set up, and so there is no difference between those two options in terms of authority. Standards (which XDG is, colloquially) are followed based on popularity.

              • @[email protected]
                link
                fedilink
                22 months ago

                Yeah, I fully get that. The post and comments were very specific about how if you dont follow XDG, you’re fucking up, while only generally saying that “everything would be better if everyone followed the same standard.”

                I pointed out that there are several standards and asked for a unique reason why XDG was the best to use.

                I still haven’t heard one, which is fine, but it undermines the “If youre not using, XDG youre a idiot” tone of the post and comments.

                • @[email protected]
                  link
                  fedilink
                  English
                  12 months ago

                  I think the logic is that it’s the most used, so to avoid seriously competing standards, it’s better to stick with it.

      • @[email protected]
        link
        fedilink
        -42 months ago

        /etc can’t be edited on immutable distros and usually apps store the editable config in /home/config and make the /etc one kind of read-only.