<jlv>
Is there something like `replaceStrings` to act on files?
<energizer>
jlv: substituteInPlace?
AluisioASG has joined #nixos
<jlv>
energizer: close. I'm looking to change `hardware.pulseaudio.configFile`, not a writable file, so I don't think that will work.
<cole-h>
ottidmes: I did indeed mean a review, thanks :) I use r+ for a positive review (approval) because it's short and it's what Rust does for its PRs with `bors`
WilliamHamilton has quit [Remote host closed the connection]
captjakk has quit [Remote host closed the connection]
captjakk has joined #nixos
numkem has quit [Ping timeout: 256 seconds]
captjakk has quit [Remote host closed the connection]
captjakk_ has joined #nixos
<bqv[m]>
ugh, i've just realised why almost every package i build is a cache miss now. i've been building almost every package in my system's dependencies across channels
r0bby is now known as robbyoconnor
robbyoconnor is now known as r0bby
<{^_^}>
[nixpkgs] @peti pushed to haskell-updates « hackage-packages.nix: automatic Haskell package set update »: https://git.io/Jvhhw
<zeta_0>
cole-h: oh ok, so that option does do that, i set the option in home.nix and removed the command from displayManager.sessionCommands in configuration.nix
captjakk has quit [Remote host closed the connection]
captjakk has joined #nixos
<zeta_0>
oh and it uses mkAfter to make sure it goes last, so it does not mess up the shell, that's nice
<{^_^}>
[nixpkgs] @gnprice opened pull request #85042 → stdenv: support __structuredAttrs, opt-in per package → https://git.io/Jvhhd
<zeta_0>
cole-h: thanks for pasting the link
<zeta_0>
cole-h++
<{^_^}>
cole-h's karma got increased to 22
<cole-h>
:P All I did was click on the "Declared by" link and scroll down to where `enableBashIntegration` was actually used
<zeta_0>
oh, i need to get better at searching through the documentation, sometimes i just ask here to save some time
KindOne has joined #nixos
<zeta_0>
cole-h: i'm setting up lorri+direnv+emacs, everything works good so far, all i have left to setup is emacs
<zeta_0>
nix frustrates me sometimes, but for the most part it's a very good tool
<neeasade>
zeta_0: the direnv package works well enough in my experience (same combination of tools)
<zeta_0>
neeasade: nice, energizer recommended this setup to me, i like it so far, it's automation is nice
<bqv>
compiling with -j32 when you only have 4 cores is ...suboptimal, right?
captjakk has joined #nixos
<gchristensen>
generally so, bqv :)
<ngortheone>
yes, say I am building a machine for doomsday
<bqv>
hmm
<codygman__>
pjt_014: Good idea. I was hoping a smaller group nix focused might see it first and recommend nix specific improvements if applicable.
<ngortheone>
and I want not to depend on Internet to build things
maxdeviant[m] has joined #nixos
<ngortheone>
in FreeBSD there is a way to download all sources for ports in a tree
<bqv>
why do people keep wanting to do this
<bqv>
it's bizarre and extremely unnecessary
<gchristensen>
ngortheone: cool, check the script maintainers/scripts/copy-tarballs.pl in the repo?
iyzsong has joined #nixos
<pjt_014>
I *think* `nix-env -i` might do it, but I refuse to try because I greatly fear death
<gchristensen>
bqv: corporate networks sometimes like to do the building themselves, and on machines without network access ... is the best I can imagine
<bqv>
heh
<gchristensen>
but also there is good reason to be able to identify and mirror all the sources.
<gchristensen>
we try to do that and sync it ot tarballs.nixos.org, for example
cr4y1_ has quit [Ping timeout: 264 seconds]
<codygman__>
bqv Is it that bizarre to want all of nix derivations stored on a hard drive? It's extreme, but also kind of cool to think about in a way :)
m0rphism has quit [Ping timeout: 256 seconds]
cr4y1 has joined #nixos
<pjt_014>
Have a set of things you know you might need in the event of the big boom-boom: nwtworking tools, a decent terminal multiplexer, backup tools, a browser that handles offline shit well, prob some other things
<bqv>
it makes sense on a distribution repository level, but on an individual level i can't imagine why anyone would want every source tarball in existence on their hard drive when they're only likely to use less than 1% of them, and the disk space required would really not be worth the price
<gchristensen>
you should take a gander at #datahoarder :P
<pjt_014>
It's cool in the same way that killing a fruitfly with an asteroid is
<bqv>
i'll pass :p
cjpbirkbeck has quit [Quit: cjpbirkbeck]
<pjt_014>
I mean we *can* recommend you offline-friendly stuff, there's major overlap there
<gchristensen>
people go looking for "interesting" data to ... just have? :)
<pjt_014>
ep
<pjt_014>
yep
<pjt_014>
source: me
<pjt_014>
I mean to a degree
<pjt_014>
people on the datahoarder subreddit have flairs for their storage amounts used
cjpbirkbeck has joined #nixos
<pjt_014>
some of them have 50TB+
<pjt_014>
I'm not on *that* level
<codygman__>
Well /r/datahoarder is a pretty good real world quality test to answer "what hard drives are reliable" I think. Then again... they have 50+ TB so would they notice stuff is corrupted/missing.
<pjt_014>
but if you need a preemo vintage copy of iczerone I got that I guess
<bqv>
meanwhile i think there's a grand total of 1GB worth of data on my drives not backed up somewhere online, that i actually care about
<pjt_014>
codygman__: they're well aware of the possibility
<pjt_014>
heavy duty filesystems like x/zfs or btrfs have measures to preven that
pie_[bnc] is now known as pie
<codygman__>
pjt_014: Makes sense, I only skimmed there for ideas for my duplicati based backup system.
<pjt_014>
and tools like git-annex are good for automatic redundancy managment
pie is now known as pie_
<pjt_014>
ideas? duplicati's pretty simple
<ngortheone>
gchristensen is right. Internet is unstable. Things that you can download today - tomorrow might be unavailable. One of the most recent things that I encountered - some derivation was having sources on russian resources. Russia was blocking a bunch of IPs and I couldn't download sources
<codygman__>
Well, I was looking for cheap online storage mostly pjt_014 since duplicati makes it super easy to encrypt before backup.
<pjt_014>
many tools do--restic, borg, bup...
<pjt_014>
that's without googling too
<pjt_014>
it's a common need
dongcarl has joined #nixos
<codygman__>
pjt_014 Well, you seem more experienced than I with those things. I was also learning about each of those and trying to choose before arriving at duplicati.
<pjt_014>
tarsnap's a fun one--you can legit backup onbe byte oneline for like $0.00000001/month
<pjt_014>
yeah dcati's def easier to start with
<pjt_014>
though once you get enough experience with the command line most of the ones I mentioned because roughly the same level of difficult
<pjt_014>
except git-annex.
<gchristensen>
pjt_014: I think you're off by at least one order of magnitude, since it is $0.25/gb/mo :)
<pjt_014>
I just jabbed 0s yeah
<codygman__>
I've actually used git-annex before. Yeah duplicati was super easy to setup, though when helping others use it a few UX quirks seemed to really hang people up.
<gchristensen>
ah okay. (you were pretty close though)
<simpson>
git-annex is really nice, but isn't a complete solution.
sigmundv_ has joined #nixos
<pjt_014>
it's a toolset for building your own backup system really
<pjt_014>
some assembly required
<pjt_014>
no joke my first package i PR'd for for an alternative to GA because I couldn't get it ti do what I wanted
<cole-h>
I don't think nix-index does incremental updates of the cache
<peelz>
shucks
<peelz>
should I make a systemd timer for it?
<cole-h>
Would be nice if I could force nix-index to generate a cache for every single attribute ever
<cole-h>
Sometimes things are hiding
<peelz>
what do you mean? like when derivations are split into multiple outputs?
<pjt_014>
peelz: you could just put an fcron entry in configuration.nix
<peelz>
pjt_014: I'd rather use a user systemd timer since I have nix-index installed as a user package
OrangeTetra has joined #nixos
<cole-h>
peelz: No, I mean when looking for things in haskellPackages.* or python38Packages.*, etc
<cole-h>
Those subgroups aren't searchable with nix-index AFAICT
<peelz>
cole-h: oh damn, that sucks
<Pwnna>
why is it that when i have matplotlib with enableQt = false, I still get a qt.qpa.plugin: Could not find the Qt platform plugin error when I try to do plt.figure() ?
<Pwnna>
Now my current environment _does_ have QT, but it's not imported by this standalone script
<OrangeTetra>
I've been testing the nixpkgs a bit and am not wondering: What else do the maintainers check other than a "nix-review" and binaries check?
<Pwnna>
when I unload my package that depends on qt, matplotlib starts to work
<pjt_014>
OrangeTetra: I maintain one package, and that's honsetly all I did
<pjt_014>
It came with tests that automatically executed too, so tere is extra coverage often
<pjt_014>
but I guess it depends on the comnplexity
aleph- has quit [Quit: WeeChat info:version]
aleph- has joined #nixos
<cole-h>
OrangeTetra: That's all, really. As long as ofborg gives you a green checkmark, binary runs (try in a `--pure` shell as well), and nix-review comes back positive, you should be good to go
<Pwnna>
ah nice i have to manually do a matplotlib.use
cr4y1 has quit [Ping timeout: 256 seconds]
<pjt_014>
they also check that your git commits are tidy
<peelz>
cole-h: do you put nix-index on a timer?
<OrangeTetra>
So is that why they like people contributing by just reporting if they could build it? Knowing how long it takes, I can't imagine them wanting to also do it for them al.
<cole-h>
Oh yeah, making sure your commits are properly formatted is good, too
<OrangeTetra>
pjt_014: Couldn't they just squash the commit if it isn't?
bhipple has joined #nixos
<cole-h>
They can, but some committers don't. If anything, you should `git commit --fixup` any changes -- I usually force-push though
<pjt_014>
Yes. and that's the hard part if you (hypothetically) already pushed it
<cole-h>
I believe GH should autosquash fixup commits on merge
<pjt_014>
git doesn't know what you want to do--it just kinda does exactly what you tell it
<pjt_014>
do `man git` and look under the 'name' field
<peelz>
cole-h: well yeah, but then why have it in buildInput if it's interpolated into the script?
<bqv>
he's right you know...
morgrimm has joined #nixos
<peelz>
bqv: who's right?
<codygman__>
Does anyone use Haskell, developPackage in their default.nix, and direnv? direnv appears to work for me but then cabal can't find my package dependencies :S
felixfoertsch has quit [Ping timeout: 246 seconds]
felixfoertsch has joined #nixos
<cole-h>
peelz: btw that was just an example that probably doesn't work -- think of it as a derivation. Here's a working example: it overlays discord to change the binary name to lowercase: https://gist.github.com/cole-h/24dc497c8ff8254bf6d6803b7018f39c
zeta_0 has joined #nixos
<clever>
cole-h: oh, maybe that will fix the file browser loosing its config constantly
<zeta_0>
energizer: i finished setting up lorri+direnv+emacs-direnv , thanks for the recommendation
<zeta_0>
energizer++
<{^_^}>
energizer's karma got increased to 4
<energizer>
:-)
<cole-h>
clever: What will? My Discord overlay? :P
<clever>
cole-h: the gdk backend fix you have in there
<cole-h>
Oh
<cole-h>
Hehe
<clever>
cole-h: every time i open the file picker in discord, it forgets the sort order and last dir
<zeta_0>
energizer: quick question, will i need to execute: M-x direnv-mode and M-x direnv-allow , manually all the time? or do these commands get automated as well?
<cole-h>
At least until Discord uses electron that comes with ozone
<gchristensen>
is ozone the one that supports wayland?
<codygman__>
zeta_0: Can you link what helped you finish setting up direnv?
<energizer>
zeta_0: you can turn on direnv mode in .emacs if you want. you'll have to do `M-x direnv-allow` in emacs or `direnv allow` in your system shell once per project directory, for security reasons
<zeta_0>
energizer: cool, so this automatically activate direnv-mode on startup? https://dpaste.org/vqOR
<codygman__>
zeta_0: Thank you. Sadly looks like I have a different issue since I've installed each of those and followed lorri's page on setting up direnv.
<energizer>
zeta_0: i think so
bhipple_ has joined #nixos
bhipple has quit [Ping timeout: 240 seconds]
<energizer>
in my display manager, when i go to enter my password after boot, the first character that i type into the password field doesn't get entered. is this a known issue? i've experienced it with a couple different display maangers
<energizer>
sddm and whatever the kde one is called
<codygman__>
Ah, when using only a default.nix with developPackage you need to specify default.nix should be loaded by direnv like `use_nix default.nix`
<zeta_0>
energizer: cool, i was just double checking, thanks again, i'll give you some more karma
<bqv>
has someone got the {^_^} version so i can compare the drv
<zeta_0>
energizer: uhh, i was having problems with my display managers as well(because it overrided my custom keyboard layout), so i just use xmonad by itself, without any desktop environment and it works fine with xmonad's default password login
<clever>
> nixos-unstable.lib.version
<{^_^}>
"20.09pre-git"
<clever>
ack, the .git is missing
<energizer>
yeah i'm not using a desktop environment either. curious.
<clever>
bqv: which channel are you on?
<bqv>
all of them
<bqv>
but linux should be building from nixos-unstable
<clever>
bqv: it also appears to be working fully on nixos-unstable
maxdeviant[m] has quit [Quit: authenticating]
maxdeviant[m] has joined #nixos
<bqv>
huh. odd
<bqv>
i tried nix-shell -p nix-diff and it said it was marked as broken
maxdeviant[m] has quit [Client Quit]
maxdeviant[m] has joined #nixos
<bqv>
ooh this is a nice tool
<clever>
bqv: nix-shell -p uses whatever <nixpkgs> is mapped to
<bqv>
oh, no wonder. i havent updated that for weeks
<bqv>
most frustrating. so linux is being recompiled because it depends on util-linux, which depends on systemd, which depends on iptables, which i've modified
<bqv>
along with half my system
zaeph1 has joined #nixos
<clever>
bqv: ah, that will do it
<clever>
bqv: you can use an override to force util-linux to depend on the old systemd
<clever>
and then it wont cascade up too far
maxdeviant[m] has quit [Client Quit]
<bqv>
yeah, i think i might
<clever>
you could maybe also do that to systemd
<clever>
depends on what your goal was
<zeta_0>
when i execute: `nixos-rebuild --upgrade switch`, does this keep the nix channels up to date? or do i still need to run the: `nix-channel --update` command?
<bqv>
probably better in systemd. my goal was to make sure anything using iptables by accident got redirected to nftables by the compat wrapper
<clever>
zeta_0: it updates the channel called nixos, but not any other channel
<bqv>
since stuff like libvirtd uses it module-internally
<codygman__>
Given default.nix `(pkgs.haskell.packages.ghc883.developPackage { root = ./.; })` and `pkgs.haskellPackages.shellFor { packages = p: [myapp];}` and then trying to call `nix-shell` I get `attribute 'getCabalDeps' missing`
zaeph has quit [Ping timeout: 265 seconds]
<zeta_0>
clever: that's good to know, i haven't ran `nix-channel --update` in a long time, but i do have an unstable nix channel as well, so i guess i do need to run it for that
<pjt_014>
Any way I can do `nix search -u` with limited ram?
<bqv>
ha! nice. overriding systemd reduced the number of packages i have to build locally by an order of magnitude
<zeta_0>
yesterday i asked a couple of questions on the nixos reddit website, if any of you are interested helping me fix that stuff: https://www.reddit.com/r/NixOS/
<pjt_014>
Hm. Maybe. I might end up doing it on a machine that can handle it and just yoink it over via sftp
<pjt_014>
We *really* need to memoize nix search -u sometime
<zeta_0>
i don't want to ask to many questions on this channel, so i'll ask a lot of my bigger questions there
<cole-h>
I think discourse and stackoverflow (or whatever) would be better places than reddit, tbh
<pjt_014>
zeta_0: I'll answer anything I know
<zeta_0>
cole-h: ya, but i like reddit, it just feels better to me
<zeta_0>
pjt_014: thanks for taking a look
<cole-h>
I meant better in terms of response speed/volume, but you do you.
fusion809 has quit [Remote host closed the connection]
<zeta_0>
cole-h: in reddit, i got responses almost immediately after i posted
<zeta_0>
cole-h: but ya, i get what your saying
<infinisil>
For Nix things I'd order Discourse > Reddit > StackOverflow
<infinisil>
There really aren't a lot of people answering Nix questions on SO
waleee-cl has quit [Quit: Connection closed for inactivity]
<cole-h>
Oh, really? I'll keep that in mind then.
<cole-h>
I retract (that part of) my statement :P
<infinisil>
Discourse seems to get the most activity
<cole-h>
Yeah, agreed
<evils>
second to IRC?
<infinisil>
Hehe yeah
<zeta_0>
i've never tried discourse before, so i'll need to take a look, i use an emacs pkg that integrates stack exchange with emacs, so being able to ask stackoverflow questions directly from emacs is very convenient
<DigitalKiwi>
emacs is truly a great operating system
<neeasade>
yes indeed
<evils>
even has a fairly good editor that looks like my username?
<DigitalKiwi>
doom does not look anything like evils
<DigitalKiwi>
fight me spacemacs users
<zeta_0>
emacs is amazing, it's a trip how many things you can do with it
<DigitalKiwi>
why's nix use /nix and not /opt #haskell is mad
<zeta_0>
sorry for being off topic, i go off on a tangent sometimes
orivej has joined #nixos
<bqv>
DigitalKiwi: lol, what would be the point of using /opt, nix is anything but FHS compatible
<DigitalKiwi>
the presumption is that the macos catalina issue wouldn't be an issue and that people wouldn't need root so shared computers on different os would be easier
<DigitalKiwi>
since not everyone can write to /nix
<DigitalKiwi>
(hey this is their argument not mine i'm with you on this lol)
LysergicDreams has quit [Ping timeout: 250 seconds]
xO1 has quit [Ping timeout: 265 seconds]
bhipple_ has quit [Ping timeout: 258 seconds]
<jonreeve[m]>
Anyone know how to get libstdc++.so.6?
<evils>
,locate libs-tdc++.so.6
<evils>
that, but without the typo :P
<{^_^}>
Couldn't find in any packages
<evils>
,locate libstdc++.so.6
<{^_^}>
Found in packages: robo3t, gcc-unwrapped.lib
<jonreeve[m]>
Hm every time I try to run this python program I get: `ImportError: libstdc++.so.6: cannot open shared object file: No such file or directory`
<jonreeve[m]>
But I have GCC installed
<pjt_014>
what program?
<jonreeve[m]>
Prodigy
<jonreeve[m]>
It's a propritary NLP program distributed in a `.whl` file
<{^_^}>
[nixpkgs] @jonringer pushed commit from @r-ryantm to master « python27Packages.smart_open: 1.9.0 -> 1.11.0 »: https://git.io/JvjJa
<energizer>
i forget the syntax but it'll be something like `poetry add file://foo.whl`
<energizer>
i haven't actually tried installing local filesystem packages with poetry2nix. if it doesn't work automatically, you can just add an override for it (documented on the poetry2nix readme)
<dsal>
I just built a new machine and forgot to try nixos. It's fresh enough that I'm considering destroying it. I can't seem to get started, though. Downloads are failing. I thought it was my local network, so I tried another one. That's also failing.
<pjt_014>
you try hydra?
<pjt_014>
here one sec
<dsal>
I'm just trying to download the virtualbox image and live install thing. I want to see if I can reasonably get my desktop/dev env setup before wiping this machine I just made. :)
<evils>
i seem to recall hearing new packages are usually not backported, so this will show up in 20.09
<pjt_014>
I can't find an explanation for how/when master gets merged into numbered releases
<pjt_014>
hmm
OrangeTetra has quit [Quit: Leaving]
<pjt_014>
Wait .09?
<pjt_014>
not .03?
<evils>
it's already in nixos-unstable-small
<evils>
pjt_014: 20.03 split off from master on 2020-02-10
<evils>
each numbered release has its own branch
<pjt_014>
I know that much
<pjt_014>
I just thought my PR would show up in 19.09 since that was the latest stable at the time
<energizer>
does nixpkgs merge package derivations that fail to build?
<energizer>
like, why are there build failures in nixpkgs at all?
zeta_0 has quit [Quit: rcirc on GNU Emacs 26.3]
<evils>
merging non-building packages could be done by a merger, but probably very rare; failures are probably due to a dependency being updated and in not being spotted (which can be done with nixpkgs-review)
<evils>
pjt_014: i'm not sure if there are exact rules for backporting, but i think that's limited to bug and security fixes
pjt_0141 has joined #nixos
<energizer>
evils: a dependency of A gets updated, A doesn't get automatically rebuilt?
* DigitalKiwi
cries about haskell-packages
bqv has quit [Ping timeout: 265 seconds]
<evils>
energizer: it does get rebuilt, but i think that's not done by the PR bot
pjt_014 has quit [Ping timeout: 240 seconds]
morgrimm has quit [Ping timeout: 264 seconds]
bqv has joined #nixos
<energizer>
evils: has there been discussion about whether that's a problem in the workflow? it'd be cool to have an always-green nixpkgs
pjt_0141 has quit [Remote host closed the connection]
<evils>
maybe some of the newer comments have addressed this, but i'm still wondering if it's possible to have a channel that has the most recent successfully built version of every package
<evils>
basically, "F closure size, give me something that works"
<pjt_014>
what is unstable if not that?
<evils>
unstable is the latest version of git master that passed a set of tests
<pjt_014>
oh. also did you answer my last question while I was disconnected?
<zeta_0>
energizer: so if i remove mkShell, direnv will stop working, if that's the case then i'll need to add mkshell to the other shell.nix files that i want to paste in that file
<energizer>
zeta_0: yes
<zeta_0>
energizer: thanks of clearing that up, it makes more sense now
<zeta_0>
cool, well i'm going to get off now, i'll test out the lorri tool more tomorrow, thanks everyone for the help
<zeta_0>
later
<energizer>
evils: idk what's involved in making a channel, it can't be very hard to query hydra for the latest successful version of a package and turn that into a channel/flake/whatever
init_6 has quit []
<energizer>
s/a package/all packages/
<iqubic>
What the difference between the lean package, and lean2?
zeta_0 has quit [Quit: rcirc on GNU Emacs 26.3]
<evils>
energizer: i think a channel ultimately comes down to a tarball of a git repo at a specific point, merging all working points together would most definitely result in some conflicts...
<energizer>
iqubic: lean is lean3, lean2 is old
<iqubic>
Ah. I see. I'll install lean3, and hopefully be able to install the emacs package too, both through nix.
<iqubic>
Is there a way to see which melpa packages have been ported to nix?
<sphalerite>
peelz: it's called import-from-derivation. I wouldn't consider it an antipattern as such, but it does come with some pitfalls
<sphalerite>
peelz: for instance, it prevents evaluation without access to the local store (so you can't do `nix build --store ssh://some-remote-machine` on an expression using it
<sphalerite>
peelz: it breaks the clean split that non-IFD derivations have between evaluation and building
<sphalerite>
peelz: it's also not allowed in nixpkgs, because hydra can't deal with it
<sphalerite>
oh wait, I forgot we have a factoid about it.
<sphalerite>
,ifd
<{^_^}>
import-from-derivation (IFD) is when you evaluate nix from a derivation result, for example `import (pkgs.writeText "n" "1 + 1")` will evaluate to 2. This is sometimes problematic because it requires evaluating some, building some, and then evaluating the build result. It has been described as "such a nice footgun."
mallox has joined #nixos
<peelz>
sphalerite: oh thanks for the explanation! <3
<peelz>
<3 sphalerite
<{^_^}>
sphalerite's karma got increased to 82
OrangeTetra has quit [Ping timeout: 256 seconds]
<evertedsphere>
TIL you can do that, a heart is much nicer than rudely incrementing someone
<peelz>
haha
jakobrs has joined #nixos
<jakobrs>
Is it possible to set the niceness on individual nix builds?
<jakobrs>
*of
<peelz>
sphalerite: can you explain what you meant by "hydra can't deal with it"?
jerryaldrichiii has quit [Ping timeout: 256 seconds]
<{^_^}>
[nixpkgs] @nschoe opened pull request #85055 → st: copy config file in 'prePatch' instead of 'preBuild' → https://git.io/JvjkD
ATuin has joined #nixos
s1341 has joined #nixos
<s1341>
morning all.
jerryaldrichiii has joined #nixos
<pjt_014>
is that what they're calling it now?
<s1341>
@Mic92 hi, i'd like to bump the frida-tools version to a more recent release... I see it's in your NUR repo... Should I open a PR against your repo?
<linarcx>
evils: Put `preFixup` inside my `shell.nix`?
<evils>
linarcx: i'm not sure how you got to that conclusion from that link...
<linarcx>
I'm developing a vala application.
<linarcx>
So. how your solution related to my problem?
<linarcx>
It's my concern.
<evils>
i think you want to add wrapGAppsHook to nativeBuildInputs, and probably hicolor-icon-theme to buildInputs
revtintin has joined #nixos
<linarcx>
evils: No. it's not working.
<{^_^}>
[nix] @LnL7 opened pull request #3488 → never use /var/folders for TMPDIR on darwin → https://git.io/JvjIW
<linarcx>
Oh. actually i'm using zsh and seems hooks don't work within zsh. Isn't it?
<evils>
then it may be vala specific (i'm not familiar with that), have you tried to look for other vala applications in nixpkgs that use hicolor-icon-theme?
<nschoe>
Hi everyone. I have a quick question: I have a nix-channel on 20.03 (so https://nixos.org/channels/nixos-20.03) Am I correct in thinking that it points to github´s NixOS/nixpkgs on branch nixos-20.03?
<Mic92>
s1341: I can update it.
<symphorien>
release-20.03 rather
<s1341>
thanks @Mic92
<nschoe>
i.e. instead of running nix-channel --update it should be the same to git pull on that branch and specify it with nixos-rebuild -I nixpkgs=/path/to/my/nixpks ?
<symphorien>
Mmh suddenly I have a doubt
<nschoe>
symphorien, ah that was my question indeed :)
jeromelanteri has joined #nixos
<jeromelanteri>
hey guys, i break something in my user logged. I did "nix-env -S 8"
<jeromelanteri>
nox ls -la /home/jerome show me ~/.nix-profile linked to .nix-profile
<jeromelanteri>
and when i try to fix that by nix-env -S /home/jerome//.nix-profile, it failed with error too many level of symbolic links
<nschoe>
pbogdan, okay, it would explain why release-20.03 has more recent commits than nixos-20.03.
<nschoe>
So most likely, channels are on nixos-20.03.
zupo has joined #nixos
<nschoe>
I´m asking because I submitted a PR and while I´m waiting for it to be accepted, I wanted to use it internally, but still wanted to be up-to-date with the channels. So insteado fupdating channels, Iĺl git pull on the branch.
<nschoe>
But maybe this is too much work and I should make an override instead. Don´t know
thc202 has joined #nixos
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<noonien>
sorry, i meant channels that are available to the system
st3r4g[m] has left #nixos ["User left"]
<hyperfekt>
noonien: (sudo) nix-channel --list
<noonien>
and what does `nixpkgs` point to?
<noonien>
the first one?
vidbina has joined #nixos
<hyperfekt>
noonien: check your $NIX_PATH to be sure
<hyperfekt>
usually i think yes, but some people have it modified
<noonien>
ah, so it points to NIX_PATH
<hyperfekt>
sorry, not to the first one, but to the nixos channel iirc
<hyperfekt>
anything in angle brackets will be resolved according to $NIX_PATH
<noonien>
hmm, is there a way to list all of them?
<hyperfekt>
all of what?
<noonien>
i'm trying to do this in python, so if there'a library, or an easier way of doing it, it would be super
<noonien>
list all the channels, or, atleast all the values that i can put in `<>`
<hyperfekt>
noonien: i think parsing $NIX_PATH would be your best bet
<hyperfekt>
for the latter
<noonien>
i see :(
<hyperfekt>
there is a default location for the channels on disk, so if you want to list those you could do that by reading that directory (see your $NIX_PATH for which one it actually is, i don't remember)
<{^_^}>
[nixpkgs] @worldofpeace opened pull request #85065 → nixos/displayManager: make autoLogin options independent of DM type → https://git.io/JvjqQ
<hyperfekt>
i'll allow myself to raise the question of how much work you want to put in channels considering that flakes, which should make channels obsolete, are incoming
chloekek has joined #nixos
<noonien>
oh, i didn't know about flakes
<Mic92>
s1341: New frida tools should be available once the channel is updated.
<hyperfekt>
whenever i try to look up how another distro has solved something i am very grateful that our source is a git repo
<zeorin53>
Hello all! I'm a new NixOS user. I'm trying to install `st` with patches. I'm currently using only system-level declarative package management (`/etc/nixos/configuration.nix`). However there are quite a few patches I'd like to apply and I'd like to try building this package in isolation from the rest of the system and get the config right, before
<zeorin53>
adding it to the system config file. How can I do this?
<runforestrun>
any idea why I cannot see the list of generations when I boot my nixos anymore? I recently did a `nix-collect-garbage -d` but I've done `nixos-config switch` quite a few times since then
<runforestrun>
`nixos-rebuild switch` is what I meant
fusion809 has joined #nixos
captn3m0 has quit [Read error: Connection reset by peer]
captn3m0 has joined #nixos
<sshow>
I've been deploying to my machine with nixops, and the morning after it's back the the state before I deployed. How can I see, and edit, the list of rollbacks and deployments?
<hyperfekt>
zeorin53: you'll want to create a separate nix file with just the st derivation. you can access pkgs by assigning 'import <nixpkgs> {}' to it
<hyperfekt>
sshow: any chance you have a configuration in EC2 user data? NixOS will apply that on any restart
<sshow>
hyperfekt: no, this is my own metal
<sshow>
I think I want to edit the rollback history, or permanently switch to the current settings, like you would with `nixos-rebuild switch`, but I don't know how to do it
<zeorin53>
hyperfekt: Thanks. Could you point me to an example? I'm afraid I don't have enough context with NixOS yet to fill in the blanks
<hyperfekt>
zeorin53: almost. you're not making this a NixOS module though, so you can leave off the top level attrset, assignment to environment.systemPackages and the singleton list
<hyperfekt>
zeorin53: that way, when you do nix build st.nix you'll get the directory with your built st back.
<hyperfekt>
zeorin53: you're really close now. try evaluating it
<zeorin53>
`error: undefined variable 'fetchurl' at /home/zeorin/code/st/st.nix:3:46`
tsrt^ has quit []
<hyperfekt>
the top level namespace is empty but for 'pkgs'. you'll have to specify where that function is coming from. also fetchurl can only download one thing at a time, so you may want to map it over your list of patches
symphorien has quit [Quit: WeeChat 2.7.1]
LysergicDreams has quit [Ping timeout: 260 seconds]
<zeorin53>
Lol I was getting a 404 error from fetchurl. Couldn't figure out why it was failing (I'd just downloaded the patches manually to get the hashes). The patch list was just updated. Had to clear the browser cache to pick it up.
philr has quit [Ping timeout: 240 seconds]
runforestrun has quit [Remote host closed the connection]
<noonien>
how can i get the system's nix-compatible arch?
<noonien>
for example, my current system is i686-linux
<gchristensen>
> builtins.currentSystem
<{^_^}>
"x86_64-linux"
<noonien>
x8_64-linux, oops
<noonien>
great, thanks!
<noonien>
is it stored in a file by any chance?
<gchristensen>
I don'tthink so, what's up?
<noonien>
i'm trying to get it within a script
philr has joined #nixos
logand has quit [Remote host closed the connection]
symphorien has joined #nixos
<noonien>
i'm working on improving my nix-run script, i'm translating it to python, and i'm reading `/nix/var/nix/profiles/per-user/root/channels/{channel}/programs.sqlite` to find a package that provides my program
<awatanabe[m]>
i started using NixOS 2 or 3 days ago, coming from Gentoo. Have been reading though Nix, NixOS and nixpkgs manuals and having fun. Right now, for work I need to work on a python project which is calling dlib with CUDA, I'm wondering what the best way to go about this is. From what I can tell, I should set up a shell with dlib, dlip python, and pass a custom CMAKE override to dlib? ("cmake -D DLIB_USE_CUDA=1 -D
<awatanabe[m]>
USE_AVX_INSTRUCTIONS=1 ../" is what I need to pass specifically). Could anyone point me to the right documentation to accomplish what I'm trying to do?
<{^_^}>
[nixpkgs] @hyperfekt opened pull request #85073 → nixos/systemd: enable systemd-pstore service → https://git.io/JvjOV
adrielus has quit [Remote host closed the connection]
InvisibleRasta has quit [Quit: WeeChat 2.3]
kai_w has quit [Quit: Konversation terminated!]
<gchristensen>
jeromelanteri: btw based on your comment on #66859, it looks like you're still looking at nix-env. yesterday when I told you I didn't really know how nix-env worked, maybe you got the impression I'm not much of a NixOS user. but I am :). nix-env isn't very common on NixOS
logand has quit [Remote host closed the connection]
<gchristensen>
I worry a bit about the videos and what they will show, because we (the nixos community) would probably not want people using nix-env for their system
iyzsong- has quit [Read error: Connection reset by peer]
invra has joined #nixos
<jeromelanteri>
gchristensen, oh sorry. As you can see, i did post a lot of questions. And i'm pretty new user and pretty new connected to this channel. i was asking for some links who clarify the situation with the exhaustive list of all nixos commands to manage nixos. I get some links i did had already when i serached on duckduckgo.... these links seems toi me usefull, but not really clear and exhautives.
morgrimm has joined #nixos
dsg has quit [Remote host closed the connection]
<jeromelanteri>
gchristensen, ok, i'm pretty ready to publish a video on YT but it target on use to nix-env command...
<gchristensen>
almost the only command to manage nixos is `nixos-rebuild`
<gchristensen>
nixos-option is useful too, but those are really the only two
<jeromelanteri>
i'm still ok, to not publish this one and read a link who can make me felling to understand better what you mean.
revtintin has quit [Ping timeout: 256 seconds]
<jeromelanteri>
gchristensen, ok, so from user connected (not root), i can use nixos-rebuild to install a new package ?
<jeromelanteri>
i then will have a new generation added to my default user profile ?
<gchristensen>
no, for that people would usually use nix-shell to get a thing they want to use, sometimes they would use nix-env. but that is more about Nix, less about NixOS
<jeromelanteri>
i was thinking that nixos-rebuild is only for the use case where the configuration.nix general config file was updated and ready to apply...
<bkv>
question: is there *any* mechanism in nixos currently to handle hotplugged network devices?
<gchristensen>
jeromelanteri: right, most changes people make to their system (adding packages permanently, etc.) are done with configuration.nix
<the_pumpkin_man[>
jeromelanteri: you know that you can also put packages in the configuration.nix ?
<jeromelanteri>
gchristensen, ok, i should focus on nix-shell script for user manage its own profile of packages to install
<the_pumpkin_man[>
So when you change that file to add a package, you just nixos-rebuild and its done
<the_pumpkin_man[>
There's actually no way to manage packages per-user with a config file, except by using home-manager
<jeromelanteri>
the_pumpkin_man[, yes, i did it for vim... for example. but i'm thinking (maybe wrong) that these one are system wide access by all users... isn't it ?
<jeromelanteri>
nixos-rebuild... and what is "switch" string target about exactly ?
<the_pumpkin_man[>
Yes, configuration.nix is system-wide
<gchristensen>
the_pumpkin_man[: if I want to install some package forever, I put it in environment.systemPackages. if I want some programs for a project I'm working on, I put them in a shell.nix and run `nix-shell`. for example: https://github.com/grahamc/mayday/blob/master/shell.nix
f0x has joined #nixos
<gchristensen>
samueldr: I see the "github is sending invalid events" bug is striking {^_^} ... :/
<jeromelanteri>
shell.nix ? where is it located ?
linarcx has joined #nixos
morgrimm has quit [Ping timeout: 250 seconds]
<gchristensen>
in your roject directory
<jeromelanteri>
so it can be everywhere inside $HOME dir
<the_pumpkin_man[>
For understanding nixos-rebuild
Guest40360 has joined #nixos
<gchristensen>
jeromelanteri: open two terminals. in one, run this command: nix-shell -p python38 in another, run this command: nix-shell -p python37
<jeromelanteri>
ok. i see many good manual pages around each command... but i failed to get a wise view of all of them and the "best practice" to learn with.
<awatanabe[m]>
a shell.nix is like a virtualenv/conda environment/etc but instead of handling just python libraries you can put anything in it
<the_pumpkin_man[>
jeromelanteri: nix is the package manager, NixOS the operating system and nixpkgs a nix expression collection, think of it as the packages you can install with nix
pbogdan has quit [Ping timeout: 256 seconds]
<jeromelanteri>
ok, down to all the tree... there is nix (the only one package manager). This is for me, a great start point.
<awatanabe[m]>
nix <-> nixpkgs now makes sense to me... thanks!
<the_pumpkin_man[>
And if you read my link above for nixos-rebuild, it expalins you.
<the_pumpkin_man[>
For example adding "switch" do >build the new configuration, make it the default configuration for booting, and try to realise the configuration in the running system (e.g., by restarting system services).
<the_pumpkin_man[>
* And if you read my link above for nixos-rebuild, it expalins you.
<the_pumpkin_man[>
For example adding "switch" do `build the new configuration, make it the default configuration for booting, and try to realise the configuration in the running system (e.g., by restarting system services)`
revtintin has joined #nixos
<jeromelanteri>
so nixpkgs is a kind of function call to get metadata around env like variables used by nix
<jeromelanteri>
or collection, yes
<gchristensen>
nixpkgs is a collection of Nix expressions to build many thousands of programs
<the_pumpkin_man[>
Just a directory with lots of nix expressions
<jeromelanteri>
switch is then to put rebuild result as default one on next boot (and any other as long as no new switch from nixos-rebuild)
<the_pumpkin_man[>
and a nix expression tells Nix how to get the package's binary or how to get the source and build it
<jeromelanteri>
ok, fine, i think i get it nice now.
<gchristensen>
switch makes that configuration active, right now.
Izorkin has joined #nixos
<the_pumpkin_man[>
switch is also to make your changes apply now
<gchristensen>
switch also makes it the configuration you will load after you reboot
<the_pumpkin_man[>
So for example, if you added some packages and run `nixos-rebuild switch, it will add it
<jeromelanteri>
i would ilke, guys, to be sure to not propagate fakes, to redact a text to talk about this who will be my ref for my video to build on that. Would you like to read it when finish and correct what will be wrong ?
<the_pumpkin_man[>
But if you `nixos-rebuild build`, then you will not see the package
<jeromelanteri>
switch ==> now and by default
<the_pumpkin_man[>
Yes
<the_pumpkin_man[>
Build => just building it
<the_pumpkin_man[>
Test => now but not by default
<gchristensen>
jeromelanteri: if you post a link to your video before it is published, I am sure people will review it and give feedback
<jeromelanteri>
so without switch ? nixos-rebuild just make change (but not now), after reboot then ?
<the_pumpkin_man[>
Boot => not now but by default
<jeromelanteri>
gchristensen, video in french language ? i'm not so sure...
<the_pumpkin_man[>
I think just `nixos-rebuild` does nothing
o1lo01ol1o has quit [Remote host closed the connection]
Guest40360 has quit [Changing host]
Guest40360 has joined #nixos
Guest40360 has joined #nixos
<gchristensen>
jeromelanteri: sure. it won't be me, but there are plenty of french speakers. #nixos-fr has them all in one place :)
<jeromelanteri>
i can try to make it as english language, but i scare someone next would like to kill me for my soouth's french accent and bad english knowledges level...
Guest40360 is now known as joepie91
<the_pumpkin_man[>
Like me, Im a frecn speaker :)
<the_pumpkin_man[>
* Like me, Im a french speaker :)
<dwagenk[m]>
comparing builtins.currentSystem to i686-linux vs x86_64-linux?
revtintin has quit [Ping timeout: 258 seconds]
<jeromelanteri>
the_pumpkin_man[, ok, so if you can accept, i will PM you when i get this readaction ready (in english first), then i will show you my poor video before to publish.
<gchristensen>
the_pumpkin_man[ thanks!
<gchristensen>
thanks, jeromelanteri!
<jeromelanteri>
thank you guys... very good.
<the_pumpkin_man[>
Ok, I will try my best
<gchristensen>
we want to help make sure your video is really good, and shows NixOS's unique features well :)
<the_pumpkin_man[>
I'm still a newcomer on NixOS, I don't know all the details but the basics
<jeromelanteri>
yes, that is the idea.
<jeromelanteri>
the_pumpkin_man[, you know much more than me.
<the_pumpkin_man[>
Ok good :)
magnetophon has quit [Ping timeout: 240 seconds]
mounty has quit [Ping timeout: 240 seconds]
mounty has joined #nixos
<MichaelRaskin>
NixOS is Europe-originated project, and at least a third of Europe can understand French, after all.
<gchristensen>
I am the odd one out :(
<the_pumpkin_man[>
Oh didn't know that
<gchristensen>
also I didn't expect getting in to NixOS would create so much pressure in my life to move to Europe
<the_pumpkin_man[>
gchristensen: don't worry, there are many non-european contributors to NixOS :p
<gchristensen>
:)
<the_pumpkin_man[>
That's the good thing with community-based project, it's not for a country, but for all the entire world
<jeromelanteri>
MichaelRaskin, wow... i'm not sure. I'm thinking NixOs concept to be so special and in advance that it can also be great for universal users.
<MichaelRaskin>
jeromelanteri: I mean just that you can easily get some comments from whoever French-understanding who has time whenever you post a link
magnetophon has joined #nixos
revtintin has joined #nixos
<jeromelanteri>
MichaelRaskin, yes, i hope to. I should increase my english speaking also. but i speak in Thai-nglish in Thailand where i stay half of the year, every year. I was thinking to increase my english... but it is more bad to speak English in Thailand than in Frnech country (funny...).
<MichaelRaskin>
I am not saying we don't have a lot of people from outside Europe, only that we do have a lot of people from inside Europe. (I, personally, do a ton of silly mistakes in my French, as it is my third language)
<jeromelanteri>
yes, i think i get the idea now.
<evertedsphere>
it's more like "nix/nixos is far less american-dominated than one unconsciously comes to expect for open-source software projects"
<jeromelanteri>
third language... wow... my third language is C++.
<jeromelanteri>
English is my... i don't know in fact.
<evertedsphere>
gchristensen: really enjoyed the zfs post, waiting for the next one
<gchristensen>
cool :) posting Monday.
<evertedsphere>
is elevator=noop not the default?
magnetophon has quit [Ping timeout: 256 seconds]
<ottidmes>
I had to learn English, German, and French, aside from my native Dutch, but I never really used German and French so now I don't even claim to be at beginner level, I just remember bits and pieces. I remember when on vacation in France nobody in the village we were staying could speak English, so they had to get someone's niece that spoke some XD
<{^_^}>
[nixpkgs] @ElXreno opened pull request #85076 → chromium: provide chromiumVaapi with VA-API support → https://git.io/Jvj3d
<gchristensen>
evertedsphere: it is for nvme drives. the elevator=noop bit is maybe not quite right, I guess I don't know the right way to set it
<jeromelanteri>
siraben, no, i'm french guy. But i love Thailand and be married there and have a life in the wide north country side of Thailand where people are so good mind thinking.
<dwagenk[m]>
it was quite busy here, while I wrote my last question, so here's another try:
<dwagenk[m]>
I'm trying to package something, that consists of source code and some prebuild libraries, that it links against. I get it to compile and link against all the dependencies, but it won't find the prebuild libraries. How do I do something like that?
<zfnmxt>
My terminal currently looks like this: https://i.imgur.com/fxJ5ao3.png and the issue extends to multiple other applications (e.g. my status bar and dunst). Any idea what's wrong? I've tried a nubmer of different fonts (Terminus, GohuFont, etc) and it happens with all of them...except if I try TTF fonts! Then there's no issue.
<evertedsphere>
going off on a limb here: locale issue?
<AmandaC__>
fontconfig removed support for bitmap fonts, I believe, if either of those fonts are such.
<{^_^}>
[nix] @edolstra merged pull request #3488 → never use /var/folders for TMPDIR on darwin → https://git.io/JvjIW
<{^_^}>
[nixops] @edolstra pushed 2 commits to flake-support: https://git.io/JvjGV
<zfnmxt>
AmandaC: I believe they both are!
morgrimm has joined #nixos
superbaloo has quit [Quit: WeeChat 1.6]
<zfnmxt>
Oh, looks like fonts.fontconfig.allowBitmaps will fix the issue.
<AmandaC>
oh nice
<zfnmxt>
Why is it set to 'false' by default? Are bitmap fonts now seen as no-nos?
<monokrome>
Does there need to be a specific extra package installed for cstdlib to exist in clagStdenv when using clang++?..
<zfnmxt>
The TTF variation of Terminus looks like crap =/
<AmandaC>
GNOME removed support for them a year or so ago, then everyone else kinda followed their lead
qrnteen has joined #nixos
<zfnmxt>
I see. Well, thanks for solving my issue so quickly. :)
<monokrome>
seems like not... wat
<monokrome>
makefile was using CC instead of CXX
* monokrome
facepalms
<zeorin53>
Hi, I'm trying to apply patches to a package and I'm getting the following error: `cannot coerce a set to a string` when trying to apply some patches to libXft: https://pastebin.com/wk5msnM9
<zeorin53>
Context: I'm trying to build a version of suckless's `st` that has support for colored emoji and some other patches. The color emoji support requires a bugfix in libXft that hasn't been merged yet.
fenedor has joined #nixos
vidbina has quit [Ping timeout: 256 seconds]
fendor has quit [Ping timeout: 240 seconds]
linarcx has joined #nixos
<b42>
zeorin53: try wrapping fetchurl { ... } in parentheses
Maxdaman1us has joined #nixos
reallymemorable has joined #nixos
Maxdamantus has quit [Ping timeout: 256 seconds]
<immae>
there is the fetchpatch function too which does a bit of smart things instead of fetchurl
<zeorin53>
That works well
<zeorin53>
N00b gotcha
sigmundv_ has joined #nixos
shweta has joined #nixos
<shweta>
is there a way to install nix on yosemite 10.10.5. nix installation says this old mac version is not supported.
<{^_^}>
[nixops] @edolstra pushed to flake-support « Nixpkgs overlay: Don't use 'pkgs' »: https://git.io/JvjZo
<srxl[m]>
I have a derivation for elixir-ls that I've got going in an overlay. Since it's a BEAM development tool, one would think it shoud go in `beam-modules`, however it uses none of the existing BEAM tooling since I wasn't able to build it using it. If I wanted to upstream this into nixpkgs, where would it go?
abathur has joined #nixos
<{^_^}>
[nixos-org-configurations] @edolstra pushed 6 commits to master: https://git.io/JvjZM
<clever>
ixxie: how much ram does the machine have, how big was the initrd?
<monokrome>
jared-w: I tried that as well, but same result as `--run`. I think that `--command` and `--run` do the same thing if not in an interactive console, I guess?
<clever>
monokrome: what happens if you just `nix-shell` and then `make` seperately?
<ixxie>
clever: donno how big initrd was, but the VM had only a gig of memory so I quadrupled it and tried again; now it seems that error isn't appearing but the kexec isn't working somehow
<ixxie>
clever: holdon, ill paste you the logs
<monokrome>
if I do it on my local machine then it works, but I don't know how to do that via this build script
never_released_ has joined #nixos
<monokrome>
nix-build may be ideal, but it runs scons
<clever>
monokrome: scons should work in nix-build too
never_released has quit [Ping timeout: 256 seconds]
bhipple has quit [Ping timeout: 264 seconds]
<monokrome>
the problem w/ nix-build is that a dependency needs scons and my parent project uses Makefile, but installing scons in `buildInputs` has caused nix-build to try to run scons which fails
<ixxie>
clever: I found an alternative command for initiating the systemd reboot is systemctl start kexec.target but this also fails with this error in the logs: https://pastebin.com/sdHdD97B
zupo has joined #nixos
<clever>
ixxie: are there any interesting logs on the display in virtualbox?
<monokrome>
clever: ah, makes sense... >.<
<monokrome>
omg I built it and it's failing locally but worked on the build server
<monokrome>
lol
<clever>
monokrome: any files leftover in the bin dir?
<monokrome>
oooh I didn't commit the cxx file yet, that's why it didn't fail =^.^=
<monokrome>
clever: there is no bin dir any more :D
<ixxie>
clever: nothing too exciting, it said 'Failed to start Reboot via kexec` `See systemctl status systemd-kexec.service` and `Dependency failed for Reboot via kexec`
<{^_^}>
[nixpkgs] @Ericson2314 opened pull request #85085 → nixos/doc: Document breaking change to Haskell dev shells → https://git.io/JvjnN
<hyper_ch>
you broke clever's kexec? oO
<clever>
ixxie: anything in the journals after it boots back up?
<{^_^}>
[nixpkgs] @bhipple opened pull request #85086 → discord-{ptb,canary}: update to latest versions and fixup updateScript → https://git.io/JvjnA
<clever>
hyper_ch: trying to make it work with `systemctl kexec`
<hyper_ch>
:)
chloekek has quit [Ping timeout: 256 seconds]
<ixxie>
clever: only the ESP partition thingy I shared before
<clever>
ixxie: i believe systemd will run that script when its done shutting down, and wants to "kexec" the machine, and this part will actually load the kernel, but line 21 will detect one already loaded and skip
work_ has joined #nixos
<clever>
Applications wanting to reboot the system should not start this unit directly, but should instead execute systemctl kexec (possibly with the --no-block option) or call systemd(1)'s org.freedesktop.systemd1.Manager.KExec D-Bus method directly.
<clever>
ixxie: from `systemd.special`
<ixxie>
clever: so it should have been systemctl kexec... hmm... but running that effective seemed to do nothing
<ixxie>
clever: except complain about the ESP partition
<clever>
ixxie: what does the kexec-prepare.service look like on ubuntu?
<jeromelanteri>
Do you have in mind a list of words which can be designed by a "NixOS specific lexical words concepts" to know about ? (like: [generation, store, profile ])
<jeromelanteri>
if you get some, feel free to post thess words as part of the answer
<jeromelanteri>
simpson, good, but not perfect in fact. There is some leakage. (the one i include in a list as "generation", "profile", and maybe some other.
<Orbstheorem>
Hi! I think I remember something about a special string that nix replaces with a unique string during build and will scan for that string after building the derivation and replace it with the derivation path/
<ixxie>
clever: not sure what are the related commands I should search for..
<clever>
ixxie: its prepare-kexec
zupo has joined #nixos
<Orbstheorem>
Does it exist and if so, what's its name?
<ixxie>
clever: doesn't find that...
<clever>
ixxie: prepare-kexec.service?
<clever>
Orbstheorem: builtins.placeholder
<ixxie>
clever: tried that too, no luck
<clever>
ixxie: what about the /lib/systemd/system/ dir, anything in there?
<nschoe_>
clever, yes indeed. Is there another place where I can browser options available in 2-.03?
<nschoe_>
clever, nah it´s fine: Firefox seems to decompress it fine. It´s just not as convenient at the normal page
<clever>
nschoe_: i think the simplest is to just boot 20.03 and run `man configuration.nix`
<ornxka>
ah debug1devices i think it is
jgeerds has quit [Ping timeout: 260 seconds]
cole-h has joined #nixos
<nschoe_>
clever, I´m running 20.03 now. Did not know the options were in the man, but okay thanks!
rogue_koder has joined #nixos
<nschoe_>
Oh I´ve just tested it, it´s very convenient. Perfect, thanks
<nschoe_>
(This must be one hell of a big man page :D)
shibboleth has joined #nixos
<morgrimm>
What would be the best way to apply an override that sets args for a package? For example, the st derivation takes patches/extraLibs as args. Right now I'm overriding patches with an overlay, but that's the attr and not the arg
<clever>
nschoe_: 97434 lines long
justanotheruser has quit [Ping timeout: 246 seconds]
<nschoe_>
That... must be a record :D
<clever>
morgrimm: .override is for the args on the 1st line of the file, .overrideAttrs is for the stuff passed to stdenv.mkDerivation
cole-h has quit [Client Quit]
cole-h has joined #nixos
<morgrimm>
Ah, perfect, gotcha. Thanks clever
<__monty__>
clever: Do you know if the nix installer should just work in fish?
<clever>
__monty__: i believe it has a #!/bin/bash at the top, so it will force itself to run under bash
<__monty__>
Yeah but the PATH setup and stuff isn't done, right?
rogue_koder has quit [Ping timeout: 260 seconds]
<clever>
__monty__: i think it has most of the needed deps baked into it
magnetophon has joined #nixos
<__monty__>
Yeah but nix-env doesn't end up on the user's PATH.
<__monty__>
That's the only problem.
codygman has joined #nixos
<clever>
__monty__: oh, that, it modifies the .bash_profile or something, and you need to copy it to the .fishrc
<clever>
__monty__: check `ls -ltrha`
<ornxka>
is there some way to limit max tries in luks via grub kernel flags
<ornxka>
i am trying to debug why i cant decrypt my disk so im trying to get a shell, but debug1 gives me a shell before my usb keyboard is vailable and debug1devices wont give me a shell until after i attempt to enter my luks password, which keeps asking me indefinitely and doesnt give up and give me the shell
<ashkitten>
clever: my configuration.nix manpage is 127702 lines :)
<{^_^}>
#65375 (by deliciouslytyped, 37 weeks ago, open): GRUB silently generates wrong config (cryptsetup default is now LUKS2)
<clever>
ornxka: and the preLVMCommands is where luks gets inserted
<clever>
ornxka: if your luks is bare on a partition, your basically screwed, but if the luks is inside an lvm array, then debug1devices will work
codygman has quit [Ping timeout: 256 seconds]
<ornxka>
yeah i dont use lvm
<ornxka>
shoot
<clever>
ornxka: but you can always clone nixpkgs at the same rev your currently using, edit stage-1-init.sh to make things simpler (add fail in a few places) and build from that
<ornxka>
srk: ah ill have a look at that
domogled has quit [Quit: domogled]
<srk>
if you installed recently it's quite possible
codygman has joined #nixos
domogled has joined #nixos
<ornxka>
i did, and i do use luks2
<srk>
yeah, thats exactly it ^^
<ashkitten>
i don't think i've really used `man configuration.nix` tbh, only `nixos-config`
<ornxka>
thats kind of strange though, because i didnt know grub knew about luks
<ornxka>
i thought that grub simply ran the initramfs, which has cryptsetup in it that nixos copies over from the host
<clever>
ornxka: the grub stuff is only for when /boot is encrypted
<ornxka>
ah yeah
<ornxka>
i dont have encrypted /boot
<bkv>
hey, can i make nix-shell use fish?
justanotheruser has joined #nixos
<cole-h>
`nix-shell -p package --run fish`?
<clever>
bkv: but youll loose all of the phase functions
erictapen has joined #nixos
<cole-h>
clever: Did the GDK_BACKEND stuff fix your issue with the file browser?
<etu>
bkv: I have a fish abbrev defined like this: abbr -a -U -- nsh 'nix-shell --run fish -p'
<clever>
cole-h: havent tried it yet
<bkv>
hmm
<etu>
bkv: Then I type "nsh " and can type package names
<clever>
cole-h: let me see...
<bkv>
yeah, i might do similar
<bkv>
doesn't fish inherit functions, on some level?
<clever>
bkv: i dont think functions can be inherited like that, for security reasons, and fish has a different syntax
<bkv>
hmm, ok
<cole-h>
The latter is the main reason
<bkv>
well, there's fenv
<bkv>
which basically makes fish completely compatible
<clever>
cole-h: nope, didnt help, it resets back to recent every time i open the dialog
<cole-h>
clever: RIP.
<cole-h>
It was too easy...
chpatrick has joined #nixos
<clever>
(Discord:6354): dconf-WARNING **: 14:03:40.905: failed to commit changes to dconf: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name ca.desrt.dconf was not provided by any .service files
<immae>
(like azerty instead of qwerty of things like that)
<ornxka>
ah, i only use qwerty
<immae>
ok
<immae>
you may try another keyboard, but I suspect it won’t solve anything
<ornxka>
one thing is, my setup is that i run boot.initrd.preLVMCommands = pkgs.lib.mkBefore "cat ${cfg.header} > /dev/ram0 ; cat ${cfg.image} > /dev/ram1;"; and then i set luks.devices to ram0 and ram1 for header and image respectively
<ornxka>
since for reasons beyond my comprehension, cryptsetup during boot only operates on block devices and not regular files
<ornxka>
(or it did when i initially set up that script)
<{^_^}>
[nixpkgs] @tobim closed pull request #76644 → nixUnstable, nixFlakes: update to current → https://git.io/JeN9B
<immae>
that’s outside of my competences sorry
<ornxka>
i thought that maybe ramdisk_size was too small but i set it to well over the size of both the header and the image
<ornxka>
the only thing i can think of is that my code is somehow not being run at the right time (but then, youd get an error when cryptsetup didnt find a proper header in ram0...)
<atemu12[m]>
ornxka: Make sure you set the LUKS devices to /dev/ram0, not ram0
<atemu12[m]>
ornxka: Happened to me once
<ornxka>
:p
<ornxka>
this exact script runs on the machine i am currently using
<ornxka>
which is of course working
<cole-h>
linarcx: You might be missing a path in XDG_DATA_DIRS.
<cole-h>
`XDG_DATA_DIRS=$XDG_DATA_DIRS${XDG_DATA_DIRS:+:}$HOME/.nix-profile/share` might clear that up.
<bkv>
it could introduce e.g. non reproducibility, though
<bkv>
i could build something, then build it again and it fails
<bkv>
can't guarantee idempotency anymore
<clever>
bkv: yeah, you cant control the side-effects, only that $out has a given hash when its done
<immae>
it could, but when it succeeds you know it’s the correct one
<bkv>
:p
<clever>
bkv: and the sandbox restricts where you can write to, so state can only persist on the network
<bkv>
ya
<cole-h>
linarcx: You should really read the Nix pills...
<bkv>
clever: by the way, if i did want to change the shell nix-shell uses, how would i?
<linarcx>
cole-h: Fixed!
<linarcx>
thanks.
<bkv>
wanna look into making it work properly if it doesn't already
bkv is now known as bqv
<cole-h>
btw, I meant to put that in front of your `nix-shell` invocation, not in your `shell.nix`.
<clever>
bkv: you would have to modify the nix-shell source, and possibly rewrite every single nix expression in nixpkgs
<atemu12[m]>
Is it possible to update an attrset with the attrset returned by a function? Nix says "value is a function while a set was expected" when I try to do `let func = _: {}; in {} // func`
<linarcx>
Hmm..
<clever>
atemu12[m]: you need to run the function first, and get the return value
<linarcx>
I put `export XDG_DATA_DIRS=$HOME/.nix-profile/share:/usr/local/share:/usr/share` inside shell.nix(shellHook). and now it's working like a charm.
<atemu12[m]>
clever: How do I do that?
<clever>
atemu12[m]: you could do `foo: {} // (func foo)`
<clever>
atemu12[m]: so you return a function, that will then run func, and then merge
<Cadey>
the NUR is broken for me, i have this in one of my configuration nix files: https://clbin.com/NtmgW but it's not letting me `nix-env -iA nur.repos.xe.ii`
<ornxka>
cpio --extract --make-directories --no-absolute-filenames --unconditional this gives me a tree of files substantially smaller than the original initrd
<ornxka>
where /mnt/boot is the mounted /boot filesystem
<Cadey>
how do i fix error: NUR import call didn't receive a pkgs argument, but the evaluation of NUR's xe repository requires it.?
<atemu12[m]>
clever: That evaluates to a lambda but I can't do anything with it. As soon as I try to evaluate a attribute of the merged attrset, I get the same error (though at a different position).
<clever>
ornxka: it might be that you have 2 initrd's concated together, one uncompressed, one compressed
<ornxka>
in grub.cfg it has as well initrd ($drive1)//kernels/vcvl19lq7lw0y81d7m44vp549ak39y1c-initrd-linux-5.5.9-initrd
<ornxka>
ahhh
<ornxka>
i guess i do need binwalk for this
<clever>
ornxka: linux can deal with the concating, but its tricky, since you have to parse it, and then re-parse with gunzip at an offset
<clever>
ornxka: yeah, binwalk is one good solution
pbogdan has quit [Ping timeout: 240 seconds]
<ornxka>
lol i try to install python3.pkgs.binwalk and it pulls in freaking wayland
<bqv>
lol
zupo has joined #nixos
<bqv>
Cadey: have you tried providing a pkgs argument? :p
<Cadey>
bqv: here is my ~/.config/nixpkgs/config.nix where I provide that pkgs argument: https://clbin.com/K6rye
<Cadey>
the weird part is that it works with `nix-shell -p` but not `nix-env -iA`
<bqv>
is that the right syntax for packageOverrides?
<Cadey>
for `nix-env -i nur.repos.xe.ii`: `error: selector 'nur.repos.xe.ii' matches no derivations`
<nschoe_>
Hey, quick question: I´ve added an image (wallpaper for lightdm greeter) to the nix store with `nix-store --add image.jpg`. It gave me the path. Perfect. But then I ran nix-collect-garbage --dry-run and it returned nothing: why doesn it list my newly-added file since it´s not used anywhere?
<atemu12[m]>
clever: I found out what's wrong, if you call a function without arguments it evaluates to a lambda, not an attrset. I wonder why Nix cares about the missing argument though because it isn't used and Nix is lazy
alexherbo2 has joined #nixos
drakonis has joined #nixos
<atemu12[m]>
`let func = x: {}; in {} // func ""` works as expected
<{^_^}>
[nixpkgs] @globin opened pull request #85092 → prometheus: use runCommandNoCCLocal for config gen → https://git.io/JvjlM
<Reisen>
Quick question, I'm not sure I fully understand expressions or how nix-env works with them. I managed to install Agda with `nixpkgs -iA nixpkgs.haskellPackages.Agda`, but not `haskellPackages.Agda` or even `Agda`, if I query with `nix-env -qa '.*Agda.*`, i can't find it there either, but `nix-env -q` lists it installed as `Agda-2.6.1`
<Reisen>
I've been running into this a lot lately, where project instructions don't have a specific enough expression to install until I hunt down the full path
<pie_>
how can i get a path relative to the build root so it still works in nix shell? i need something that wont change during multiple invocations in a build
<pie_>
so either i write scripts ro keep a state file, or theres something simpler i can do?
<morgrimm>
are there any good resources for good practice for system-specific derivations? for example, separate derivations, or just changing the build script per system, or?
<clever>
pie_: if you do ${toString ./.} youll get the absolute path of the dir the nix file is in
<pie_>
clever: not immediately clear to me that thats gonna work here but im thinking
<pie_>
clever: yeah no? this is for build time
zupo has joined #nixos
<pie_>
i need to set a home directory for xargo
<clever>
pie_: $NIX_BUILD_TOP ?
sonercirit[m] has joined #nixos
<pie_>
that might work i guess, what is that exactly?
<clever>
pie_: $NIX_BUILD_TOP is the temp dir nix made in /tmp for you
<clever>
pie_: and the build will begin with you cd'd into it
<sonercirit[m]>
hello, I was wondering if there was any other distro/os that you guys know with similar approach to nixOS's configuration based approach? Basically I should be able to regenerate the system from config. I already know about Guix.
<pie_>
in nix shell it gives me /run/user/1000 >_>
<clever>
pie_: NIX_BUILD_TOP is only set for nix-build, not nix-shell
<qyliss>
sonercirit[m]: NixOS and Guix are currently really the only two distributions in this category
<sonercirit[m]>
I was looking for something new to try, maybe I'll give Guix a go.
<pie_>
ok that make sense, i was hoping for something nice but thisis a start
<sonercirit[m]>
thx @qy
<sonercirit[m]>
* thx qyliss
ATuin has quit [Ping timeout: 260 seconds]
<qyliss>
yw :)
<pie_>
clever: though actually that fixes the temporary problem i just needed the shell for debugging
<deni>
anyone using gatttool or hcitool? it's my understanding this things got deprecated in favor of bluetoothctl and dbus api
<AmandaC>
If I've got a default.nix I'm building with `nix-build -E 'with import <nixos> { }; callPackage ./default.nix { }'` can I somehow get that imported into a nix-shell along with a normal "in-tree" nixpkgs package, such as asciinema?
<AmandaC>
clever: ... I feel like I'm missing something. I'm still getting the version of this package I have installed in `nix-env -i` of this program, not the newly-built one
<clever>
AmandaC: do you want the compiled default.nix or the env for building default.nix?
<AmandaC>
compiled
<clever>
AmandaC: ah, thats the reverse of what i gave
scheming_around has quit [Remote host closed the connection]
bqv has joined #nixos
shibboleth has quit [Quit: shibboleth]
reallymemorable has joined #nixos
ATuin has joined #nixos
jeromelanteri has quit [Quit: Leaving]
foldingcookie has joined #nixos
Thra11 has joined #nixos
<sshow>
michaelpj: yes, I had set autoUpgrade. Should that make it go back to its initial configuration?
bhipple has quit [Ping timeout: 240 seconds]
tarruda has joined #nixos
zeta_0 has joined #nixos
opthomasprime has joined #nixos
opthomasprime has quit [Remote host closed the connection]
zeta_0 has quit [Client Quit]
o1lo01ol1o has quit [Remote host closed the connection]
bhipple has joined #nixos
o1lo01ol1o has joined #nixos
<djanatyn>
i'm getting some issues with the terraform NixOS package - some modules i download are trying to call /bin/bash: Output: /bin/sh: .terraform/modules/org-terraform.project-factory/terraform-google-modules-terraform-google-project-factory-19ea6fe/modules/core_project_factory/scripts/modify-service-account.sh: /bin/bash: bad interpreter: No such file or directory
zeta_0 has joined #nixos
<djanatyn>
what would i need to do to allow the terraform package access to /bin/bash (is this similar to adding NixOS dependencies to ~/.stack/config.yaml?)
<djanatyn>
or is this an upstream module assuming that /bin/bash is on the path, which I'd need to fix?
o1lo01ol1o has quit [Remote host closed the connection]
o1lo01ol1o has joined #nixos
<gchristensen>
djanatyn: NixOS doesn't have a /bin/bash, probably should patch the provider to use an absolute path to bash
growpotkin has joined #nixos
<djanatyn>
gchristensen: thanks!
<numkem>
djanatyn: usually /usr/bin/env bash does the trick. /usr/bin/env is a useful friend with NixOS
inkbottle has joined #nixos
zebrag has quit [Ping timeout: 265 seconds]
<zeta_0>
i'm writing a shell.nix file, and this haskell-env attribute is not being recognized by the buildInputs function? https://dpaste.org/3eC4
<gchristensen>
yeah but in this case better to make it absolute, as the system may not have bash in the PATH
<bqv[m]>
well that was astonishingly dumb. i was trying to use emacs-26 packages with emacs-27
<bqv[m]>
no wonder nothing worked
<zeta_0>
looking at an example online, i appended: ++ buildInputs in the haskell-env implementation, but that did not work either?
<{^_^}>
[nixpkgs] @orivej-nixos pushed commit from @r-ryantm to master « zita-ajbridge: 0.8.2 -> 0.8.4 (#85012) »: https://git.io/JvjBl
<numkem>
bqv[m]: best solution I've found is to use the emacs overlay, the only downside is you end up building emacs from source once a day if you do a nix-build daily
<dsal>
Yeah, I'm looking at that. I've already got a working xmodmap so I'm trying to figure out how to fit that in here.
<zeta_0>
clever: i think so, i'm using nixos/nixpkgs 19.09, and did a nix-channel --update yesterday
stevenxl has joined #nixos
<clever>
zeta_0: the change likely isnt in 19.09, try unstable
<energizer>
dsal: do the instructions at the bottom make sense?
<zeta_0>
dsal: i have similar setup to what you are trying to do, i can help you after i finish fixing my shell.nix error, note: i'd recommend setting up home-manager 1st, if you haven't already
<{^_^}>
nix-community/emacs-overlay#23 (by andrea96, 1 day ago, open): `vterm` doesn't work
<dsal>
energizer: mostly. I'm still new enough that I didn't understand where the let went.
invra has quit [Quit: WeeChat 2.3]
<stevenxl>
Hi folks. I am running. I am running macOS Catalina 10.15.4, and trying to install nix. I run this from the shell "curl https://nixos.org/nix/install | sh".
<dsal>
*shrug* 15 years ago, /nix was weird on most systems I ran, many of which had read only root filesystems such that even root couldn't write there.
<manveru>
well, it can still be changed, you just have to give up on the existing binary cache
<gchristensen>
interesting, what OS's had a read-only / 15 years ago?
<manveru>
maybe netbooted ones?
<dsal>
manveru: I'm just barely trying nixos for the first time. I gave up on it on the mac a while before catalina made it a no-go just because requiring root access to try building was anon-starter.
<gchristensen>
aye
<clever>
manveru: if you move /nix on darwin, you also break the ability to deploy with nixops
<gchristensen>
well, here we are
<dsal>
gchristensen: Any that wanted them. I would typically make my root fileysstems read only and revoke root's ability to remount them as read-write without physical access.
<clever>
dsal: namespacing is very flexible, and you can change only the root and nothing else
<clever>
dsal: the FHS envs in nix do that, for things like steam
<dsal>
Ooh, I think I've almost got a useful nixos machine.
<energizer>
dsal: you're quick! took me hours the first time
<dsal>
My needs are tiny. heh
<dsal>
(and it's been a couple hours, yeah)
kreetx has quit [Ping timeout: 264 seconds]
<dsal>
Oh, I can just nix-install this from the external flash to the internal flash, right? Is there a faster way to effectively clone this system?
bqv has quit [Ping timeout: 265 seconds]
<clever>
dsal: if they use the same nixpkgs and config, it will just copy everything over
<dsal>
Oh nice. The test install wrecked my internal flash booting, so I could've just assumed it'd work out the first time.
bhipple has quit [Ping timeout: 240 seconds]
bqv has joined #nixos
<bqv[m]>
clever: heh, nice
<bqv[m]>
got nix-shell working well with any-nix-shell
morgrimm has quit [Ping timeout: 256 seconds]
<bqv[m]>
nothing is impossible
bhipple has joined #nixos
<{^_^}>
[nixpkgs] @Ericson2314 opened pull request #85101 → nixos/doc: Document breaking change to Haskell dev shells for 20.03 → https://git.io/JvjRc
<{^_^}>
[nixpkgs] @Ericson2314 merged pull request #85101 → nixos/doc: Document breaking change to Haskell dev shells for 20.03 → https://git.io/JvjRc
<{^_^}>
[nixpkgs] @Ericson2314 pushed 2 commits to release-20.03: https://git.io/JvjRC
<zeta_0>
well, if i can't get that error fixed, then i'll just wrap the entire haskell configuration with parenthesis and place it in buildInputs, that sucks, because then i'll have to change the environment variables in the shellHook as well
<michaelpj>
sshow: it's a bit unexpected with nixops, in that nixops doesn't copy the configuration *files* to the machine, so autoUpgrade upgrades on the basis of the configuration files on the machine, which isn't what you want
<michaelpj>
It would be great if there was an asset for that or something
<{^_^}>
[nixpkgs] @garbas opened pull request #85102 → vimPlugins: added branch support for update.py script → https://git.io/JvjRu
cosimone has quit [Quit: Quit.]
<bqv[m]>
hey, can someone try `ssh -vv git@github.com -o HostKeyAlgorithms=ssh-rsa`
<bqv[m]>
on my nixos systems, that seems to reliably fail
<bqv[m]>
oh, hang on, that doesn't do what i want
<bqv[m]>
nope, no idea how to reproduce this. figured out how to prevent it though
evertedsphere has quit [Ping timeout: 265 seconds]
<Taneb>
Decided to try and switch my desktop to 20.03
<drakonis>
its all fine at this point
<drakonis>
despite not being out yet
<drakonis>
i always track the latest release because eh why not
<sshow>
michaelpj: I see. So I should just turn autoUpdate off, then, and set up auto updating using nixops instead I guess
<sshow>
michaelpj++
<{^_^}>
michaelpj's karma got increased to 1
<Taneb>
Yeah, my desktop's not doing anything too weird
ggpeti[m] is now known as ggpeti[m]1
reallymemorable has quit [Quit: reallymemorable]
<michaelpj>
sshow: yeah, it's annoying and it would be nice if there was a way to do what you're trying to do there, i.e. have deployed, auto-updating systems, but I don't think there is currently. Arguably it's a bit at odds with the idea that nixops controls the state completely
<michaelpj>
and the current behaviour is a massive footgun obviously
<srk>
massive footgun!!! lol
<drakonis>
a foot cannon you mean?
<gchristensen>
ehhh yeah I keep meaning to PR my expression which breaks nixos-rebuild on nixops managed hosts
<cjpbirkbeck>
virtusviri7321[m: i was using ubuntu mate and i felt like i reached everything where was to learn there, so i was looking to switch and one guy in forum i was in was praising and recommending it, so i tried in a vm and liked, so i switched.
<srk>
Taneb: hehe :)) I'm pulling from master from time to time but unstable is better :)
vidbina_ has quit [Ping timeout: 250 seconds]
<cjpbirkbeck>
in any case, it's always good to test a distro in a vm before installing it on bare metal, as practice
noudle has quit []
morgrimm has joined #nixos
<virtusviri7321[m>
> virtusviri7321: give it a go, in a VM if you'd prefer :)
<virtusviri7321[m>
:) I do or on one of my spare laps
<{^_^}>
error: syntax error, unexpected ',', expecting ')', at (string):296:29
<virtusviri7321[m>
> in any case, it's always good to test a distro in a vm before installing it on bare metal, as practice
<virtusviri7321[m>
Cool thx for the tip
<{^_^}>
error: syntax error, unexpected IN, at (string):296:1
<bqv[m]>
unstable isn't even that unstable
<bqv[m]>
stable is too stable, if anything :p
<virtusviri7321[m>
Good to know your way. :)
<virtusviri7321[m>
> virtusviri7321: i was using ubuntu mate and i felt like i reached everything where was to learn there, so i was looking to switch and one guy in forum i was in was praising and recommending it, so i tried in a vm and liked, so i switched.
<{^_^}>
error: syntax error, unexpected ',', expecting ')', at (string):296:102
morgrimm has quit [Ping timeout: 250 seconds]
<zeta_0>
for this shell.nix file, i wrapped my haskell setup and placed it directly in buildInputs, and now it seems to work(it's still building in nix-shell): https://dpaste.org/TQ8c
<zeta_0>
but i'm going to have to change the environment variables as well
<sshow>
How can I inject the `config` variable to `nix repl` ?
<zeta_0>
i think i'm going to have to do a garbage collection soon, this nix-shell setup is dumping a lot
<energizer>
sshow: `nix repl '<nixpkgs>' ` has config in it
<bqv[m]>
sshow: `nix repl '<nixpkgs/nixos>'` should have the config you're expecting, i think
<sshow>
energizer++ bqv[m]++
<{^_^}>
bqv[m]'s karma got increased to 5, energizer's karma got increased to 6
<sshow>
What about `services`?
<clever>
sshow: config.services
hoplaahei has joined #nixos
<sshow>
orly! clever++
<{^_^}>
clever's karma got increased to 389
<hoplaahei>
hi again. Is it safe to purge zfs snapshots made by the autosnapshot service I don't need anymore because they take up too much? Or will that break the script?
<clever>
hoplaahei: totally safe
nschoe_ has quit [Ping timeout: 256 seconds]
evsph has quit [Quit: Connection closed for inactivity]
<gchristensen>
hoplaahei: are you sendig those snapshots anywhere?
orivej has quit [Ping timeout: 265 seconds]
<hoplaahei>
clever: thanks.
<hoplaahei>
gchristensen: I haven't thought that far ahead, but no, I don't think so.
bhipple has quit [Ping timeout: 240 seconds]
ratsclub has joined #nixos
<ratsclub>
Hello, guys
<ratsclub>
How are you doing?
<bqv[m]>
the activation scripts don't happen to have a verbose switch do they?
<bqv[m]>
they take so long to run on one of my systems, i want to know why
bhipple has joined #nixos
<ratsclub>
Guys, I'm having a small trouble with venvShellHook: error: attribute 'venvShellHook' missing
<dsal>
Following installation instructions, I get complaints about swap being not properly aligned. Is there an easy way to DWIM this?
<hoplaahei>
Also, I created a dataset for my .steam directory in home because the files are too large for it to get snapshotted. I intend to move the files back with rsync -aAX to preserve attrs and ACLs. I assume/hope it won't get snapshotted unless I explicitly make it a child of the home dataset I am already snapshotting or give it an autosnaphot flag? Also, can I just run nixos-generate-config before reboot, or are there any other steps to get the volume to
<hoplaahei>
mount next boot?
<ratsclub>
But I can't get venvShellHook to work
orivej has joined #nixos
<energizer>
dsal: gdisk is easier if you specify the size instead of the endpoints
<dsal>
I just used GB instead of GiB. *shrug* I'll just lose a bit of space.
<philipp[m]>
How do I get the behaviour of `home.file` (in home manager), but with the file being interpreted by nix?
<ratsclub>
I got it working, it's only on unstable
__init__ has joined #nixos
invra has joined #nixos
<__init__>
hello, have any of you set up a wireguard vpn lately? perhaps ideally/specifically with mullvad?
ratsclub has left #nixos ["ERC (IRC client for Emacs 26.3)"]
<zeta_0>
i don't want to stay stuck waiting hours for nix to build this environment over and over again
<__init__>
I'm having trouble figuring out how to debug wireguard when I don't control the server, like with hosted VPNs. when I enable the interface in systemd te connection just stops working. :)
knupfer has quit [Ping timeout: 260 seconds]
<__init__>
how should I figure out what's going wrong? like isolate it to the keys, IPs, or routes?
<bqv[m]>
that's above my pay grade
<bqv[m]>
zeta_0: it can't cache anything if you don't give fetchtarball a hash
<__init__>
they supply some premade configuration but I can't make it work with the one generated by nixos :(
<sshow>
Is there some sort of spread operator to do something like this: `allowedPorts = [ 80 ...config.services.openssh.ports ]`
<monokrome>
Does anyone know if there's a way to recover the latest configuration.nix? My swap file was apparently full, so `sudo -e` apparently overwrite it with an empty file...
<monokrome>
TIL that can happen
<bqv[m]>
:D
<zeta_0>
oh, and does nix-shell use cachix? if not, i will be waiting for days
<bqv[m]>
this is why i make my configuration part of the system
<monokrome>
isn't it already?
Desetude has joined #nixos
<bqv[m]>
nope!
vidbina_ has joined #nixos
<bqv[m]>
there is a system.copyNixConfiguration option
<bqv[m]>
or something like that
<energizer>
sshow: [80] + ports
<bqv[m]>
it's off by default (and doesn't work with flakes anyway)
<energizer>
sshow: maybe there's fancy syntax idk
densecomet has joined #nixos
<energizer>
sshow: er, ++
<zeta_0>
evils: thanks for the link, i'll try that out
<sshow>
energizer: okay. makes sense. so I could do like this: `mylist = mylist ++ [ 80 ]`
<energizer>
sshow: yes
<sshow>
energizer: and this is the only syntax that you're aware of?
<monokrome>
well crap
<monokrome>
this is not gr8
<clever>
sshow: nixos options append lists automatically for you
aditsachde has joined #nixos
<monokrome>
sudo is broken AF
<sshow>
clever: okay, so I could go full on `networking.firewall.allowedTCPPorts = services.openssh.ports` ?
<sshow>
and it will simply be appended?
<clever>
sshow: ssh opens its own ports for you, so thats the one thing you dont need
<sshow>
clever: lol. okay. but apart from that
<gchristensen>
bqv[m], monokrome: that option doesn't really work anyway
<sshow>
energizer++ clever++
<{^_^}>
clever's karma got increased to 390, energizer's karma got increased to 7
<clever>
sshow: yeah
<gchristensen>
monokrome: ouch :(
captjakk has quit [Remote host closed the connection]
ggpeti[m]1 is now known as ggpeti[m]2
<Desetude>
Are commits selectively moved into unstable from master or is a full catch-up done from master to unstable every couple of days?
captjakk has joined #nixos
<Desetude>
(in nixpkgs)
<gchristensen>
Desetude: unstable points to a commit in master
<philipp[m]>
monokrome: Your files might not be completely lost. Iirc, sudoedit should first create a temporary backup file somewhere. Have you checked that?
<dsal>
I can't do a rebuild on my new system. :( Says it can't find nixpkgs
<dsal>
nixpkgs/nixos was not found in the Nix search path. Can I recover this?
<monokrome>
So, I can just copy over my laptop's config and update the passwdHash, but is there a way to get the systemVersion so that I don't mess it up?
<dsal>
`nix-channel --update` fixed my problem.
<dsal>
So I guess two things went wrong when I moved my installation to another disk. The other thing is that it kept my old (external) swap.
dsiypl4 has joined #nixos
bhipple has quit [Ping timeout: 240 seconds]
<energizer>
monokrome: you just want to find out what the current stateVersion is?
<virtusviri7321[m>
> monokrome: the steam in nixpkgs, is trying to simulate a debian system in a chroot
<virtusviri7321[m>
Ah cool
<{^_^}>
error: syntax error, unexpected IN, expecting ')', at (string):296:22
<monokrome>
lol wild
<lukegb>
steamos is... still being updated, ish. It got an update 8 months ago, at least
<lukegb>
iirc steamos 3 was supposed to be stretch-based, but it's not out yet
<monokrome>
I copied the config on my laptop, got the error "You must set the option ‘boot.loader.grub.devices’ or 'boot.loader.grub.mirroredBoots' to make the system bootablet" and now it seems that after I set that value, I get that error anyway =^.^=
<monokrome>
whoa how did that copy so bad
<clever>
monokrome: which file did you set that in?
<monokrome>
/etc/nixos/configuration.nix
<virtusviri7321[m>
Thx for your help up to now :)
<monokrome>
the hardware-configuration.nix is still in tact from where it was before
<clever>
monokrome: is it already installed, or running from the installer iso?
<monokrome>
not even sure why I need to set this
<monokrome>
clever: Already installed, but a bug in sudo led me to erase my configuration.nix so I had to pull the configuration.nix from my laptop
<clever>
monokrome: ah, and you now have boot.loader.grub.device(s) set in the new configuration.nix?
<monokrome>
yeah, but it's not there on my laptop
<monokrome>
so I'm surprised to see the error
<monokrome>
maybe it's safer to just redo my system :/
<clever>
monokrome: there are other options
<clever>
monokrome: first, do you know if it boots with efi or legacy?
<monokrome>
EFI
<monokrome>
w/ cryptodisk
<clever>
monokrome: then you want boot.loader.grub.device = [ "nodev" ];
<clever>
monokrome: next, what does `nix-store -q --deriver /run/current-system` say?
<clever>
monokrome: now try `nix-diff /nix/store/5ywfdxcg4arbxc7fb32gfxwv02bg76ip-nixos-system-peru.home.monokro.me-19.09.2395.02f2241354a.drv $(nix-instantiate '<nixpkgs/nixos>' -A system)`
<monokrome>
seems to be a bash script
<clever>
monokrome: that will show you the difference between your currently running os, and the current configuration.nix
<clever>
then you just edit configuration.nix to remove differences, and repeat the nix-diff
<clever>
monokrome: weird, try updating the nix-diff cmd
<monokrome>
tried, now it ran but I got the same error: warning: you did not specify '--add-root'; the result might be removed by the garbage collector
<clever>
monokrome: thats normal, does it actually show a diff?
<monokrome>
nope
__monty__ has quit [Quit: leaving]
<monokrome>
that warning is all I get
<bqv[m]>
that's a warning, not an error, btw
<clever>
monokrome: did you do nixos-rebuild at any point?
<bqv[m]>
it says it on the tin
<monokrome>
thanks bqv[m]
<monokrome>
clever: not since you started giving me nix-diff commands, but I did do it after setting device = [ "nodev" ]
<monokrome>
which would explain why there's no diff, they're maybe the same now
<Desetude>
In my path there is an objdump from binutils and one from go tools, is there a nice way to have the binutils binary have precedence?
<zeta_0>
is: export HIE_HOOGLE_DATABASE="$(which hoogle)" correct for a shellHook?
maddo has quit [Quit: See ya]
<clever>
zeta_0: try running it inside nix-shell and see if it makes any difference
<zeta_0>
i may need swap () with {}
<zeta_0>
clever: ok, i'll test it out in a nix-shell
<zeta_0>
clever: this: `HIE_HOOGLE_DATABASE = "$(cat $(which hoogle) | sed -n -e 's|.*--database \\(.*\\.hoo\\).*|\\1|p')";` , is the env var that you helped me set a long time ago in home.nix, and this: export HIE_HOOGLE_DATABASE="${haskell-env}/share/doc/hoogle/default.hoo" , is the env var shown in the instructions that i'm following: https://github.com/ysndr/blog/blob/a62763de64a127ba861b88a981a2416c3b9a5b77/default.nix
<zeta_0>
#L56-L74
<zeta_0>
clever: i've made some progress with this shell-nix, it doesn't throw anymore errors when i run it in a nix-shell(though i canceled the build because it was taking too long): https://dpaste.org/Mwvy
dermetfan has quit [Ping timeout: 260 seconds]
<zeta_0>
i commented out the shellHook while building in the nix-shell, so i'm fixing them now
erictapen has quit [Ping timeout: 240 seconds]
snicket has quit [Ping timeout: 240 seconds]
<zeta_0>
the other env vars look fine, it's this HIE_HOOGLE_DATABASE env var that's holding me back
erictapen has joined #nixos
<hoplaahei>
Lutris is saying it can't detect Vulkan support. I have tried to configure it in configuration.nix: https://pastebin.com/pe25CRK8
<hoplaahei>
Do I need amdgpu-pro driver? I have open amdgpu only at the moment.
Desetude has quit [Quit: WeeChat 2.8]
<hoplaahei>
Vega 11 onboard graphics of the Ryzen 5 3400G.
<monokrome>
this is wild
<monokrome>
now it rebuilds but when I reboot it retains my old config instead of using the new one
<monokrome>
I think it maybe installed a separate grub
<monokrome>
but also apps are disappearing because my root disk is full somehow
<dsal>
Hmm... My stack project won't build because it's using a package that requires zlib, and can't find zlib.h
ZaraChimera has joined #nixos
<bqv[m]>
iirc, there's a difference between zlib and ZLIB
reallymemorable has quit [Quit: reallymemorable]
hoplaahei has quit [Quit: Konversation terminated!]
<codygman__>
dsal: What does your nix block of your stack.yaml look like? Do you have zlib listed?
<dsal>
My stack.yaml doesn't know anything about nix. I'm just trying to build an existing project.
<energizer>
dsal: you might wanna check out snack or some of the other tools
xO1 has quit [Ping timeout: 256 seconds]
<dsal>
snack? I just want to develop software on this machine. :)
<codygman__>
dsal: If you are building on nixos stack uses nix integration by default and you'll need to add zlib or maybe disabling nix integration will work... not sure. See here: https://docs.haskellstack.org/en/stable/nix_integration/
<dsal>
Thanks. I think nixos suits me well as a system, but I need to build this on other systems as well.
<codygman__>
"it's not going to be usable as a build system." Do you mean like cabal is a build system, stack is a package set + some other stuff over cabal build system, and nix alone isn't a build system? Most people use cabal+nix to for the case you mean I think.
<dsal>
codygman__: I mean if nix is required to build my software, then I've failed myself, since I can't use nix everywhere I use the software I work on.
<codygman__>
dsal: Oh, so it's just a political thing where only stack is guaranteed on your systems then.
<codygman__>
Anyway, your project's working now and I don't want to monopolize your time :D
<dsal>
It's also a technical thing where nix can't work on some of the systems I use and I guess semi-political to demand a random contributor to do stuff that requires root access to build my thing.
<dsal>
But yeah. So far I like nixos. :)
mbrgm_ has joined #nixos
<codygman__>
If you can when you have time, please detail the technical parts that keep you from using nix everywhere as they would be of great interest to many of us I think.
<simpson>
codygman__: It's a simple case of why we can't have nice things: Because not everybody is able to receive the nice things.
<dsal>
You can't write a new directory to the root filesystem without both root access and a writable root filesystem. These things aren't always reasonable requests.
mbrgm has quit [Ping timeout: 256 seconds]
mbrgm_ is now known as mbrgm
<simpson>
dsal: You may find that you don't need to change any of your build process, but merely add a default.nix and shell.nix to your project root.
<dsal>
I still don't know what those two files do. :(
<simpson>
Do not think that, merely because you and your contributors type different commands, that you therefore are using distinct build processes. It is reasonable and common for Nix-driven builds to be on top of, and not replacing, existing build tools.
<dsal>
I tried that home-manager recommendation which is neat so far.
<dsal>
I'm not opposed to using nix as part of my build process as long as my build process still works without nix. My main machine can't even run nix and I can't do anything about that.
jgeerds has quit [Ping timeout: 265 seconds]
<codygman__>
I empathize with you if you simply can't install nix package manager on those systems because you don't have root access and can't get it approved at $work.
<dsal>
Yeah, I *technically* could on my work machine, but the security people would be asking me questions before the build finished.
<energizer>
codygman__: most people don't have nix installed, forcing everyone to use nix is implausible
invra has joined #nixos
<energizer>
dsal: there are answers to the security questions
<simpson>
codygman__: We will not support every proprietary kernel and userland; we can't. I gather that the problem here is one of a proprietary OS.
<codygman__>
simpson Right, I wasn't expecting that of anyone. I didn't conclude it was a proprietary OS, just that there was a security team who wouldn't like `/nix` getting populated.
<MichaelRaskin>
We don't even support all BSDs, and those that kind of work have limited coverage.
<dsal>
Proprietary OS is just one of the problems.
<energizer>
dsal: anyway, the idea is default.nix describes how nix should build a package. often it can be quite short, inferring the relevant information from the language-specific lockfiles in the directory. shell.nix imports default.nix and creates a system shell that provides access to the built package
<dsal>
Different things, though. I like nixos so far. It'd be kind of neat if I could use this stuff elsewhere, but I'm OK when in Rome.
m0rphism has quit [Ping timeout: 256 seconds]
<codygman__>
energizer Everyone didn't have python or perl on their systems at one time. If something provides enough value and gains enough adoption, you can expect everyone your software targets to reasonably have nix. I think you get there by showing developers how they can develop more reliably with nix while not breaking their current distribution method
<codygman__>
(stack here), then over time they might recommend nix over stack for instance because it's more reliable.
<dsal>
energizer: I'm still in massive absorption phase. Is there a good overview?
<dsal>
codygman__: when I didn't have python or perl, I installed them as my own user in my home directory.
<MichaelRaskin>
You actually can have Nix with the store in your ~ (but then you rebuild the world)
<dsal>
I have homebrew installed as my own user in my home directory on my mac, because I don't own /usr/local
<simpson>
codygman__: That is too much work. Instead, make things which work for you, and design the things that you make to be generic.
<energizer>
dsal: unfortunately the documentation is spread out across three manuals (nix, nixos, nixpkgs) and various third party repositories
<simpson>
codygman__: "We do not influence the course of events by persuading people that we are right when we make what they regard as radical proposals. Rather, we exert influence by keeping options available when something has to be done at a time of crisis." http://www.erights.org/
<zeta_0>
does anyone know a good link to shellHook nix documentation, the nix manual only shows one example of it, it's syntax is different then the sessionVariables option in home.nix, so that's confusing me
<cole-h>
Isn't shellHook just bash script?
<dsal>
There's kind of a baby/bathwater thing here, though. You built a system that has a lot of amazing properties, and then hardcoded a value into that causes it to not be universally applicable. I don't think "value must be hardcoded" is really that critical to such a system.
<MichaelRaskin>
dsal: if you want to have shared binary cache, you have to hardcode _some_ value
<energizer>
dsal: but basically: when working on a project, make a default.nix and a shell.nix that imports default.nix (https://nixos.wiki/wiki/Development_environment_with_nix-shell) and then run nix-shell or use lorri to activate an environment that has the package set up
<MichaelRaskin>
If you don't, you can run Nix with non-default store path
<dsal>
energizer: thanks. I'll look into that some.
<simpson>
dsal: The hardcoded value being "/nix"? What else would you set it to?
erictapen has quit [Ping timeout: 256 seconds]
<codygman__>
dsal: re: overview. I bet you'll get recommended the manual for Haskell packages and there is value there, but it alone didn't get me where I needed to be since I had many custom packages that required various workarounds for work. Try this reading this https://discourse.nixos.org/t/nix-haskell-development-2020/6170 and then try using this template
<dsal>
simpson: Well, $NIX ? Something with a slightly later binding that could be runtime relocated.
<lukegb>
So, out of interest and for my own curiosity: the latest build for nixos:trunk-combined:tested failed https://hydra.nixos.org/build/116575957 but it's not obvious why - is it just a cached build flake?
<energizer>
dsal: various languages have tools that can be used in default.nix to get dependencies etc. naersk (rust) poetry2nix (python) , snack (haskell),
<MichaelRaskin>
dsal: relocations do not work
<simpson>
dsal: Sure, for consenting software. But not for the typical pile of C that folks seem to rely upon.
<MichaelRaskin>
You _can_ set a few environment variables listed in the bottom of man nix-store and _build_ for a relocated path
LysergicDreams has quit [Ping timeout: 265 seconds]
<simpson>
Nix is transitional. In a world with better languages, better modularity, and better understanding of structures, we wouldn't need it; *all* software already would be far past this point. But that is another timeline, not ours.
<dsal>
:)
<dsal>
In the meantime, I'm going to enjoy nixos on my new build. It does seem mostly right.
<energizer>
simpson: that said, does it really need to be built out of duct tape and bash
LysergicDreams has joined #nixos
<MichaelRaskin>
dsal: I have at some point run a non-standard Nix store path for cross-compiling to a e-Book and this worked
<{^_^}>
[nixpkgs] @marsam opened pull request #85110 → rsstail: enable on darwin → https://git.io/Jvjzj
<MichaelRaskin>
After a lot of building stuff from scratch…
<codygman__>
simpson: re: erights... Big caveat that's my first time hearing that or thinking about it. My kneejerk reaction is that sounds good and I'd like it to be true, but per my mental model of the world that's not actually going to result in adoption of nix or any other solution that much. It very much sounds like "if you build it they will come".
<simpson>
codygman__: No, "if you build it, and make cool stuff, and make them jealous, then they will come"
<simpson>
"and be upset because they don't understand, and so forth"
<MichaelRaskin>
Not really that.
bdju has quit [Read error: Connection reset by peer]
bdju has joined #nixos
<MichaelRaskin>
You convince enough people that someone uses the fitting hobby tool in a «you want me to hit the deadline — then shut up» situation…
<MichaelRaskin>
(afterwards nobody ever has time to replace that part and …)
zeta_0 has quit [Quit: rcirc on GNU Emacs 26.3]
<codygman__>
simpson: I find in that situation you'll get some people to join you, but many others rationalize their current solution is better or it's otherwise not worth even trying to adopt $betterSolutionForTheirUseCase". I have to head off for now though, will check back for any responses later though. Thanks for the discussion.