Power of Nix but it's YAML (macOS and Linux)

(namios.dev)

20 points | by jktyjvhubb 8 hours ago

9 comments

  • astralkraft 4 hours ago
    Too little too late.

    Conda is taking over, and it has simple toml tools available from the very beginning of it's rise in popularity.

    https://pixi.prefix.dev/

    In raw users, outside of echo chambers in DevOps, Conda Forge has already won (Facebook money), and the tooling natively works equally well across Windows, MacOs, and Linux.

    Nix needed something like this 3-4 years ago

    • astralkraft 4 hours ago
      There's other tools as well:

      https://mise.jdx.dev/

      Conda support. No special hoops to jump through on Mac or Windows either.

      Convince me, why should I go back to using Nix at work in a mixed workstation environment? Why should I use a system based on a boutique language that's not transferable to any other domain, rather than write a TOML config?

    • nylonstrung 3 hours ago
      I don't think Nix and Conda are direct substitutes for each other, nor that it is "losing". Nix has 5x the number of packages and focused primarily on binaries
    • riedel 3 hours ago
      I don't know if conda has won. I am seeing exactly the opposite around me. People have moved away from conda. I myself ended up using nixos and devenv. Not caring to much about syntax as most stuff I get stuck can be inferred by an LLM.
      • astralkraft 2 hours ago
        I prefer not needing to get stuck in the first place, especially when I have work to do
        • riedel 1 hour ago
          This was only for figuring out nix syntax. In the end nix and particularly nixOS is much more expressive.

          So I would agree, that one does not want to get stuck overall, but point to the many times conda would not do due to either not being able to resolve either conflicts or wrapping more complex stuff.

          • astralkraft 1 hour ago
            Challenge accepted. I choose Mise: https://mise.jdx.dev/dev-tools/backends/

            Let's compare environments. Your Nix recipe vs my mise.toml file

            I will have exact, and up to date, versions of whatever we will need. Also, please share your environment with QA, PM, and cross team Leads.

            If expressiveness was the be all end all, we would all still be using using Ruby on Rails

            EDIT: mise is conda, and a few other goodies. I keep hearing of these mythical reasons that Nix is the only way my problems could be solved, and I can't understand the cult-like behavior. Nix truly is a Clive Barker Cult.

            • riedel 1 hour ago
              I meant conda, not mise—mise is actually great for what it does. I went with Nix so I can declaratively manage the entire devbox, from LUKS and remote initrd unlocking to bubblewrapping agent harnesses, which is outside mise's scope.
  • ktpsns 4 hours ago
    This is somewhat similar to https://cloud-init.io/ , an established standard to spin up new VMs/VPS from local KVM to cloudy land. In its simplest form it is a YAML file looking very similar to namios.
  • d3Xt3r 1 hour ago
    Unfortunately the problem with using Nixpkgs is that packages there are often behind upstream, or even completely non existent.

    For eg, ardour on Nixpkgs is still on 9.10, whereas on Arch it's at 9.11. Muse is on 4.2.1 vs 4.3.1 on Arch. dua is two releases behind (3.0.3 vs 3.1.1 on Arch). uv is even worse, it's three stable releases behind Arch (0.13.10 vs 0.13.13).

    And Lemonade doesn't even exist in Nixpkgs, whereas it's a regularly maintained repo package in Arch!

    So what's the point in boasting that you've got 150k packages?!

    So as an Arch user, I don't see why I should use Nixpkgs and suffer dealing with outdated or non-existent packages.

    • mpalmer 1 hour ago
      Do you use nix regularly? These are not problems one expects to hear from a practitioner.

      The last thing you want is a stable channel tracking the bleeding edge... you have the unstable channel for that.

      150k is by far the highest number of packages offered by any package manager. I don't think that's in dispute.

      Use what you want, always! But it is almost always trivial to specify the packages yourself wherever you need to depend on them, or find someone else's flake who has already done the same.

  • vivzkestrel 5 hours ago
    - sorry i dont get it, is this a brew.sh alternative?
  • max-privatevoid 43 minutes ago
    This is not the first yaml2nix thing, and it's unfortunately probably not the last, but AFAIK all the yaml2nix things before it have failed. Are some people really this averse to learning JSON, but swap ":" with "=", and "," with ";"?
  • zamalek 2 hours ago
    Replacing Nix with YAML (of all possibilities) is certainly a choice. I guess TOML was already taken as a porcelain.

    Maybe I will use some tokens to make a brainfuck porcelain this weekend.

  • TheFuzzball 5 hours ago
    "Jeez this YAML is verbose and unwieldy, maybe I need some sort of meta language to clean this up?" Oh...
  • aeve890 5 hours ago
    I know yaml is constantly trashed as unfit for configuration and almost always one would be better with a proper procedural language but this looks so clean next to nix I can't wait to give a try.
  • ProphetOfParado 5 hours ago
    I use Nix _because_ I hate YAML btw.