Nix Documentation | 435 Members | |
| Discussion about documentation improvements around the Nix ecosystem | 92 Servers |
| Sender | Message | Time |
|---|---|---|
| 17 Aug 2022 | ||
| starting with a configuration.nix switching to flake.nix switching to a flake that you find on github. switching to another one.. deciding to write your own flake again .. | 15:18:03 | |
| finding a flake configuration that have a similar setup makes understanding so much easier. and frameworks like digga are really hard to understand in the first try | 15:20:07 | |
| sorry english is not my native tongue 😄 i just talking about my experiences from the last year | 15:20:55 | |
| imho, and i've expressed this to various people looking for help, flakes have been overcomplicated | 15:21:26 | |
| yes.. and as soon you use a flake config that use some homemade libs, most instructions on websites are not working anymore | 15:22:40 | |
| its really hard to write a config only with the understanding for programing. its a big plus to understand the nixlang... and i normally can hack my why into most stuff 😄 i can use/create/modify neovim configs in lua without speaking lua. i can fix python stuff without fully understand python.. but with flakes i really feel lost | 15:25:31 | |
| 18:32:41 | ||
| 20:21:33 | ||
| 18 Aug 2022 | ||
| 03:07:05 | ||
| Hi folks, Nix noob here, I have a few small thoughts about rough edges on the "new user experience" where some aspects of the docs took me 5-10 mins of digging where I feel they could have been structured to hand-hold a bit better. I've just gone through the Rust Book and so I've got some good contrast for how nice a ramp-up doc can be. Is it useful to share nits and other suggestions here? I feel like most of my input is too small to justify a Github issue. | 03:10:43 | |
| i'd say go ahead | 03:18:54 | |
| i was a new user a few years ago but i've forgotten all those bits | 03:19:11 | |
| but like the view from up here (if you'll indulge me for a moment) i wonder if the way people approach nix is right | 03:20:56 | |
| 👍️ OK here goes. I started off on https://nixos.org/learn.html, clicked "First steps...", and got to https://nixos.org/guides/ad-hoc-developer-environments.html. My first bit of feedback on the nix CLI tools is that all of the commands have this long delay that makes me wonder if I installed it right; for example As an aside, I'm already thinking "-qaP ?" I think as a mnemonic/teaching aid, using the full | 03:28:36 | |
| Next, the "reproducible executables" example doesn't explicitly say "put this into a file, chmod +x it, and then run the file". I think being more explicit about what you want the user to do with that blob of text would be helpful. This is clearer on https://nix.dev/tutorials/ad-hoc-developer-environments#ad-hoc-envs which I found later and which has better formatting | 03:32:32 | |
| The comment "The -I flag pins the Nixpkgs revision to an exact Git revision, leaving no doubt about which exact version of Nix packages will be used." makes my eyes glaze over. How do I get that git revision? Is a user really expected to do this? In practice I don't think I'd use a shell one-liner this way, I'd use a shell.nix, right? I think this example is bringing in immutability a bit too early, even though it's a defining feature. | 03:34:40 | |
Sandro 🐧: nix-env -qaP is definitely a thing to take out in your "sync with best practices" PR | 03:36:56 | |
| do you feel familiar with git and github? | 03:37:52 | |
| The next bit https://nixos.org/guides/towards-reproducibility-pinning-nixpkgs.html#pinning-nixpkgs talks more about this, and feels like the good stuff. But it abandons the python example from before, and so I can't figure out how to use niv. I want to say something like
Not a friendly error message, and I feel like the doc is missing a chance to continue to build on the previous page. | 03:38:28 | |
| Now that I think of it,
-- where is the python38 coming from? (By which I mean, how does a new user figure out what python3* exist to use?) One thing the Rust docs (and ecosystem more generally) do is liberally link between different sources of information, so if there is a doc repository hosting the | 03:42:31 | |
| Final note -- I feel like this brushes over some core concepts: "You can use the generated nix/sources.nix with a top-level default.nix" Before you tell me to do a | 03:45:30 | |
| can i ask what brought you to nix? | 03:45:31 | |
| and do you have any particular goals in using it? if you are trying to get set up with django i imagine you are a python programmer | 03:47:43 | |
| (also that previous q about: do you feel familiar with git and github?) | 03:48:54 | |
| I hear a lot of people preaching on HN about how nice it is, and I see the appeal of setting up developer environments and CI/CD pipelines. I found that on MacOS at least, every 6 months my "new developer" guide for my team broke because of some library/OS change, and I am interested to see if doing things immutably, the Nix way, would be better. Currently my dev env stack is (MacOS): pyenv, pyenv-virtualenv, poetry (would switch if other packaging systems integrated better), PyCharm. I use yarn and webpack for JS stuff. And everything goes into a Docker container and gets deployed to Kubernetes. While I'm mostly writing Python I just followed the example in the docs. I have Docker as my "blessed environment" for builds and CI/CD, but it's annoying to ask developers to use Docker for their local dev loop. So we have two different env setups, one for local dev, and one for CI/CD build and prod deploy. | 03:51:54 | |
| I'm familiar with the git toolchain. | 03:52:28 | |
| and presumably some form of git hosting service? | 03:54:53 | |
| Yes, I've run projects on Github and Gitlab in the past | 03:55:08 | |
| one last random sounding question: do you use apple silicon macs? | 03:56:00 | |
| * one last random sounding question: do you use apple silicon macs? (and is that where you ran your niv command)? | 03:56:09 | |