<egasimus>
I'm having the same problem trying to build a very simple package with yarn2nix
meh` has quit [Ping timeout: 265 seconds]
<egasimus>
could probably override the whole thing to get a `ln -sf` in there
<egasimus>
would prefer to figure out where it's going wrong first though
dbmikus has joined #nixos
<egasimus>
also if anyone else with a clue about yarn2nix could chime in, that'd be much appreciated
<{^_^}>
[nixpkgs] @peti pushed to haskell-updates « hackage-packages.nix: automatic Haskell package set update »: https://git.io/JTVvP
sss2 has quit [Quit: Leaving]
<ajs124>
egasimus: I don't really remember. It's been over a year, so I barely have any recollection of ever working on this.
jdnixx has joined #nixos
<egasimus>
ajs124: fair enough
<jdnixx>
when a derivation fails to build where in the error output should I look for the root problem?
<jdnixx>
like where does it mention it
<jdnixx>
I'm looking at the wall of text after megasync failed to build from source i guess
<jdnixx>
ooooh ok nvm I think it's all the same error:
<jdnixx>
gui/InfoDialog.cpp:1011:149: warning: 'static QString QString::fromAscii(const char*, int)' is deprecated [-Wdeprecated-declarations] ------------------- In file included from /nix/store/blahblah-qtbase-5.14.2-dev/include/QtGui/qdesktopservices.h:44,
<jdnixx>
qt problem or? I couldn't find anything in the nixpkgs issues and it's been happening for like a week or 2 at least
<{^_^}>
[nixpkgs] @jonringer pushed commit from @sikmir to master « python3Packages.pygmt: init at 0.2.0 »: https://git.io/JTVUu
dbmikus has quit [Ping timeout: 240 seconds]
<{^_^}>
[nixpkgs] @jonringer merged pull request #101515 → blugon: fix build on darwin → https://git.io/JTajL
<{^_^}>
[nixpkgs] @jonringer pushed commit from @r-burns to master « blugon: fix build on darwin »: https://git.io/JTVUV
<matthewcroughan_>
Hey hey hey
<matthewcroughan_>
I'm finally getting around to setting my laptop up
<matthewcroughan_>
I've had this damned new laptop for months and have just neglected to properly configure nixos on it.
justanotheruser has joined #nixos
<matthewcroughan_>
Wayland better be fully usable at this stage :D
<matthewcroughan_>
(Wishful thinking)
<matthewcroughan_>
:O a real derivation compile error wtf
<matthewcroughan_>
builder for '/nix/store/xxmfz4k662q86j1xvsb3pifbcwm3vxwx-waybar-9ea13e790d463fc40a467862eb6835db17d6cd0b.drv' failed with exit code 1
<{^_^}>
[nixpkgs] @egasimus opened pull request #101521 → Expose mkYarnModules' postBuild as yarnPostBuild → https://git.io/JTVIL
ericsagnes has joined #nixos
<{^_^}>
[nixpkgs] @r-burns opened pull request #101522 → bandwidth: fix build on darwin, fix license, adopt → https://git.io/JTVIK
<matthewcroughan_>
bqv: Yeah uh, the issue was that I needed to update my channels.
<matthewcroughan_>
`nix-channel --update`
<bqv>
✌
<matthewcroughan_>
What on earth is that character.
<matthewcroughan_>
What the hell is that ._.
<danderson>
so... I made a flake-based nixos config. It had an error and failed eval, so I fixed it. But now nixos-rebuild just exits with "cached failure of attribute 'nixosConfigurations.vega.config'
<danderson>
... without telling me what or why or how to fix it. Halp?
<danderson>
never mind, was editing the wrong file when I fixed the failure. Would still be nice to reprint the error though.
<matthewcroughan_>
That's interesting, I thought what I proposed was the right way of doing it.
<matthewcroughan_>
secrets.nix contains a bunch of vars, there could be a way to make it like this, right? Securely.
<matthewcroughan_>
Seems intuitive to me.
<qyliss>
unfortunately not, because when Nix "instantiates" a Nix expression, it gets stored in the store (in a sort of compiled form -- this is a .drv file)
<qyliss>
and the store is world readable by design
<qyliss>
and so any value you put in a nix expression will end up world readable in the store
<matthewcroughan_>
Alright, that's a good architectural reason :D
<matthewcroughan_>
Damn!
<qyliss>
In general, a common strategy for secrets is to keep them somewhere outside of Nix, on disk, and then have a Nix expression that copies them into place
<qyliss>
or just generates them if they don't exist, if it's something like an ssh host key
<matthewcroughan_>
Yeah like a zfs encrypted dataset.
<qyliss>
there are various things you can try, but there's not any consensus solution yet, and so it's a bit of an advanced topic, unfortunately
<matthewcroughan_>
Is home-manager worth it, even if I'm the only user of a system?
<qyliss>
if you're not worried too much about your wifi passwords, you might decide it's fine to keep them in the store for now (but always remember to be careful with more confidential secrets), or try network-manager. Come back to secrets once you've got the basics down.
<qyliss>
matthewcroughan_: it comes in handy when you want to use a system that isn't running NixOS
<qyliss>
there are also some modules that are only in home manager, because it wouldn't make sense for them to be system-wide
<qyliss>
but I say all this as a non-home-manager user. I appreciate that it exists but have never had the need for it myself.
<qyliss>
another nice thing is that it probably helps you seperate user configuration from system configuration, if that's something you're interested in (I'm not particularly but lots of people feel quite strongly about that)
<matthewcroughan_>
How many imports do you have in your main config?
<cole-h>
I only have one (in both my system config and home config) -- `./modules`, which has a default.nix which imports lots of other stuff :P
<qyliss>
I have a big forest of imports spanning that goes several layers deep
<danderson>
okay, I have a nix syntax question. I'm trying out flakes for nixos, and something I'd like is to import modules in other files, and be able to reference the overall flake's inputs. My sample (based on Tweag's blog posts) is https://gist.github.com/danderson/8fb37571768945456df8801d8e9aee18 , but evaluation fails in test.nix with an infinite recursion.
<danderson>
I'm quite sure I'm failing to understand how the various arguments seemingly magically propagate from place to place. What am I doing wrong?
<cole-h>
danderson: the inputs are only available in flake.nix
<cole-h>
So if you were to inline ./test.nix, it would work
<danderson>
Right, I had that working. So how do I factor my configuration into more files, the way I would have done with "classic" nix?
<qyliss>
wow that's spooky
<cole-h>
You could also set `specialArgs` (which is a feature of the module system IIRC), and `inherit inputs;`, which is what I do.
<danderson>
hm. Both these things further confuse me, but they're keywords I can google to figure it out. Thanks!
<cole-h>
e.g. `specialArgs = { inherit inputs; }` (which requires you to bind your inputs to that variable)
<matthewcroughan_>
I just take that for granted in all nix files but don't even know what it is.
<bqv>
I'm working on it >_>
<cole-h>
Hehe
<danderson>
hmkay, I think I see what you mean. Let's see now...
<matthewcroughan_>
cole-h: Can we make nix derivations for channels we host privately, that basically just give friends games in their perfect environment? :P
<matthewcroughan_>
e.g deus ex, or some windows game with a crazy wine config, just `nix-shell` it.
<cole-h>
Live-reloading nix-shell, I guess I'd describe it
<qyliss>
lorri is like nix-shell except it builds new versions of the environment in the background, so you can keep using the old one while you wait for it to build
<matthewcroughan_>
that's so screwed up
<matthewcroughan_>
:v
<matthewcroughan_>
the world is getting crazy
<matthewcroughan_>
livestreaming code directly into your system
<matthewcroughan_>
I mean that in a good way. It's just so insane what lorri is doing.
<danderson>
hmkay, now the reference works, but hydra no longer builds due to missing packages. So... Progress, I suppose?
<danderson>
ah, hmm. The hydra derivation also references inputs directly. So, in overriding it, presumably I've nuked the lock from that flake and replaced it with whatever I'm doing
<matthewcroughan_>
cole-h: so lorri doesn't even subprocess nixos-rebuild switch?
<matthewcroughan_>
it actually works with the primitives of nix, to deliver this experience?
<qyliss>
lorri is only for nix-shell
<qyliss>
it won't live rebuild your system for you
<matthewcroughan_>
Yes, I know, but it's like.. How is it so fast
<matthewcroughan_>
I couldn't write a bash wrapper that was this fast.
<matthewcroughan_>
Or could I?
<cole-h>
It's written in Rust :)
<qyliss>
it's fast because everything happens asynchronously
<qyliss>
there's a daemon that's always running in the background
<danderson>
yeah okay, that looks about right. Hydra expects inputs.nixpkgs to be unstable, and with extraArgs I stomped that with a 20.03 version. I think.
<omasanori[m]>
@bqv Not yet, but I had tried quicklisp-to-nix several times, while I could not add new package successfully at that time.
<matthewcroughan_>
cole-h: holy crap, I see exactly how you're using home-manager
<cole-h>
:)
<matthewcroughan_>
is this a good thing? To have everything as a separate module like this
<cole-h>
Good is subjective.
<matthewcroughan_>
So you just don't have any dotfiles?
<matthewcroughan_>
You only have nix modules?
<cole-h>
I like it, because it makes it easy to search through
<cole-h>
I think I have a few unmanaged dotfiles, but I tried to manage almost everything with Nix
<omasanori[m]>
jasom: cool, thanks for sharing!
<matthewcroughan_>
So you plan on only using systemd based distributions cole-h?
<cole-h>
Until something better comes along, I see no reason to change. There are upsides and downsides to everything, but I plan on sticking to NixOS for the foreseeable future (which also happens to be systemd-based for the foreseeable future)
<jasom>
omasanori[m]: there's no docs yet, but to get an idea of how it works, first do a ./runme in the checkout, try to quickload "cl+ssl" in slime (or sly if you prefer) then uncomment the "openssl.out" line, and run ./runme build_env when you get an error, then just do the "retry" restart in sldb
<matthewcroughan_>
But could you switch to arch with this setup or not cole-h?
<cole-h>
Well, I originally built most of my config on Arch
<qyliss>
oh wow yeah I forgot how recently you switched
<cole-h>
If you view the master branch, you'll see my config as of whenever I stopped using Arch
<jasom>
omasanori[m]: I used an nix environemnt rather than nix-shell because we are lispers damnit, we shouldn't have to restart our image just to add a new dependency; that's just uncivilized.
<matthewcroughan_>
I mean since you're using home-manager, can you actually switch to ubuntu, all your "dotfiles" managed inside of nix modules, over to your destination?
<cole-h>
Probably.
<matthewcroughan_>
I'm using Arch now, wanting to move directly over to Nix.
<matthewcroughan_>
New laptop won't even touch Xorg :D
<cole-h>
That's basically how I was back in... *checks repo* May.
<matthewcroughan_>
See? This is why you're: 1. A legend. 2. My Hero
<cole-h>
:P Happy to hear that I can be of use.
<cole-h>
s/use/help/
<matthewcroughan_>
Right, so your repo is pretty much all there is, regarding the "right" way of doing things haha
<cole-h>
"Right" is subjective, but it certainly fits my use case ;)
amfl_ has joined #nixos
<matthewcroughan_>
So what branch should I be looking at for your current config?
<cole-h>
The default branch, `nixus`
amfl has quit [Ping timeout: 246 seconds]
amfl_ is now known as amfl
<matthewcroughan_>
So, if I wanna boot your system now, how do I do that :)
<cole-h>
Read the README ;)
<matthewcroughan_>
No f'ing way.
<matthewcroughan_>
Too good.
<matthewcroughan_>
-o compression=zstd
<matthewcroughan_>
you might want to change that to zstd-fast-19 or
<cole-h>
(I didn't actually do that, because I switched before zstd compression was merged)
<cole-h>
Still on lz4 or whatever the default was
<omasanori[m]>
jasom: thanks for detailed info! sure, (lisper hat on) we should keep our environment running if possible.
<matthewcroughan_>
That's just the opening benchmark.
<cole-h>
Right. I'd be interested in seeing if anything changed, since there was a lot of time between open and merge :P
astronavt has quit [Quit: Leaving]
<matthewcroughan_>
Hmm. So I already have nixos installed, I just want to copy your nix configs.
<matthewcroughan_>
I don't really know how I could do that
<cole-h>
First steps would probably be removing references to `my.secrets.*`, since those files won't exist for you ;)
<matthewcroughan_>
Yeah, but that's for your user config
<matthewcroughan_>
I'd just rip vin out.
<cole-h>
I also have it in my system config
<matthewcroughan_>
I should be able to do that right? Just get rid of vin, and start fresh with matt
<cole-h>
Specifically in my libvirt and wireguard configs
<cole-h>
It's possible. I haven't tried, so I wouldn't know ;0
<matthewcroughan_>
System config is comprised of what exactly?
<cole-h>
hosts/<hostname>/*
<matthewcroughan_>
Everything outside of the users folder?
<matthewcroughan_>
Oh, okay.
<matthewcroughan_>
So what is everything in the root?
<matthewcroughan_>
iso.nix, flake.nix, extraneous files like that/
<cole-h>
my.nix creates `my.{secrets,drvs,scripts}`, so I don't have to type the path out everywhere
<cole-h>
overlay.nix is just my nixpkgs overlays that get applied
<cole-h>
flake.nix is the meat of my config, where I set the Nixpkgs config and overlays, do some flakes-related configuration, and configure nixus to deploy my system
<jasom>
omasanori[m]: and all of this talk about lorri inspired me; I just added a server you can run that will automatically rebuild the environment every time default.nix changes
<cole-h>
Happy to answer any specific questions you have beyond that
<matthewcroughan_>
My question really was, is that all lorri IS doing?
<matthewcroughan_>
Or is it doing some crazy stuff in the background that is more low level?
<jasom>
matthewcroughan_: I just glanced at it, but it looks like it runs in the background generating new shells in the ~/.cache/lorri directory and if your shell is out-of date when the prompt is printed, it puts you back in the shell (probably through direnv)
<jasom>
matthewcroughan_: note that they have to force a new prompt by hitting "enter" once after they add figlet in the demo
<matthewcroughan_>
cole-h: your config is definitely evolved
<matthewcroughan_>
Far too complex for me. I'm looking forward to reaching your level of understanding :)
<cole-h>
Uhhh, yeah, understanding...
<cole-h>
:P
<matthewcroughan_>
Fudgery
<matthewcroughan_>
Your level of fudge.
<cole-h>
Most of that knowledge was gained from asking questions here (mostly being answered by bqv)
<matthewcroughan_>
Welp, another apprentice has arrived.
<cole-h>
Soon to join the masters :)
<matthewcroughan_>
So that submodule for your secrets, is that a private repo?
<cole-h>
Yep
<matthewcroughan_>
but you're happy with your secrets being on a github private repo?
<cole-h>
The only stuff you would gain by having access to it, however, is metadata (file names, when it was last updated, etc)
<cole-h>
Because it's encrypted with git-crypt
<matthewcroughan_>
nice
<cole-h>
So I unlock it and it looks unencrypted on disk, but it's always encrypted to git
<matthewcroughan_>
so where do you pass the key to a nix function?
<matthewcroughan_>
oh, so you just unlock everything during install?
<cole-h>
via the hack I linked earlier, in `my.nix`
<colemickens>
the wiki has okayish docs on how to use nix cli with flakes too
<{^_^}>
[nixpkgs] @jtojnar pushed 13 commits to gnome-3.38: https://git.io/JTVOp
<matthewcroughan_>
Yes, that's good and all, but I want a bottom-up "here's how you should make your system work first time around", rather than just the pure concepts.
<{^_^}>
[nixpkgs] @r-burns opened pull request #101526 → bacula: fix build on darwin → https://git.io/JTVOj
<matthewcroughan_>
I have read that wiki, but it doesn't really help me understand how it fits into the ecosystem.
<matthewcroughan_>
> we don’t know what we’re actually running in production, so reproducing or fixing problems becomes much harder.
<{^_^}>
error: syntax error, unexpected $undefined, expecting ')', at (string):345:7
<matthewcroughan_>
Lol, so until now, we only ever knew we were on "latest", is that correct?
<matthewcroughan_>
Kind of like Arch? :p
<colemickens>
most of us were pinning via niv, or our own stuff, or the channel system is basically a form of pinning
<colemickens>
if you were on the nixos-unstable channel then you were on a form of "latest" depending on when `nix-channel --update` was last run.
<matthewcroughan_>
Yes, which just lead me when I joined a few hrs ago to a drv compile error
<simpson>
NixOS has had two releases per year for a while, and that cadence is used to stabilize versions of various system state (database versions, etc.)
<matthewcroughan_>
until I ran nix-channel --update
<colemickens>
Flakes mostly forces you to do the pinning at the place of usage (versus channels which was basically a pin, but stored somewhere n the system instead of in the config)
<{^_^}>
[nixpkgs] @buckley310 opened pull request #101529 → nixos-generate-config: Change how auto-generated swap files are detected → https://git.io/JTVCm
eoli3n has joined #nixos
<danderson>
another deep nix language question: what is _module? Is it a magic variable?
<danderson>
Trying to puzzle through how nixos configs get evaluated, and in particular how `pkgs` appears to end up magically defined _somewhere_, and there are references to _module that I'm not able to grok.
domogled has quit [Remote host closed the connection]
<danderson>
cole-h: thanks. Hopefully my brain can unwind this :)
<danderson>
still not seeing where the hell `pkgs` gets defined if I'm not passing in explicitly, even though empirically it does. Hopefully I find it soon :)
<MichaelRaskin>
That way both of us (and whoever else will want to join) can stream or not stream voice
<MichaelRaskin>
And the chat doesn't overlay the screenshare
<MichaelRaskin>
And we could decide to stream video feeds or not (and they are properly different notion from screenshare, yay)
<MichaelRaskin>
Anyone interested in Common Lisp with Nix is welcome to join, too — I do not expect too many, and it can handle NixCon Water-Cooler scale just fine
<siraben>
How do I disable QT's hooks when I add qmake as a build dependency?
<siraben>
It tries to run some qmake command but fails
<srhb>
ambro718: Note that you should no longer use the nixpkgs-channels repo since it's deprecated (though it's probably not the cause)
<ambro718>
srhb: what should I use as an alternative if I want to use git and maintain custom changes on top of a channel?
<srhb>
ambro718: nixpkgs itself
<srhb>
ambro718: It has all the corresponding channels that used to be in -channels
<ambro718>
srhb: which branches are these?
jabster28 has joined #nixos
<srhb>
ambro718: Same names, eg nixos-unstable, nixos-20.09 etc.
<ambro718>
ah I see, thanks
<{^_^}>
[nixpkgs] @kmein opened pull request #101536 → opustags: init at 1.3.0 → https://git.io/JTVoU
jakobrs has joined #nixos
ArtemVorotnikov[ has quit [Quit: Idle for 30+ days]
fjodor[m] has quit [Quit: Idle for 30+ days]
<stuebinm[m]>
is there a better way to ensure that a given directory will exist via nix than to just start a systemd service which checks if it already does and uses `mkdir` if it doesn't? (doesn't need to be anything in there, but without it a web service crashes — obviously i could just create it by hand, but i guess it'd be nice of there'd be some declarative way of doing the same)
<srhb>
stuebinm[m]: A common method in newer modules is systemd.tmpfiles
<srhb>
stuebinm[m]: Personally I'm undecided.
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
<srhb>
I think I like being nearer to the unit in question wherever possible to avoid out-of-sync issues.
<srhb>
stuebinm[m]: If possible, reusing systemd's own concepts of statedir etc.
<srhb>
stuebinm[m]: (Note that you can specify multiple for each class of directory, so you can probably find a good fit.)
whald has joined #nixos
sangoma has joined #nixos
rsynnest_ has quit [Quit: Connection closed for inactivity]
<srhb>
stuebinm[m]: (For instance, setting `StateDirectory = "foo,bar";` will ensure /var/lib/foo and /var/lib/bar are created when the service is started)
<jakobrs>
Or I could use linuxPackages.callPackage, but then I'd need to know what version of linuxPackages to use *in* the overlay, somehow
<whald>
i'm having trouble to get hydra to properly build some project that's using git-lfs (and is built using a flake, if that matters). the sources checked out by hydra have the git-lfs files missing.
<whald>
i assume that hydra does something like "nix flake clone 'git+ssh://git@some.gitlab.instance/foo/foo.git' --dest foo" to get the sources which, when run on my machine, *does* fetch the git lfs files, so not all hope is lost. but how can I convince hydra to do the same?
<srhb>
whald: I only barely remember this, but iirc git-lfs is an entirely out of band tool mostly unrelated to git, which just hooks into various git commands and causes execution of certain git-lfs commands.
<srhb>
whald: So I suppose you either have to do the lfs magic out of band (as a separate source? if that's possible) or teach nix about git-lfs
<whald>
srhb, from my experience, git in itself is, since a few releases, aware of git-lfs and will do *the right thing* if only git-lfs is found on the $PATH. that's probably why the "nix flake clone" command just works.
<srhb>
You may be right. I guess what I know really is out of date then. :)
<whald>
srhb, but iirc, on nixos, systemd services like hydra are isolated from environment.systemPackages, so adding it there does not help. i probably need a (patched?) nix which uses a git which can "see" git-lfs or maybe it's enough to inject it into what hydra sees somehow. hmm. only one way to find out, i guess... :-)
sangoma has joined #nixos
tom39291 has joined #nixos
inkbottle has joined #nixos
zebrag has quit [Ping timeout: 258 seconds]
jakobrs has quit [Quit: WeeChat 2.9]
<{^_^}>
[nixpkgs] @jtojnar opened pull request #101537 → gtk3: Use tracker3 for search → https://git.io/JTVi2
kaiha[m] has left #nixos ["User left"]
<{^_^}>
[nixpkgs] @xfix opened pull request #101538 → test-driver.py: remove bufsize=1 from Popen calls → https://git.io/JTVi6
<tom39291>
I don't use channels, and instead pin to particular nixpkgs commits. I upgraded a physical machine to recentish commit on branch release-20.09, and rebooted, but it fails to boot. It says "Loading GRUB", then doesn't GRUB, and seems to go straight to loading a GRUB entry, since it says "Booting the kernel." but the console doesn't update anymore. The only indicator I have of boot progress is the
<tom39291>
disk indicator on my machine blinks for about 30 seconds, before giving. I see neither stage1/stage2 output.
<tom39291>
Is my best bet to recover via USB and nixos-enter and nixos-rebuild, pointing at an old generation?
orivej has quit [Ping timeout: 256 seconds]
<symphorien[m]>
try maintaining shift during boot to make grub appear ?
is_null has joined #nixos
null29 has joined #nixos
sangoma has quit [Ping timeout: 256 seconds]
<null29>
Hi everyone. I'm trying to run `nixos-rebuild switch`, but I get `Died at /nix/store/w5s7s1nnzsmzdqh06abysffrj2m0nrwf-update-users-groups.pl line 20.` error (logs https://pastebin.com/2za7iJjF). Any ideas how to debug/fix the issue?
<tom39291>
symphorien[m]: Thanks for the suggestion. That didn't seem to catch it. I do recall the grub menu appearing for this machine, so either grub menu no longer displays on nixos 20.09, or my machine is messed in some way I don't understand. I'll try the recovery for now.
Soo_Slow has quit [Quit: Soo_Slow]
dbmikus has joined #nixos
dbmikus has quit [Ping timeout: 256 seconds]
<tom39291>
I recovered by mounting my boot partition, editing grub.cfg, and moving an old generation up to the top of the grub menu. It booted after that. Impure, but recovered. :) I'll try and figure out what went wrong.
<danderson>
does hydra not build non-free licensed derivations?
<danderson>
having installed virtualbox, my nixos-rebuilds all drag because I have to recompile virtualbox each time. I'm suspecting that it's because it's unfree and hydra doesn't compile it, but unsure.
<symphorien[m]>
No because licence may preclude reditristribution
<marble_visions>
hi all! running nixos 2003 with gnome3, on a laptop, wired ethernet. when i boot the machine, gnome starts spamming a connected/disconnected for the wired eth interface (the cable is connected). when i disable the iface from the gnome gui, the problem goes away until next reboot. seems like it's related to https://github.com/NixOS/nixpkgs/issues/72416
<{^_^}>
#72416 (by laikq, 51 weeks ago, closed): dhcpcd service mysteriously starting after NixOS 19.03 -> 19.09 update
<pinpox>
Hi, does anyone know how to create a shell.nix file to share with other developers that has zsh as shell?
<pinpox>
I know you can use --command on nix-shell, but I'd like to allow anyone to just run nix-shell with my shell.nix file and be all setup for development
<eeva>
pinpox: I don't have a solution for you, unfortunately. Two close things I can think of: 1) using direnv, by creating a .envrc containing `use nix` or 2) use lorri (and not nix-shell). Both of these are extra dependencies unfortunately, but direnv is pretty standard
maxdevjs has joined #nixos
<eeva>
Otherwise `nix-shell -c zsh` is the best one can do with zsh
<simpson>
Note that "other developers that has zsh" is not "anyone".
<pinpox>
eeva: ok, thanks for the hints. I'll look at both and see if it's worth the effort. I'm thinking about trying to convince a few co-workers to start using nix, while bash is probably fine I know they are both kinda zsh-fanboys so that would make it easier
<pinpox>
Was hoping for some directive to include in the shell.nix file that installs zsh and possible some plugins and set's it all up
<simpson>
Let folks bring their own shells and editors into the environment. What you'll want to provide for folks are the build commands for your package, not the tools for editing the package's source code.
<pinpox>
simpson: In this case it's mostly terraform, ansible and bit of other stuff. We've had problems because of different versions, so I thought a shell.nix for everyone would be nice
<eeva>
pinpox: shell.nix is very nice to bring the “good” versions of these tool in scope. I'm using this too
<pinpox>
eeva: Nice. I'm using it myself too and it works perfectly, my co-workers don't though.
<pinpox>
The setup process for the project is "theoretically" simple but in my experience always something is missing and it get's tedious.
<pinpox>
If I can shorten down the README to something like "just use this shell.nix - done." that'd be great
malook has joined #nixos
civodul has joined #nixos
null29 has quit [Remote host closed the connection]
<simpson>
pinpox: Understandable. Part of the direnv ethos is to make the choice of underlying shell less relevant; the same environment-preparation steps should work on any popular shell.
<tilpner>
pinpox: You should be able to define aliases in shellHook
<tilpner>
Does anyone recognise this error? "ld.lld: error: undefined symbol: std::__1::chrono::system_clock::now()"
<tilpner>
(Context: Rust crate tracing-tracy tries to build some C++)
<patagonicus>
Has anyone recently run into rendering issues with Chrome? I'm getting flickering (controls on Youtube in fullscreen, for example) and sometimes the whole window is rendered higher than it should be, but the interactive controls are where they should be, so lower than they are drawn. Might be some combination of Chrome, i3, X and/or intel GPU
<patagonicus>
drivers.
ddellacosta has joined #nixos
<{^_^}>
[nixpkgs] @moben opened pull request #101551 → ceph: Fix build with glibc 2.32 → https://git.io/JTVx8
werner291 has joined #nixos
<tom39291>
Figured out why my machine wasn't earlier. I was nix-copy-closure'ing the wrong nixos configuration (and wrong fileSystems."/boot" and fileSystems."/" :)
<tom39291>
wasn't booting earlier*
txt_file has joined #nixos
philr has quit [Ping timeout: 246 seconds]
<txt_file>
I installed nixos on a computer and it is running good.
<gchristensen>
neat
<txt_file>
Is there a way to allow users to install software via config file without elevated privileges? I've red it might be possible via ~/.nixpkgs/config but didn't not figure out how.
<gchristensen>
nix-env -iA nixpkgs.git
<infinisil>
Although it's nixos.git on NixOS
<gchristensen>
right ... :)
<txt_file>
"nix-env -iA nixos.git" installs git if I'm not mistaken.
<{^_^}>
[nixpkgs] @vbgl opened pull request #101552 → ocamlPackages.mirage-net: init at 3.0.1 → https://git.io/JTVp6
lordcirth has quit [Read error: Connection reset by peer]
lordcirth has joined #nixos
<siraben>
When building the remarkable-toolchain package, I end up with this in the result folder, http://ix.io/2BQf any indicators on how this can let me cross-compile?
dbmikus has joined #nixos
<siraben>
It might be that I need to add the reMarkable tablet as a cross-compilation target.
dbmikus has quit [Ping timeout: 256 seconds]
tsrt^ has quit [Read error: Connection reset by peer]
Chiliparrot has quit [Ping timeout: 260 seconds]
ilmu has joined #nixos
<Ke>
if I don't want to have updates restart containers. should I have systemd.services."container@".restartIfChanged = false or "container@name".restartIfChnaged ?
<Somelauw>
I'm trying to get qutebrowser 1.14, however nix -i qutebrowser installs version 0.9 If I search on search.nixos.org/packages?query=qutebrowser I see it should install version 1.14
<siraben>
infinisil: ah, that project is interesting too
<Somelauw>
ironically, I've managed to break qutebrowser. When trying to upgrade I get: error: the group 'nixbld' specified in 'build-users-group' does not exist
<Somelauw>
ironic, because nix was supposed to prevent your system from ending up in a broken state, whereas now nix itself ended up in a broken state
<siraben>
MichaelRaskin: Nah, my cache works fine. I remember seeing this interesting concept before but forgot it
<siraben>
Oops wrong reply
<MichaelRaskin>
Somelauw: the installer does some random automagic, and it is supposed that the build users will be created if they are needed in the mode of use that the installer automagically picks
werner291 has quit [Remote host closed the connection]
<MichaelRaskin>
So this is not in installation instructions… I guess unfortunately
<MichaelRaskin>
sudo $(which nix-instantiate) /home/laurent/.nix-defexpr/channels/nixpkgs -A hello
sangoma has quit [Ping timeout: 258 seconds]
<supersandro2000>
I have 3 nix files. The first defines a variable, the second does things based on that and the third consumes it. I tried various let .. in constructs with the following:
<MichaelRaskin>
(what I ask you to do is kind of workable Nix use, but only kind of; I just want to check whether the basics are actually working before trying to fix the next level)
<Somelauw>
MichaelRaskin: No idea what I'm doing, but it worked and it copied some paths
<matthewcroughan_>
So, with Nixos, are you supposed to enable/disable services with systemd?
<matthewcroughan_>
Or are you supposed to completely avoid manually setting systemd with nixOS
zupo has joined #nixos
<supersandro2000>
Can anyone recommend a good guide for nix that is not that lengthy and shows things in practical examples? Sometimes I have the feeling I have no clue what I am doing.
<matthewcroughan_>
Yeah I'm in the same boat supersandro2000 :)
<matthewcroughan_>
There's nothing that good that I've found, other than the official latest 20.03 manual.
<supersandro2000>
matthewcroughan_: I am more searching for things to better understand nix. I do most of my stuff with home-manager and normally I know what I want to do but the syntax is just wrong
<matthewcroughan_>
Well, I know that it's all just bash syntax, mostly..
Somelauw has quit [Quit: WeeChat 2.3]
<matthewcroughan_>
Yeah, I think a syntax lookup table would be good
<MichaelRaskin>
bqv: started
<bqv>
MichaelRaskin: <3
<matthewcroughan_>
bqv: You must know. Systemd manual intervention on nix? Yes or no? :P
<bqv>
thats a no
<neiluj>
so the root of the problem is this import in one of my nix files: inputs.home-manager.nixosModules."home-manager"
<bqv>
Enable/disable will likely not even work
<matthewcroughan_>
Oh really? let me try it hmm
<neiluj>
home-manager is defined as input in flake.nix
<matthewcroughan_>
systeWarning: Stopping docker.service, but it can still be activated by:
<matthewcroughan_>
Nope, seems to work bqv
<bqv>
That's stop, not disable
<matthewcroughan_>
ah, sorry
<matthewcroughan_>
Failed to disable unit: File /etc/systemd/system/docker.service: Read-only file system
<matthewcroughan_>
:D
<MichaelRaskin>
bqv: fortunately, I still have the cache from the morning\
<cole-h>
I disable sound because I use soundsense (plays music/sounds based on events from the game log) and it's annoying to turn down the default music on every launch
<cole-h>
and I enable FPS so I can see how slow stuff is going
<matthewcroughan_>
I mean can you explain exactly what that line does?
<cole-h>
It overrides the dwarf-fortress-full package to disable sound and enable the FPS counter
<matthewcroughan_>
enableSound is an environment variable you want to be set when you call `dwarf-fortress` right?
<matthewcroughan_>
or is it not an environment variable?
<cole-h>
no?
mananamenos has quit [Ping timeout: 260 seconds]
<matthewcroughan_>
Right, so what is enableSound, and where is it defined?
xd1le has quit [Read error: Connection reset by peer]
<cole-h>
This is `override`, which overrides top-level attrs, not `overrideAttrs`, which overrides attributes (or sets them) inside of the derivation
<bqv>
MichaelRaskin: apologies, I think I missed some off the list, are these availale too?: cl-cffi-gtk cl-webengine cl-webkit2 enchant trivial-main-thread
<cole-h>
neiluj: Your `outputs =` needs to look like `outputs = inputs:` or `outputs = { ... } @ inputs:`
<bqv>
(borg succeeded though)
<MichaelRaskin>
I have some bad feeling re: cl-webkit2 and cl-webengine
<cole-h>
neiluj: If you're trying to access the inputs in another file, this won't work unless you change the module args with `_module.args.inputs = inputs;` inside the flake.
<neiluj>
hum i looked well and did not found any reference to <nixpkgs>
<cole-h>
If you can't survive without this, you can do `--impure`, but this will bust the evaluation cache (so everything will have to be evaluated every time)
<cole-h>
If you paste the full error somewhere, maybe someone (or I) can help.
<mica[m]>
Can I just import a derv. that isn't in nixpkg yet?
<neiluj>
ok, so got my system generated :) with --impure because adding _module.args.pkgs = pkgs.lib.mkForce pkgs; yields a new 'infinite recursion encountered' error
<cole-h>
Not pkgs.lib, nixpkgs.lib
<neiluj>
mica[m]: do you mean using a custom package?
<cole-h>
nixpkgs is the nixpkgs input, which has a lib output which exposes the lib/ stuff from the Nixpkgs repo
<mica[m]>
neiluj: yes
<mica[m]>
I will submit it to nixpkg, but I want to use it now and it isn't packaged.
<neiluj>
mica[m]: you can do with an overlay, i give you an example
<MichaelRaskin>
bqv: I wonder how much of gtk libs cl-cffi-gtk needs
<mica[m]>
neiluj: yes please & thank you
<bqv>
MichaelRaskin: I'm sure I'll find out soon...
<{^_^}>
[nixpkgs] @7c6f434c opened pull request #101581 → lispPackages: more Nyxt deps → https://git.io/JTwRn
Chiliparrot has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
andybkof2001 has joined #nixos
<andybkof2001>
made your area like quebec and speak german, in the frontier méxico with texas,the flag is in the frontier, in horizont orange almost dark like brick in up, in half gray aluminum, and in down blue sky day, with letter L red shinning thick, no very thick just 1 cm and 4 mm with red fire in the right side in line like shadow the same red shinnig 9 mm right, at the left side 1 mm of shadow,
<andybkof2001>
and in down 3 mm of shadow red shinnig all the shadows stiked at the L the L no with waves in line 9 mm of fire 1 left and 3 in down , the L in the center of the new german flag occupying the entire gray strip with the shadow, the name is Deutcsh, coin deutsches. let the giants play baskectball with the browns.learn german https://app.memrise.com/course/920/5000-german-words-top-87/1/ copy
<andybkof2001>
the adress of the page, and paste somewhere, for read it later, go at the bookseller and ask for the diccionary english german and read it verbatim, https://www.youtube.com/watch?v=Y6DNjM4s-zw
<cole-h>
srhb:
<cole-h>
or gchristensen
andybkof2001 has quit [Remote host closed the connection]
<srhb>
cole-h: That was atypical :P
<cole-h>
Definitely... strange
<cole-h>
lol
<supersandro2000>
wrong channel
malook has quit [Remote host closed the connection]
<evanjs>
so, project with multiple sub-projects, all yarn -- is there anything that currently handles something like this in nixpkgs already?
<evanjs>
I wonder if it might _somehow_ make sense to add it to nodePackages... I do see some things in there that have git repos explicitly specified
* evanjs
tries adding to node-packages.json and running generate.sh
<{^_^}>
[nixpkgs] @Luflosi opened pull request #101582 → hdparm: name -> pname → https://git.io/JTw0f
<evanjs>
I get the feeling it's going to die either at the lerna or the vue-cli-service invocation again
<evanjs>
no it's getting done it seems. well, just patching "node_modules" at least lol
<cole-h>
pumpy: Not yet.
<evanjs>
derr well it's either expecting vue-cli-service to be in the PATH or something else provides it
xd1le has joined #nixos
ericsagnes has quit [Ping timeout: 272 seconds]
<evanjs>
I wonder if adding @vue/cli-service to nodePackages might help
<evanjs>
(side note: it is _not_ fun querying the "@" packages... they're more or less invisible from most mechanisms like `nix search` and even `nix-env -qaPA nixpkgs.nodePackages`, IIUC)
<evanjs>
or maybe @vue/cli can be used in the same way
<MichaelRaskin>
bqv: if you have working nyxt package, feel free to send the .nix file for ijntegration in lisp-packages.nix, or mention me on a PR
dbmikus has joined #nixos
<bqv>
MichaelRaskin: I've been getting pulled away from my attempt again and again, ill have one by later I'm sure
<evanjs>
Ah. Command vue build requires a global addon to be installed. Please run undefined @vue/cli-service-global and try again.
<evanjs>
Well then :P
<MichaelRaskin>
I mean, we had this 2-hour call this morning, and 2 hours were needed
<MichaelRaskin>
To unblock various basic infra stuff
<MichaelRaskin>
Hopefully now you should have an easier time
<m1cr0man>
Hey folks. What's the correct way to build a conditional around system.stateVersion? I need to guard a change in acme.nix against old releases.
xd1le has quit [Read error: Connection reset by peer]
gentauro has quit [Read error: Connection reset by peer]
<jdnixx-M1>
how come syslogd won't output basically any log messages on /var/log/messages?
gentauro has joined #nixos
<MichaelRaskin>
I guess, systemd and journald
<jdnixx-M1>
I enabled the nixos services option, default config, but since turning it on last night it's literally got like 10 lines of just the timestamp + "JNIXX -- MARK --"
xd1le has joined #nixos
dxtr has joined #nixos
<jdnixx-M1>
I thought the . argument in the default syslog.conf would mean all logs go to the messages file
<jdnixx-M1>
whoops *.*
<bqv>
MichaelRaskin: ugh, cl-enchant is still required too
<bqv>
I'm gonna patch it in manually for now
<matthewcroughan_>
cole-h: Alright, so, I've created users/matthew/modules/all-my-apps
<MichaelRaskin>
Wait, is it different from enchant
<matthewcroughan_>
what else do I need to do in order to rebuild and end up with a good home-manager setup?
<bqv>
Yes, apparently
<MichaelRaskin>
bqv: the package / QL system is enchant, and it is in lispPackages
<bqv>
Oh
<MichaelRaskin>
cl-enchant is not in QL
<bqv>
Oh I just haven't updated, mb
<MichaelRaskin>
Of course on Debian there is no namespacing so they have to call that cl-enchant
neiluj has quit [Remote host closed the connection]
<pumpy>
matthewcroughan_ i had configuration.nix install home manager. i got it working with a per-user install but i think systemwide makes more sense
<pumpy>
i also use a dynamic import that imports any .nix files in ./conf.d
<jdnixx-M1>
could anyone point me in the right direction for making my own new derivations. I'm new to it and a little while ago was trying to package up Klogg (fork of glogg) to maybe submit to nixpkgs, but was in wayyyy over my head & pretty much gave up for now
<jdnixx-M1>
but I just found a really stupid simple little plasma applet with a 6-line install script basically, think I could use that for practice
sss2 has joined #nixos
<cole-h>
matthewcroughan_: Ping me again in ~7 hours -- gtg work
<jdnixx-M1>
the only thing in it that has to change to be nix-specific is it copies an extra file to /etc/sudoers & chmod's it
<jdnixx-M1>
other than that I guess I should be good to just stick the git repo's contents in a .nix file and do something to handle that little bit, but I'm super confused on what all boilerplate is always/sometimes required for different types of derivations
<MichaelRaskin>
It's a stylistic preference, whether you prefer to write configs and keep them under a VCS, of if you want to write all choices in Nix syntax, and have a consistent set of configs generated for you
<matthewcroughan_>
e.g, this repo foregos dotfiles, in order to use home-manager, defines everything inside.
<matthewcroughan_>
can you produce dotfiles from this though? Should you want to share your dotfiles with people who do not use nixos?
<MichaelRaskin>
Sometimes there is a single option that controls a larger chunk of config that is usually tweaked as a whole
<MichaelRaskin>
Yes, this is intended to produce dotfiles
justanotheruser has quit [Ping timeout: 260 seconds]
<matthewcroughan_>
See, that's what I was worried about. I was worried that by using this, I have to make everything non-standard, unsharable and un-portable.
<matthewcroughan_>
So this is not true? I can only gain by using this feature?
<MichaelRaskin>
Well, your dotfiles are now symlinks into /nix/store
endformationage has joined #nixos
<matthewcroughan_>
Well, I can't tell you how annoyed I was when I found out I had to maintain my dotfiles in /etc/nixos/dotfiles :D
<matthewcroughan_>
MichaelRaskin: Okay, so when I use homemanager, does this mean my configuration.nix no longer includes `users.users.Username =` ?
<MichaelRaskin>
Why? user list is a system-wide thing
<neothefox>
So, I made changes to a module and it's is now in my local repo, but can I build it specifically withou making my poor 4 core Intel m3 compile firefox from upstream along with the rest of the system?
Chiliparrot has joined #nixos
<matthewcroughan_>
what about environment.systemPackages? MichaelRaskin
<MichaelRaskin>
Home manager manages what user can write freely
<bqv>
MichaelRaskin: am I missing something? Is ASDF::USER/FSET a package separate to asdf somehow?
ATuin has quit [Ping timeout: 258 seconds]
<MichaelRaskin>
The name looks like just not a package
<bqv>
It seems to be lacking, one way or another
<MichaelRaskin>
Not sure what exactly is lacking there
ilmu has quit [Ping timeout: 260 seconds]
<bqv>
specifically, the error i'm looking at is thus:
<bqv>
lisp-nyxt-f744af52> Unhandled ASDF/FIND-COMPONENT:MISSING-DEPENDENCY in thread #<SB-THREAD:THREAD "main thread" RUNNING
<bqv>
lisp-nyxt-f744af52> {10008B80D3}>:
<bqv>
lisp-nyxt-f744af52> Component ASDF/USER::FSET not found, required by #<SYSTEM "nyxt/keymap">
<MichaelRaskin>
Yeah, none of the ASDFs seem to contain a mention of fset
<MichaelRaskin>
Cluffer looks fine when transplanted into lisp-packages.nix
<bqv>
fab
<bqv>
MichaelRaskin: i'm not sure that derivation would run correctly, fwiw, because my local nyxt build has a few other things, i was just testing the lisp part
cjpbirkb1 has joined #nixos
<MichaelRaskin>
I mean, that's Robert, I wouldn't expect his cluffer to bring any surprises
<MichaelRaskin>
Some version of nyxt.asd compilation succeeds…
zupo has quit [Client Quit]
<bqv>
hooray. that's something
BoxWithAHat has joined #nixos
<BoxWithAHat>
Hello. Anyone currently online?
cjpbirkbeck has joined #nixos
<MichaelRaskin>
bqv:
<bqv>
github says you committed that "in 4 minutes"
<bqv>
interesting
<bqv>
BoxWithAHat: many!
<MichaelRaskin>
it doesn't compile the binary, though
<MichaelRaskin>
It is a position I hold for many years, that my laptop clock should be ahead by 7 minutes
<bqv>
that should be fine, because now the wrapper derivation can call asdf:make
<BoxWithAHat>
I'm considering getting NixOS. How is it different from, say, GoboLinux?
cjpbirkb1 has quit [Ping timeout: 240 seconds]
<MichaelRaskin>
Any system that breaks due to interaction with a 7 minutes off clock should be broken
<bqv>
curious. I like it
<MichaelRaskin>
I think Gobo has less granularity
<astronavt>
ah :( its a shame that a newer application still isnt using xdg home dirs
<BoxWithAHat>
granuwhat?
dbmikus has quit [Ping timeout: 260 seconds]
<BoxWithAHat>
I'm kind of new-ish to Linux
<MichaelRaskin>
My motivation is not really to stress-test systems against clock asynchronicity, but for Reasons I prefer that clock to be a bit ahead
<BoxWithAHat>
I've only ever really used two desktop distros
<BoxWithAHat>
Mint and Raspbian
<MichaelRaskin>
Well, in Nix you can have available two copies of the same application, but built against different dependencies
<MichaelRaskin>
I think Gobo goes by name and version only
<MichaelRaskin>
I might be wrong about Gobo, though
<BoxWithAHat>
I'm still a bit confused
knupfer1 has joined #nixos
<MichaelRaskin>
Frankly, if you do not have confidence in terms of generic Linux things, you might suffer a bit too much from Nix* learning curve
knupfer1 has quit [Client Quit]
<BoxWithAHat>
Shame
<chpatrick>
BoxWithAHat: nixos is kind of alien because every package is installed in a separate immutable store and then linked together to get the system you actually run
bvdw has joined #nixos
<chpatrick>
which is great because if this re-linking is really cheap so if you mess something up you can just go back to an earlier one
<BoxWithAHat>
I'm lost again...
<MichaelRaskin>
Well, Gobo also does the first half
<chpatrick>
on normal distros you have a big filesystem and every time you install something the new package gets copied over whatever is there
<chpatrick>
but you can't really undo it
<BoxWithAHat>
Yeah
<chpatrick>
and if you make a mistake you might be in trouble
<BoxWithAHat>
I'm just wondering where the learning curve part comes in
<BoxWithAHat>
It sounds simple to me
<chpatrick>
BoxWithAHat: it's just that on top of the normal linux stuff you might have to learn there's also the weird nix stuff :P
<MichaelRaskin>
BoxWithAHat: from understanding the hundreds of small things where people assume FHS
<BoxWithAHat>
FHS?
<chpatrick>
which you can sometimes only get on IRC or reading the source
<MichaelRaskin>
Standard layout of everything in the system
justanotheruser has joined #nixos
<exarkun>
If you're just trying to use NixOS and pre-packaged NixOS software then I don't think NixOS is any harder than your average Linux distro to learn.
<MichaelRaskin>
Well, and there are thing that you are expected to learn from reference manuals
<exarkun>
All Linux distros are bizarre and quirky, they're just mostly bizarre and quirky in a different way than NixOS is.
tilpner has joined #nixos
<bqv>
it stands for Filesystem Heirarchy Standard, btw
<BoxWithAHat>
Oh, that makes sense
<BoxWithAHat>
Well, I don't really have time for manuals, I just want to computer
<MichaelRaskin>
exarkun: make a step to the side, hit a gotcha, and suddenly we ask for a ton of context in the terms mostly used by experienced sysadmins, though
<BoxWithAHat>
i did an bad englishes
<bqv>
BoxWithAHat: it's likely you'd suffer with nixos, then
<exarkun>
MichaelRaskin: I gave my caveat.
<BoxWithAHat>
I'm just wanting to try out unique operating systems
<BoxWithAHat>
Since I have some unused SD cards
<MichaelRaskin>
Well, uniqueness almost always imlplies relearning
<exarkun>
BoxWithAHat: So you're going looking for trouble but you don't want any trouble?
<exarkun>
good luck with that
<BoxWithAHat>
Nix seems like it'd be better as an OS to "settle down" with (sorry for the weird terms). It sounds like it's very stable for its learning curve.
<chpatrick>
BoxWithAHat: lots of manuals though
<BoxWithAHat>
Right
<chpatrick>
but once you learn it it really keeps working
<BoxWithAHat>
Which is outweighed by the fact that, being stable as it is, you don't really feel the need to move on to different operating systems
<BoxWithAHat>
Whoops
<BoxWithAHat>
I was trying to newline
<chpatrick>
I went slackware -> linux from scratch -> gentoo -> arch -> nixos
<chpatrick>
and I'm pretty happy
growpotk- has joined #nixos
<BoxWithAHat>
I pretty much went to Mint and stuck with it for good
<BoxWithAHat>
And I use Raspbian on my Pi
<MichaelRaskin>
BoxWithAHat: if you want basic appliance-level stuff from your OS, Debian or Ubuintu will serve you well in almost-default configration
<BoxWithAHat>
Also, LFS, Gentoo, *and* Arch? There's some bragging rights
<BoxWithAHat>
Oh, I know that, hence Mint
<bqv>
MichaelRaskin: looks like asdf reached the final stage, so yeah, no more deps
<BoxWithAHat>
I tried Ubuntu before, but I preferred Mint
<bqv>
thanks!
<bqv>
now it's just getting the build to work completely...
<MichaelRaskin>
Gonna merge once eval-check is done, even though it's all cargoculting
<bqv>
heh
<MichaelRaskin>
In the sense that I know these changes _should not be able_ to break anything given the kind of changes and the kind of local testing
<MichaelRaskin>
But should not be able to break anything sounds like famous last words
<MichaelRaskin>
I wonder if it is actually feasible to build Nyxt as a pure wrapper starting from what I merged and not touching the lispPackages.nyxt but using it as a library
<MichaelRaskin>
(depends on what exactly their application build does)
__monty__ has quit [Quit: leaving]
<bqv>
that's what i'm attempting. it is, i think, but asdf:make wants to put the result in the lispPackages.nyxt path
<MichaelRaskin>
Obviously, it is fine to build some binary in a Lisp package.
<MichaelRaskin>
I blatantly abuse my position to keep a query-fs package that only I use (and I am the upstream), and it builds a binary
<bqv>
nyxt-gtk> ; wrote /build/.temp-nixbld-home/.cache/common-lisp/sbcl-2.0.8.nixos-linux-x64/nix/store/pshkhgw87f81szb75wmh2xc6xkxqyr3s-lisp-nyxt-2020-10-23/lib/common-lisp/nyxt/source/renderer-gtk-tmpUWBX3JKB.fasl
<bqv>
nyxt-gtk> ; compilation finished in 0:00:00.266
<matthewcroughan_>
yes, I am not complaining. I just am asking if something I desire exists :)
werner291 has quit [Remote host closed the connection]
<bqv>
it doesn't, but probably should
<matthewcroughan_>
bqv: Well, what does it do?
<bqv>
to soften the learning curve
<matthewcroughan_>
What does the first line in configuration.nix, as generated by nixos-install, do?
naivettes has joined #nixos
<bqv>
matthewcroughan_: do you understand what a lambda, or function, is?
<matthewcroughan_>
Roughly, so what is it doing?
<matthewcroughan_>
{ config, pkgs, ... }:
<bqv>
that.
orbekk has joined #nixos
<matthewcroughan_>
> { config, pkgs, ... }:
<{^_^}>
error: syntax error, unexpected ')', at (string):346:1
<naivettes>
Hello! Beginner here. I'd like to add support for add-ons to the tome4 game. Add-ons are meant to be downloaded to into a directory within the game, but it's in the nix store. https://github.com/NixOS/nixpkgs/tree/master/pkgs/games/tome4Could anyone recommend a good example of how this might be done?
<bqv>
what programming languages are you familiar with?
<MichaelRaskin>
It _starts_ defining a function
<matthewcroughan_>
Python, Bash.
<Raito_Bezarius>
did anyone tried nixops with flakes?
<bqv>
let me translate that into python
<Raito_Bezarius>
seems like there is a --flake stuff
<MichaelRaskin>
This first line is argument list
<bqv>
{ config, pkgs, ...}: is equivalent to defun unnamed(config, pkgs, **kwargs):
<matthewcroughan_>
I'm not so familiar with python that I understand that, to be honest.
<bqv>
sorry, s/defun/def
<matthewcroughan_>
You still haven't told me what the first line of configuration.nix that everyone starts out with does :P
<bqv>
i've been fiddling with a lot of lisp today...
<matthewcroughan_>
I get it
<Raito_Bezarius>
matthewcroughan_: it just creates a function
<bqv>
matthewcroughan_: i get the feeling you're intentionally being belligirent here
<Raito_Bezarius>
if the question is more like: what is the purpose?
<Raito_Bezarius>
then, the answer is: a configuration.nix abstract over the pkgs and the configuration you give it
<bqv>
i'm not going to answer any more questions, ask someone else
<Raito_Bezarius>
the reason why you want to have a function is that your configuration depends on a certain set of packages and you could just replace the pkgs by another set which implements what you want
<matthewcroughan_>
If I remove it, how am I breaking it?
<matthewcroughan_>
What am I removing.
<Raito_Bezarius>
if you remove it, the nixos-rebuild will try to call the function
<Raito_Bezarius>
but there won't be any function
<Raito_Bezarius>
so it will fail
<matthewcroughan_>
The function is defined inside of {} ?
<Raito_Bezarius>
no
<Raito_Bezarius>
more like
<Raito_Bezarius>
{ x, y, z}: value
<ehmry>
well in some cases you can remove that line but then you will have free variables in the file
<Raito_Bezarius>
x, y, z are the arguments of the function
<Raito_Bezarius>
value is the return value
<matthewcroughan_>
So, in my case: `{ config, pkgs, ... }:`
<matthewcroughan_>
what is ... btw?
<Raito_Bezarius>
it's basically a variadic marker
<Raito_Bezarius>
it means : I accept any argument
<Raito_Bezarius>
so that if I call you with config, pkgs and foo
<Raito_Bezarius>
you won't fail
<matthewcroughan_>
So I'm still so incredibly confused what happens and why it's there at the top of the file :D
<multun>
matthewcroughan_: are you familliar with lambda functions ?
<matthewcroughan_>
no.
<Raito_Bezarius>
I think you might be confused with the NixOS model matthewcroughan_
<Raito_Bezarius>
But assuming you ignore the first line
<Raito_Bezarius>
Do you understand the rest?
<matthewcroughan_>
Pretty much yes
<Raito_Bezarius>
So, for example
<Raito_Bezarius>
You're using a NixOS at a certain version
Darkmatter66 has quit [Ping timeout: 260 seconds]
<Raito_Bezarius>
If you do update, you realize that the pkgs variable will have to change, right?
<matthewcroughan_>
system.stateVersion = "20.03";
<Raito_Bezarius>
That's not the NixOS version
<Raito_Bezarius>
That's the state version
<Raito_Bezarius>
It's something else
naivettes has quit [Remote host closed the connection]
Darkmatter66 has joined #nixos
<matthewcroughan_>
Well that's certainly not intuitive :P
<Raito_Bezarius>
The NixOS version is handled outside of the configuration.nix
<Raito_Bezarius>
matthewcroughan_: it would be called version otherwise :p
<multun>
a lambda function is a function without a name. myfunc = lambda a: 42 does just like def myfunc(a): return 42
<multun>
in nix, it would be { a }: 42
<matthewcroughan_>
the pkgsvariable has to change?
<matthewcroughan_>
where can I read the variable pkgs?
<Raito_Bezarius>
If you do an update, then yes
<matthewcroughan_>
pkgs is defined inside this file, no?
<Raito_Bezarius>
It's a complicated thing for a beginner :p but basically there is something called nix-channel
<multun>
matthewcroughan_: nix isn't an intuitive language if you have an imperative language background
<Raito_Bezarius>
Do you see pkgs = xxx somewhere?
<Raito_Bezarius>
If you don't, then pkgs is not defined there
<matthewcroughan_>
No, there is no definition inside my configuration.nix that defines pkgs =
<Raito_Bezarius>
So, pkgs is not defined in your configuration.nix
<matthewcroughan_>
so why's it there?
<Raito_Bezarius>
it's not there
<matthewcroughan_>
did I copy and paste something? Probably :D
<Raito_Bezarius>
and it won't be there
<matthewcroughan_>
`{ config, pkgs, ... }:` exists as the first line of my file
<evanjs>
is there any way to run node-packages' generate.sh for only the packages added in my WIP branch?
<evanjs>
or single packages, idc
<matthewcroughan_>
it is there, maybe not when it is evaluated, but should I get rid of it? Can I get rid of it?
<Raito_Bezarius>
You cannot get rid of it
<{^_^}>
[nixpkgs] @NeoTheFox opened pull request #101604 → implement fscrypt for PAM → https://git.io/JTwid
<matthewcroughan_>
How do I determine whether I can get rid of it?
<evanjs>
It's just not fun running it and waiting 15mins for it to fail because of another missing dep, etc
<multun>
matthewcroughan_: the content of the file isn't a program, it's a function
growpotk- has joined #nixos
<matthewcroughan_>
My configuration.nix contains `{ config, pkgs, ... }:`
<Raito_Bezarius>
The rules says that configuration.nix is a function eating config, pkgs and maybe other arguments and outputting a NixOS configuration
jumper149 has quit [Ping timeout: 246 seconds]
<multun>
it's a function that takes config and pkgs as an argument
<Raito_Bezarius>
So you cannot get rid of it
<matthewcroughan_>
we have determined that `pkgs` is not defined in configuration.nix
<Raito_Bezarius>
Yes, it's not
<multun>
indeed
<matthewcroughan_>
`{ config, ... }:`
<matthewcroughan_>
why can I not replace it with this?
<Raito_Bezarius>
Because you wrote pkgs after :
<Raito_Bezarius>
at some point
<multun>
you absolutely can
<Raito_Bezarius>
for example, environment.systemPackages = with pkgs; [ vim wget ];
<multun>
which you probably wanna do, if you need packages
<matthewcroughan_>
environment.systemPackages = with pkgs; [
<Raito_Bezarius>
that's it, matthewcroughan_
<Raito_Bezarius>
you understand why pkgs must remain in the list of arguments?
<matthewcroughan_>
because I'm later defining pkgs.something?
<Raito_Bezarius>
you're not defining
<Raito_Bezarius>
you're referring
<multun>
you're using
<multun>
pkgs.a is like pkgs["a"] in python
jumper149 has joined #nixos
<matthewcroughan_>
so the point of the first line of the default configuration.nix `{ config, pkgs, ... }:` is to allow me to choose from this list of arguments?
<Raito_Bezarius>
matthewcroughan_: I suggest you to do the full tutorial here: https://nixcloud.io/tour/
<Raito_Bezarius>
it'll help you
<Raito_Bezarius>
well
<Raito_Bezarius>
the "allowing you to choose" is a consequence
<matthewcroughan_>
so why can't I just have { ... }:
<evanjs>
mmmm.... love how generate.sh leaves the node-packages folder in a bad state if it fails to resolve a dep in node-package.json :P
<evanjs>
node-packages.json*
<Raito_Bezarius>
if you do use { ... }: it will bind no argument in your scope
<evanjs>
it deletes node-env.nix so you have to checkout again :P
<Raito_Bezarius>
I think you need to check out what means (lexical) scopes in programming languages and what are closures
<multun>
matthewcroughan_: if you have { ... }:, nix will have no idea what you're talking about when using the variable "pkgs"
<matthewcroughan_>
Wow that nix tour :O
<matthewcroughan_>
just like the golang tour
dbmikus has quit [Ping timeout: 240 seconds]
<matthewcroughan_>
multun: so where do I go if I want to "search" higher with my eyeballs?
<matthewcroughan_>
how do I see what nix sees when it sees pkgs defined in my file { pkgs }
<matthewcroughan_>
how do I see what's in pkgs?
<multun>
oh yeah right
<matthewcroughan_>
how do I see what's in ... or in config?
<multun>
well you can use the shell for that
<multun>
I mean the repl
<matthewcroughan_>
so that's all coming from channels right?
<multun>
yup
<matthewcroughan_>
"pkgs" and "config" get their contents from channels?
<Raito_Bezarius>
matthewcroughan_: nix repl
<Raito_Bezarius>
:l <nixpkgs>
<multun>
pkgs does, config is something else
<Raito_Bezarius>
then you can do pkgs.xxx
<Raito_Bezarius>
to see the contents
<matthewcroughan_>
so how do I determine the TYPE of what the things I put in { } are?
<Raito_Bezarius>
but warning, evaluating the pkgs attrset is not a very good idea
<Raito_Bezarius>
there are no types in NixOS matthewcroughan_
<Raito_Bezarius>
well
<Raito_Bezarius>
there are, but those are dynamic
<matthewcroughan_>
things are different from eachother
<Raito_Bezarius>
pkgs is an attrset
<Raito_Bezarius>
config is an attrset too
<multun>
run "nix repl", then type "pkgs = import <nixpkgs> {}"
<matthewcroughan_>
ok, how do I know whether I can look inside?
<Raito_Bezarius>
if you want to know the full contents of an args
<Raito_Bezarius>
{ ... }@args: args
<Raito_Bezarius>
that will print you everything that gets passed
<Raito_Bezarius>
those kind of things can be learnt in the Nix tour and in the docs, also, https://github.com/tazjin/nix-1p is relevant
<matthewcroughan_>
multun: empty response
<multun>
indeed
<Raito_Bezarius>
matthewcroughan_: then do "pkgs"
<matthewcroughan_>
{ AAAAAASomeThingsFailToEvaluate = «error: Please be informed that this pseudo-package is not the only part of
<matthewcroughan_>
lol
<Raito_Bezarius>
normal, you cannot evaluate the whole pkgs
<multun>
pkgs is a variable with all the packages nix can evaluate
<multun>
nix is a lazy language
<Raito_Bezarius>
you should try pkgs.vim for example
<multun>
matthewcroughan_: nix is a functionnal language
jabster28 has quit [Ping timeout: 265 seconds]
<multun>
there's no such thing as ;
<evanjs>
16.0.0-beta.5 -- I wonder if beta versions and etc are killing it
<multun>
your whole program is a single value you evaluate
<Raito_Bezarius>
multun: in your file, though yes, but in the repl, no
<multun>
yeah right x3
<multun>
the repl is kinda special
<Raito_Bezarius>
it's more imperative-like
<multun>
matthewcroughan_: If you wanna learn more about functional languages, I'd suggest checking out ocaml https://ocaml.org/learn/tutorials/
<matthewcroughan_>
Well, I actually don't ;)
<multun>
gee
<matthewcroughan_>
I just want to learn Nix. Then maybe I'll care.
<matthewcroughan_>
nix1p does it for me. Thank you Raito_Bezarius
<multun>
you'll have a hard time learning a functionnal language if you don't give a shit
<matthewcroughan_>
I do give a shit. Just not about genericism.
<matthewcroughan_>
I want to learn this to accomplish something. Setting up my new laptop.
<Raito_Bezarius>
Well, when the time comes, you will cross the bridge, hopefully :)
<matthewcroughan_>
One does not learn by staring at a page of definitions.
<matthewcroughan_>
One learns by doing.
<MichaelRaskin>
es one does
<matthewcroughan_>
At least I do..
<Raito_Bezarius>
Understanding how works fixed point mechanisms will require a bit of lurking into functional languages
<multun>
alright
<matthewcroughan_>
> purely functional. It has no concept of sequential steps being executed, any dependency between operations is established by depending on data from previous operations.
<{^_^}>
error: syntax error, unexpected ',', expecting ')', at (string):345:72
<multun>
Raito_Bezarius: that's probably not needed
<matthewcroughan_>
So, does this mean that there is no concept of "Do X, store X's out put in memory, then do Y, using some value that X put in memory" ?
<matthewcroughan_>
Or have I missed the point?
<Raito_Bezarius>
multun: well, when I'm chasing about why is it doing infinite iteration :D…
<multun>
matthewcroughan_: that's right, it's why you can have a variable containing all packages. as long as you don't need any, none will be built
<Raito_Bezarius>
matthewcroughan_: if you accustomed to mathematics, it means that everything boils down to a giant big compositions of functions
<Raito_Bezarius>
with some initial values
<Raito_Bezarius>
+are
thelounge8127 has joined #nixos
<multun>
matthewcroughan_: every value is defined as a function of some other stuff. this way, you can delay the computation until you need it
<matthewcroughan_>
So nix decreases my cpu usage? :Pp
<multun>
ahah
<multun>
if only
<matthewcroughan_>
If everything was functional, would that be the case?
<multun>
I don't think so
<Raito_Bezarius>
Well, functional improves a lot of things and performance research under functional programs is actually a thing
<multun>
you can achieve the same with both functional an imperative languages
<Raito_Bezarius>
But it's not a silver bullet
Rusty1 has joined #nixos
<matthewcroughan_>
So if we can achieve it with imperative, why not? Imperative seems easier to understand.
<matthewcroughan_>
i.e Dockerfile and OCI format
<multun>
matthewcroughan_: if you tried to get a dictionnary with all packages you can get inside with an imperative language, you would need a lot more cpu usage
<Raito_Bezarius>
matthewcroughan_: functional has saner properties other than performance
<multun>
with functions, you can apply changes to your code more easily, compose it
<matthewcroughan_>
there is no `{ powerManagement }` at the top of the file
<matthewcroughan_>
how is `powerManagement` getting resolved?
<multun>
heheh
<matthewcroughan_>
from `...` ?
<multun>
nop !
<bqv>
MichaelRaskin: it may even be more sensible to keep it as this, and not have a stray binary in the default lispPackages variant
<multun>
it's not a variable being read from
<Raito_Bezarius>
matthewcroughan_: it's not a variable
<bqv>
this being that overrideAttrs
<multun>
matthewcroughan_: in nix, you can make dictionnaries like that: { a = b; c = d; }
la-jesystani has joined #nixos
<MichaelRaskin>
Nah, I think having a binary there makes sense
<multun>
matthewcroughan_: { a.b = c; } is a shortcut for { a = { b = c; }; }
<MichaelRaskin>
Although maybe I can fix the path-patching
<matthewcroughan_>
So then config, lib, pkgs or modulesPath. One of those contains `powerManagement.cpuFreqGovernor` ?
<Raito_Bezarius>
No
<bqv>
feel free
<Raito_Bezarius>
It's not a variable matthewcroughan_
<Raito_Bezarius>
It's a declaration if you prefer
<la-jesystani>
howdy, im trying to convert some of my files to use flakes, and i have one that uses fetchFromGithub to grab vim plugins, that is passed to pkgs.vimUtils.buildVimPlugin, will i need to convert these to be flake inputs?
<matthewcroughan_>
I know that powerManagement.cpuFreqGovernor is not a variable.
<matthewcroughan_>
But where does it come from?
<matthewcroughan_>
What allows me to make the declaration?
<bqv>
la-jesystani: no
<multun>
matthewcroughan_: powerManagement.cpuFreqGoernor is a value in a configuration dictionnary
<multun>
you can add anything you like in that dictionnary
hmpffff has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<matthewcroughan_>
Well I don't see any dictionaries :D
<multun>
at the top of the file, the dictionnnary starts
<multun>
you should see an opening { on its own line
<matthewcroughan_>
Right, so everything inside of my {} is a dictionary?
<multun>
yes
<matthewcroughan_>
The whole file is effectively this though..
<multun>
the code inside your configuration is a function that takes external configuration, the package set (pkgs), and returns a dictionnary of configuration
<multun>
matthewcroughan_: nix is a programming language like others, but it's used to build operating systems. learning nix isn't that hard, but learning both nix and how it's used to build you os is harder
<{^_^}>
[nixpkgs] @WolfangAukang opened pull request #101607 → signumone-ks: init at 3.1.2 → https://git.io/JTwXA
<multun>
matthewcroughan_: it would be a bit like learning python reading django code, there's a lot abstracted away
<multun>
matthewcroughan_: just like django created abstractions for models using python, nixos's module system creates abstraction over configuration using nix
<multun>
matthewcroughan_: that's why you're having a hard time understanding this stuff, you're reading framework code
<matthewcroughan_>
If I am writing a configuration.nix file, I need to understand every line in it.
<matthewcroughan_>
Otherwise, I'm just copying other people's configs and I might as well use an imperative distribution.
<matthewcroughan_>
I need to have a reasonable, non academic understanding of this.
<matthewcroughan_>
You have thus far academacised it with numbers and irrelevant abstraction.
<matthewcroughan_>
I do not want to learn the language academically. I want to learn it practically.
fendor_ has quit [Remote host closed the connection]
<matthewcroughan_>
I'm going through the tour and leaving you alone now, but I want you to be aware that this is why kids fail math :)
alp has quit [Ping timeout: 272 seconds]
<Raito_Bezarius>
kids do not fail math because they start with type theory I believe
<Raito_Bezarius>
there a lot of resources out there, we provided you with pointers and explained you in different ways stuff
<multun>
you can't both want to understand everything before starting, and want to learn it practicaly
<Raito_Bezarius>
nix has some kind of requirements, it's not your super beginner OS, especially if you want to know everything on the first time without knowing a bit on functional language
<multun>
you'll have to pick a side
Neo-- has joined #nixos
<bqv>
matthewcroughan_: i understand your drive to understand the details, but just as with learning the grammatical system of a natural language, most of these things are utterly meaningless without context, which is why structured learning is required
andymandias has joined #nixos
andymandias_ has quit [Ping timeout: 272 seconds]
<matthewcroughan_>
Kids fail math because they don't feel a drive to learn, because they feel it's useless.
<matthewcroughan_>
If you told a kid "You can use trigonometry.. TO 3d print an amazing thing that lets you do something"
<matthewcroughan_>
yeah, maybe they'd listen.
<matthewcroughan_>
Similarly, if you gave me examples that included packages instead of numbers, I'd understand.
<multun>
matthewcroughan_: nixos isn't yet in a state where it's easily understandable. kids better stay away for now
<bqv>
then i would counter with the fact that knowing the exact meaning of `{ config, pkgs, ... }:` will be absolutely useless to you with regards to doing anything to your system configuration
<matthewcroughan_>
I don't know what 42 represents.
<bqv>
it's not practical knowledge, it's a context-sensitive detail
<matthewcroughan_>
I know what dwarf-fortress-packages.dwarf-fortress-full.override represents
<matthewcroughan_>
you're trying to tell me 42 instead of dwarf-fortress-packages.dwarf-fortress-full.override
<{^_^}>
[nixpkgs] @zowoq opened pull request #101608 → qemu: use shared libslirp → https://git.io/JTw1B
<matthewcroughan_>
therefore it's not making sense, at any stage
<matthewcroughan_>
it's too arbitrary
<samueldr>
I'll say that I missed the start of the discussion, but when I got involved, it looked like you wanted to know _how_ things worked, and not how to achieve a specific result
<samueldr>
so that coloured my explanations
<multun>
you asked for the internals, you got it
<matthewcroughan_>
I wanted to know, more or less, when/why you would add or change something in your configuration.nix's opening lambda.
<MichaelRaskin>
Well, a person who wants to know what every line does, _and_ only understands «what does» in imperative terms
<matthewcroughan_>
I didn't want the internals. I just wanted to know why it was there.
<matthewcroughan_>
Rather than blindly assume I never need to modify it
<MichaelRaskin>
But why _is_ internals
<samueldr>
right, the arguments from the set-pattern functions can all be removed until needed; most likely `lib` and `pkgs` are the ones you'll need at first
<MichaelRaskin>
The header is like that so that it matches the expectations of what calls it
<matthewcroughan_>
You know. When I understand this a bit more clearly, I'm sure I won't be explaining it like this :P
<samueldr>
`config` is needed when you want to start affecting results in an expression depending on other configurations
<samueldr>
the `...` I don't think is needed to be explained; but yeah, removing it will break the eval :)
<multun>
matthewcroughan_: have you even taught in a class ? you'd be surprised to see how hard that is
<matthewcroughan_>
I've taught kids how to use the command line in a matter of hours.
<matthewcroughan_>
Because they found it fun to send files to eachother's IP addresses using scp.
<multun>
indeed
<multun>
I've taught kids how to make games in python in a week
<matthewcroughan_>
What isn't fun is being told 42 represents a package, keep it in mind and follow along with my impossible to follow along with explanation on functional languages.
<matthewcroughan_>
or 42 represents something arbitrary that you're not sure of, because the explainer is not putting packages or anything practical in place of numbers in their explanation.
<bqv>
matthewcroughan_: it might help you more to play around in the nix repl for a bit
<bqv>
that way you'll get a feel for the language, and can explore nixpkgs a bit, interactively
<matthewcroughan_>
> This line makes the current Nix expression a function. The variable pkgs contains Nixpkgs, while config contains the full system configuration. This line can be omitted if there is no reference to pkgs and config inside the module.
<{^_^}>
error: syntax error, unexpected ',', expecting ')', at (string):345:90
<MichaelRaskin>
Not even always hard, but has some amount of playing abstract board games first
<bqv>
matthewcroughan_: when you're getting familiar with a large new codebase, how do you normally do it?
<matthewcroughan_>
Earlier, you were telling me this is not a variable.
<matthewcroughan_>
Yet the manual states explicitly that this is a variable.
<matthewcroughan_>
My intuition told me this was a variable.
<matthewcroughan_>
I kept asking about it as if it was a variable. The manual agrees. You disagree?
<bqv>
variable is the incorrect term
<bqv>
because it literally doesn't vary
<matthewcroughan_>
> The variable pkgs contains Nixpkgs
<{^_^}>
undefined variable 'The' at (string):345:1
<bqv>
this is a functional programming language, there can't be variables
<matthewcroughan_>
Who wrote this then?
<matthewcroughan_>
Can we ring them up?
<bqv>
probably :D
<bqv>
but pedantry aside, you get what they were going for
<matthewcroughan_>
I even used the term "contains"
<matthewcroughan_>
someone said it doesn't contain anything.
growpotk- has quit [Ping timeout: 258 seconds]
<matthewcroughan_>
I don't know what to believe :D
<bqv>
the more accurate sentence would be "the value `pkgs` is ..."
<matthewcroughan_>
is what?
<matthewcroughan_>
> This line makes the current Nix expression a function. The variable pkgs contains Nixpkgs, while config contains the full system configuration. This line can be omitted if there is no reference to pkgs and config inside the module.
<{^_^}>
error: syntax error, unexpected ',', expecting ')', at (string):345:90
<multun>
variable help people familiar with imperative languages feel at home though
<matthewcroughan_>
Correct this whole paragraph please :D
pr06lefs has quit [Ping timeout: 260 seconds]
<matthewcroughan_>
If it's not a variable, what is it instead?
<matthewcroughan_>
A function?
<bqv>
the value `pkgs` contains nixpkgs, while `config` is a reference to the full system configuration
<matthewcroughan_>
An argument to a function? It's on the left, so it must be an argument, right?
<matthewcroughan_>
Based on what you said earlier, pkgs is an argument
iceypoi has joined #nixos
<matthewcroughan_>
"the argument pkgs is ..."samueldr
<MichaelRaskin>
bqv: yay, unwrapped nyxt runs
<bqv>
pkgs is indeed a value, and that's all it is
<multun>
pkgs is an argument to a function, to it's also a value
<matthewcroughan_>
samueldr: sorry! Accident
<samueldr>
yeah, I'm no pkgs argument :)
<bqv>
MichaelRaskin: oh? how did that work
supersandro2000 has quit [Disconnected by services]
supersandro2000 has joined #nixos
<MichaelRaskin>
We-ell
<matthewcroughan_>
multun: to WHAT function?
<MichaelRaskin>
Included a bit of fixing cl-wrapper
<matthewcroughan_>
It's amazing that there is not even one mention of "function" in the whole damned modules section
<matthewcroughan_>
wtf
lunik17 has joined #nixos
<matthewcroughan_>
who do I believe!
<MichaelRaskin>
By this section, just seeing {}: tells you it is a function
<multun>
matthewcroughan_: the whole file contains a function :) it has no name, it's a lambda function, an anonymous function. the first line defines the arguments, and the rest is the return value
<bqv>
matthewcroughan_: is there mention of "lambda"? because that would be interchangeable
<multun>
matthewcroughan_: it's a manual about nixos, not about the nix language
<matthewcroughan_>
Only one mention, in a completely different section bqv
<matthewcroughan_>
in "syntax summary" 5.3
<bqv>
better than nothing...
<matthewcroughan_>
5.4*
lunik1 has quit [Ping timeout: 240 seconds]
lunik17 is now known as lunik1
icey_ has quit [Ping timeout: 256 seconds]
Gh0ul has joined #nixos
<Raito_Bezarius>
anyone knows how to define a devShell and nixosConfigurations in a flake?
<Raito_Bezarius>
I'm trying many things but each time the devShell.buildInputs gets never loaded
<multun>
matthewcroughan_: have you ever learnt any python framework?
<Raito_Bezarius>
'nix flake show' shows me the devShell and the nixosConfiguration but I don't understand why deps are not loaded
<matthewcroughan_>
No, I regret saying I'm familiar with Python because I'm really not in the way that you think I am.
<matthewcroughan_>
I'm a noob.
<matthewcroughan_>
Just assume all I know is shell.
<bqv>
Raito_Bezarius: take a look at the nix wiki article on flakes
<multun>
hm
<Raito_Bezarius>
bqv: I did
<Raito_Bezarius>
the output schema didn't help me that much
<Raito_Bezarius>
let me paste the stuff
<bqv>
should have said how both of those don't take any top-level attrs except systems
<neothefox>
I have a simple question - what is the best way to add an arbitrary file that can be embedded into the .nix script itself to a filesystem during build? I have to check a variable in config.nix and then either create it or not
<MichaelRaskin>
bqv: I guess now you can pare down your wrapper and declare it top-level nyxt the application package
<bqv>
in progress
thelounge812 has quit [Ping timeout: 265 seconds]
lazylambda has joined #nixos
<lazylambda>
Hello functional friends, I'm trying to build the src of openid-client and before was trying to use it as a dependency. But it fails on 2/18 test cases then stops building the derivation. However when I install with "cabal build" none of these test cases fail.
<lazylambda>
Does anyone know why that might be? I haven't modified anything from the project including its' .nix files
<bqv>
hot take: you can always disable the tests and avoid that entirely
<lazylambda>
True, just wondering if there's checks in nix to see if a repository passes it's test cases
<lazylambda>
Or what would cause the difference leading to the failures, when using nix
<bqv>
it's entirely possible that the tests failing has 0 bearing on runtime behaviour