> Tangram takes a lot of inspiration from nix, and could be described as a mix between nix and bazel where you write JS/TS
Devenv.sh: Fast and reproducible developer environments using Nix
71–80 of 171 posts
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#72this, devbox, and others seem to be alternatives to `nix-env shell` or the flake-based `nix develop`. spurred i think by a desire for better UX. these are excellent for any project off-the-ground enough that you’ve run `git init` or created a repo. the adjacent area i’m struggling with is the “i want to write a tiny program to verify some conjecture, and i’ll probably throw it away an hour from now”. think codegolf c…
asdf was the closest to this, but the startup time is pretty bad (there is a 300ms+ delay) for apps. It is a giant hack but works well. But I hear about weird dependency issues all the time with Macs (both Intel and the newer Apple Silicon) with Erlang or Elixir. I'm really excited for nix as true sandboxing would be great. Nix however I couldn't get working properly.. and I've been using Linux for almost 17 years. O…
Someone has told me that this can be solved with asdf-direnv so I am wondering if this is true and I should actually consider using asdf.
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#73Can someone explain to me the advantage of using Nix over containers? What do they offer that are not provided with using docker or other container platform.
For just the problem of "I want to be able to distribute the same application everywhere", container images solve this well. This can also be solved using Nix instead of container images; or Nix can even be used to build the container images.
The Nix expression language is much more expressive/powerful/elegant than Dockerfile's syntax is. -- Which can be useful for stuff like declaring "I want built with different build flags / patches".
Nix ends up being useful for scratching the itch of "put in effort now, to save effort later".
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#74Earlier quoted context omitted.
Don't know why it is downvoted but isn't it a legitimate concern that if dev and prod environments are produced differently with different tool chains, it might result in discrepancies? Concrete example, dev environment with nix but production is Dockerfile with apt getting packages? Thoughts?
That question never stopped developers from getting Apple hardware and OSX at their workplaces and it seems they've been productive, even though hardly anyone except mobile developers deploy anything on OSX. Besides, what's the point of having a production environment based on apt if it can be derived from the same graph of all dependencies that you use for building and running your software locally by Nix? [1] There…
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#75Another project I've been following in this space (no affiliation) is Tangram ( https://www.tangram.dev/ ), which I think of as "Nix, but TypeScript" -- or, from their Discord: > Tangram takes a lot of inspiration from nix, and could be described as a mix between nix and bazel where you write JS/TS
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#76Earlier quoted context omitted.
Do you use NixOS? I've found it a little too clunky for my taste, as a Gentoo Linux user. But maybe Nix is still worthwhile for me as a standalone tool.
I used Gentoo for over 15 years before switching to NixOS. I like it so much better, I'm never going back.
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#77Can someone explain to me the advantage of using Nix over containers? What do they offer that are not provided with using docker or other container platform.
Strictly compared to containers, the big advantages are reproducibility and lower overhead. Overhead: Windows and macOS can't run Linux-based containers natively. Instead, there's always a full Linux virtual machine running in the background acting as an intermediary and host for your containers. Nix can conjure arbitrary native development environments on a per-command or per-terminal basis, giving you all the perfo…
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#78Hi all, I'm the author of https://devenv.sh , https://cachix.org and https://nix.dev . I've been part of the Nix community for more than 10 years and in the last 4 years focused on making it documented, simple and accessible for any developer. After building Cachix (where you can store any software binaries with a few steps) we realized that there needs to be an intuitive interface for crafting developer environments…
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#79Earlier quoted context omitted.
Strictly compared to containers, the big advantages are reproducibility and lower overhead. Overhead: Windows and macOS can't run Linux-based containers natively. Instead, there's always a full Linux virtual machine running in the background acting as an intermediary and host for your containers. Nix can conjure arbitrary native development environments on a per-command or per-terminal basis, giving you all the perfo…
Would nix guarantee that all upstreams are available forever? Is nix planning to replace all upstreams? (PyPI, Conda, npm etc?) OR does it plan to keep a cache forever?
The build recipes pull from the original source and use a hash to ensure that the source artifacts don't change. Nix caching is usually done at the build output layer, e.g. the resulting binaries.
Re: Devenv.sh: Fast and reproducible developer environments using Nix
#80Can someone explain to me the advantage of using Nix over containers? What do they offer that are not provided with using docker or other container platform.
Strictly compared to containers, the big advantages are reproducibility and lower overhead. Overhead: Windows and macOS can't run Linux-based containers natively. Instead, there's always a full Linux virtual machine running in the background acting as an intermediary and host for your containers. Nix can conjure arbitrary native development environments on a per-command or per-terminal basis, giving you all the perfo…