alexteves has quit [Remote host closed the connection]
NightTrain has quit [Ping timeout: 246 seconds]
<chreekat>
elvishjerricco: there is, but once created, you can't resize it with nixops. With that caveat, it's deployment.ec2.blockDeviceMapping."/dev/xvdf"= { fsType = "swap"; size = <..>, ..., };. That's the best I came up with, at any rate. Note that /dev/xvdf was basically random, and had to be synced with the logical description of the machine (I defined it in a variable in a shared.nix that both descriptions
<chreekat>
import). The logical description has <box>.swapDevices = [ { device = "/dev/xvdf"; size = <..>; })];
<chreekat>
Probably I don't need to specify the size in the logical description, hm
<elvishjerricco>
chreekat: Nice. Maybe `swapDevices` makes more sense to put in a physical description anyway?
<chreekat>
Anyway, this does seem a bit janky. I also don't understand why nixops requires two distinct nix files, rather than just two distint expressions
<chreekat>
I agree, and I recall thinking, "I ought to fix this"
<chreekat>
and then, well
pie_ has quit [Ping timeout: 272 seconds]
<elvishjerricco>
chreekat: It doesn't *require* any number of files. The deployment is based on a naive merge of the logical and physical files. It can be 1, 2, or 1000
<chreekat>
:o
<elvishjerricco>
Yea the clever merging is in the NixOS module system, which isn't used for the top level files of nixops like it really ought to be.
<`_>
In our setup we do all the merging ourselves and specify one file
<chreekat>
How, though? Don't I specify identically-named attributes in the two files, one for the logical description and one for the physical?
<{^_^}>
[nixpkgs] @peti pushed to haskell-updates « hackage-packages.nix: automatic Haskell package set update »: https://git.io/fAGvF
<elvishjerricco>
So nixops just gathers the files and zips them together, then takes the lists and evalModules them
<elvishjerricco>
chreekat: You can specify those attributes in either file
thc202 has quit [Ping timeout: 252 seconds]
<chreekat>
So what does it mean to merge to attribute sets when they both have a function with the same name?
<chreekat>
*two attribute sets
<elvishjerricco>
chreekat: Are you familiar with the NixOS module system and how it can merge modules?
<chreekat>
I am probably familiar with parts of it, though clearly not this part :)
<elvishjerricco>
chreekat: NixOps is one top level layer above a bunch of NixOS modules. Basically, a NixOps file (physical or logical) would have type `Map String NixOSModule`, where there exists a function, loosely, `evalModules :: [NixOSModule] -> NixOSConfig`. The keys in that map are the machine names, and NixOps basically represents a function `[Map String NixOSModule] -> Map String NixOSConfig`, which calls `evalModules` on all
<elvishjerricco>
the entries of the map with the same name.
<elvishjerricco>
This is ignoring a few special case top level attrs like `resources` and `network`
<elvishjerricco>
`evalModules` is very smart; it can implement very complex merge strategies. But the NixOps function is not very smart; it's just delegating to `evalModules` and hoping you don't need much sophistication at the top level
carlosdagos has joined #nixos
Lisanna has quit [Quit: Lisanna]
b has joined #nixos
<chreekat>
So the NixOSConfig:s are monoidal in some way, I take it? `nixops = foldr1 (unionWith <>) . fmap evalModule` ?
<chreekat>
± some extra maps and fmaps
<emily>
oh how I wish that much rich typing were involved
<chreekat>
hehe
<{^_^}>
[nixpkgs] @johannesloetzsch opened pull request #45725 → vim-fireplace: init at 2018-06-01 → https://git.io/fAGfi
<emily>
but yeah, it's semigroups
<infinisil>
chreekat: elvishjerricco: Actually, nixops is more like `[String -> (Map String NixOSConfig -> NixOSConfig)] -> Map String NixOSConfig`
<infinisil>
Because you can have the configs depend on other machines configs
<infinisil>
(but it's very inefficient..)
<chreekat>
Add this to the pile of things that could use some better docs :)
<chreekat>
Has anyone floated the idea of docstrings/pydocs/haddocks for Nix, incidentally?
dmc has quit [Quit: WeeChat 2.2]
dmc has joined #nixos
stallion has joined #nixos
jperras has joined #nixos
<elvishjerricco>
It's hard to do since Nix doesn't really have a top level structure to files.
<elvishjerricco>
The NixOS module system is fairly well documented itself, and facilitates really good self documentation. I'd love to see more things done via the module system.
<elvishjerricco>
Maybe a slightly altered version of it; it's got its warts. But it's great overall
<elvishjerricco>
You can use it for more than just NixOS. I've used it to describe haskell projects. Makes things nice and composable
stallion has left #nixos [#nixos]
<chreekat>
That's good to know. I probably stopped because I "wasn't building OS modules"
<chreekat>
*stopped reading
<chreekat>
I'm soon going to be trying to figure out how best to package a haskell app for deployment on a server that has Nix but not NixOS. I guess reading about modules will be helpful? I know I want to figure out how to install and activate systemd units, but not sure what the solution will look like yet
<chreekat>
Excellent! It is not immediately apparent to me how the module system could be used for that, so I'd be curious to see more details
redj has joined #nixos
sorear has joined #nixos
mingc has quit [*.net *.split]
cocreature has quit [*.net *.split]
andi- has quit [*.net *.split]
dhess has quit [*.net *.split]
linuxdaemon has quit [*.net *.split]
dgpratt has quit [*.net *.split]
dukedave has quit [*.net *.split]
kandinski has quit [*.net *.split]
bmpvieira has quit [*.net *.split]
akaWolf has quit [*.net *.split]
AstroBadger has quit [*.net *.split]
mikeplus64 has quit [*.net *.split]
mdash has quit [*.net *.split]
DenialAdams has joined #nixos
<DenialAdams>
hi all, i'm new and have a couple of questions. 1) When to use nix-env versus modifying the system configuration? For all intents and purposes this is a single user machine (my desktop)
<DenialAdams>
2) Is there an easy way to uninstall all packages from a profile? (revert to system state)
<elvishjerricco>
DenialAdams: I pretty much always use the system configuration, unless I'm just messing around with something quickly and don't want to bother editing a file (but `nix run` is usually better in that case anyway)
andi- has joined #nixos
ilikeheaps has quit [Ping timeout: 240 seconds]
<clever>
DenialAdams: nix-env -e
<chreekat>
I need to start using 'nix`
cocreature has joined #nixos
AstroBadger has joined #nixos
<elvishjerricco>
nix-env -e '.*' will remove everything.
* clever
heads off to bed
<DenialAdams>
Thanks elvishjerricco and clever! Much appreciated :) nix-env -e '.*' doesn't seem to do anything for me though
<DenialAdams>
good night clever, thanks again
<elvishjerricco>
Then the man page is outdated :P
<DenialAdams>
Yes, I tried that after reading the help before you guys mentioned it and it didn't seem to work >.>
<elvishjerricco>
Odd. You could use `--set` to set it to an empty environment, but I don't know how to do that
<DenialAdams>
I'll poke around. Perhaps something is wrong with my configuration, not the help
Supersonic has quit [Ping timeout: 272 seconds]
mayhewluke has quit [Ping timeout: 240 seconds]
Supersonic has joined #nixos
mayhewluke has joined #nixos
Lears has quit [Remote host closed the connection]
linuxdaemon has joined #nixos
silver has quit [Read error: Connection reset by peer]
<disasm>
is it possible to do a `nix-store --realise` for a different architecture?
<DenialAdams>
nix-env -e '.*' worked when I sudo-ed it, maybe i was confused and had installed the packages with sudo. Thanks again elvishjerricco
<disasm>
to pull it from cache that is
<elvishjerricco>
disasm: `.drv` files are host independent. You can take a `.drv` from a darwin machine, put it on a linux machine, and `nix-store --realise` it. Nix will just check substituters and remote builders for the output, and if it finds none, then it'll complain that the host is the wrong architecture to build the `.drv`
<elvishjerricco>
I guess "host independent" isn't the right way to word that. A `.drv` encodes its own host, and Nix will respect that
Drakonis has joined #nixos
dmj` has joined #nixos
<{^_^}>
[nixos-artwork] @samueldr merged pull request #32 → grub2-installer: makes it even better → https://git.io/fN51M
<{^_^}>
[nixos-artwork] @samueldr pushed 4 commits to master: https://git.io/fAGks
jperras has quit [Ping timeout: 240 seconds]
jperras has joined #nixos
<disasm>
elvishjerricco: ah, so it's the level above that, can I pass an arch to `nix-instantiate` to force it to generate a drv for darwin?
<elvishjerricco>
disasm: With nixpkgs it's easy: `nix-instantiate "<nixpkgs>" --argstr system x86_64-darwin -A hello`
<elvishjerricco>
Other nix code will have to provide some way of passing the `system` argument to `import <nixpkgs>`
<disasm>
ah, so argstr system, that's already in default.nix
<ldlework>
infinisil: I'm adding overlays/default.nix to my host's imports
<infinisil>
ldlework: You didn't mess up the self: super: order anywhere relevant? Because it's messed up in line 42
<ldlework>
infinisil: just checked
<ldlework>
all the other self: super: are correct
<ldlework>
I only have a couple overlays so far
<ldlework>
and fixing that one didn't fix it
<ldlework>
but i guess it wouldn't since those vars wernt being used
<ldlework>
infinisil: do you at least see from the code what I'm trying to do?
<ldlework>
like with the unstable overlays
<ldlework>
its just like your system for modules, but for overlays
<infinisil>
Yeah, can't see anything wrong with it
<ldlework>
with support for a pinned unstable overlay
<infinisil>
Try not using pkgs
<ldlework>
hmm fetchFromGithub for the unstable pin
<ldlework>
oh
<ldlework>
I need to use super
* ekleog
would guess for a loop using the self: overlay
<infinisil>
I'd guess that you accidentally passed the pkgs argument at the top
<hyper_ch>
LnL: I don't understand your comment to the PR as the PR only updates Plex...... I fail to see what this has to do with plex pass
<infinisil>
ldlework: Oh, that's a NixOS module? Yeah that won't work
<ldlework>
What?
<infinisil>
You're using pkgs, while the result is dependent on pkgs
<infinisil>
You're assigning nixpkgs.overlays
<infinisil>
which will influence the pkgs argument at the top
<ldlework>
right where am I using pkgs though
<ldlework>
just fetchFromGithub?
<infinisil>
ye
<ekleog>
you can simply s/pkgs/(import <nixpkgs> {})/
<ldlework>
that can use super
<ekleog>
it's not using self or super, it's using the pkgs argument of the module system, which is independent from overlays :)
<ekleog>
and which depends on nixpkgs.overlays, which you set below depending on the value of the pkgs argument
<infinisil>
ldlework: Yeah super should work
<ldlework>
oh tons of stuff uses lib though
<infinisil>
Or the import <nixpkgs> {} suggestion by ekleog would work too
<infinisil>
ldlework: import <nixpkgs/lib>
<{^_^}>
[nixpkgs] @Enzime opened pull request #45729 → compton, compton-git: Merge derivations and update version → https://git.io/fAGLW
<ekleog>
infinisil: there's no super in their module :°
<ekleog>
ldlework: lib doesn't depend on nixpkgs.overlays, so there's no issue :)
<ldlework>
oh I think i got further than before
<infinisil>
ekleog: The super from line 42, can be used in the definition of unstable-nixpkgs (after inlining)
<ldlework>
yeah
<ldlework>
that's what I did
<ekleog>
oh, indeed :)
<ldlework>
I inlined it
<infinisil>
ekleog: But pkgs.lib does depend on nixpkgs.overlays
<ldlework>
it works!
<ldlework>
well maybe
<ekleog>
oh good point :)
<ldlework>
lol
* ekleog
thinks that's yet another issue with the module system, everything being conflated in a single fix point makes infinite recursion way too likely
<ldlework>
probably to check there are no duplicates or something
<ekleog>
now that's tricky
<ldlework>
blind guess :D
<ekleog>
it likely depends on the implemntaiton details
<samueldr>
oh no
<ekleog>
either nix forces the hashmap keys first then tries matching, or nix first attempts known keys, and if it doesn't find it it forces the remaining ones
<ldlework>
the latter would be too clever
<ekleog>
I'd guess the first option is the simplest thus the one done, and so it'd error, but… :°
<ekleog>
here it completely could have been not-strict
<ekleog>
s/not-strict/lazy/ actually
<infinisil>
ekleog: I think what ldlework mentioned, that it can't have duplicates, prevents that
<c15ade4>
is there any good intro to adding a package to nixpkgs that supports automatic updating?
argo has joined #nixos
<ldlework>
automatic updating?!
<c15ade4>
yes
<ldlework>
is that even a thing
<c15ade4>
there are scripts in nixpkgs that seem to check urls and update hashes
<ldlework>
woah
<ldlework>
doesn't sound very reproducable!
devopsdeluxe has quit [Quit: ZNC 1.7.1 - https://znc.in]
hlolli has quit [Ping timeout: 246 seconds]
<ekleog>
ldlework: that's a script that's designed to be run from time to time and only updates nixpkgs, the result then has to be committed and pushed
<ekleog>
(then, there are things like mozilla's rust-overlay that is actually non-reproducible, but that's a different matter, based on builtins.fetchurl without the hash arguments)
amir has joined #nixos
<infinisil>
ekleog: ldlework: I'll post another nix quiz in #nix-lang if you join :P
<ldlework>
tsk tsk
<ekleog>
oh, there's a #nix-lang?
<infinisil>
Not too active, rather new
<c15ade4>
ldlework: even updating nixpkgs by hand is not reproducible
mog has joined #nixos
<c15ade4>
someone has to login, check a page, save the hashes
<c15ade4>
check them into the .nix file
<ldlework>
c15ade4: everything in my config is pinned though
<c15ade4>
make pull request
<c15ade4>
I don't think you understand what I am talking about
<ldlework>
probably not!
<c15ade4>
how do you get the pin hashes?
<ldlework>
by trying to install them, letting nix tell me the real hash
<ldlework>
then updating the hash
devopsdeluxe has joined #nixos
<c15ade4>
that doesn't sound reproducible
<c15ade4>
by your logic
<ldlework>
huh?
<ldlework>
if I don't change the hash, it doesn't matter if some package releases a new version
<c15ade4>
no shit
<ldlework>
i'll still be on the revision matching the hash
emily has joined #nixos
<ldlework>
if the hash changes whenever the package does
<c15ade4>
you can pin nixpkgs itself
<ldlework>
then my computer could crash, by the time I rebuild on a new laptop, the package changed, so when i build, a new hash is auto calculated, I use the never version of the library
<ldlework>
which is oops
<ldlework>
not compatible with whatever and my system breaks
<c15ade4>
no thats not how it works
<ldlework>
that's good
<c15ade4>
but if you want a reproducible laptop, you need to pin nixpkgs
<ekleog>
ldlework: hashes are not auto-calculated (unless you're speaking of the mozilla rust-overlay)
<ldlework>
c15ade4: which I do
<ldlework>
ekleog: sure I assumed that's the kind c15ade4 is looking for
<ekleog>
these scripts are just helpers to do the work of fetching the package download page and hashes and updating stuff
<ldlework>
ekleog: if they don't do it automatically when you rebuild, then great
<c15ade4>
obviously...
<ldlework>
well i don't know what auto-updating could otherwise mean sorry
<ldlework>
no idea why you're being so sharp
<c15ade4>
anyway, I just want to submit a new package that is compatible with it
<c15ade4>
mainly because you injected your opinion when you didn't have knowledge of the topic.
<c15ade4>
(I make that mistake too, its not that bad)
<c15ade4>
maybe im just in a bad mood, sorry about that
pikajude has quit [Ping timeout: 276 seconds]
graphene has quit [Remote host closed the connection]
graphene has joined #nixos
pikajude has joined #nixos
<c15ade4>
ldlework: you are right, it was unjustified, sorry my friend
<{^_^}>
[nixpkgs] @Helkafen opened pull request #45730 → snakemake: init at 5.2.2 → https://git.io/fAGqW
midchildan has joined #nixos
timj1 has joined #nixos
timj has quit [Ping timeout: 245 seconds]
<ekleog>
ldlework: mozilla's rust overlay does have tricks for auto-updating on rebuild, though (hopefully someone may be motivated to add a real pinning option there, even though the auto-updating is done only when requested for it still requires internet to enter the nix-shell :°)
<{^_^}>
[nixos-artwork] @samueldr opened pull request #34 → Removes old logo use by changing the backgrounds used → https://git.io/fAGmk
<{^_^}>
[nixpkgs] @samueldr opened pull request #45731 → Removes old logo use by changing the backgrounds used → https://git.io/fAGmI
Drakonis has quit [Remote host closed the connection]
<{^_^}>
[nixos-artwork] @samueldr pushed to fix/logo-credits « Adds credit to the logo README. »: https://git.io/fAGms
<{^_^}>
[nixos-artwork] @samueldr opened pull request #35 → Adds credit to the logo README. → https://git.io/fAGmZ
hamishmack has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
timj1 has quit [Ping timeout: 240 seconds]
timj has joined #nixos
<tnks>
some questions I feel I keep forgetting the answer to. Nixpkgs has a lot of derivations. Do they all get indexed with `nix search -u`?
<tnks>
And also, can I get indexing with custom expressions under ~/.nix-defexpr?
phreedom_ has quit [Remote host closed the connection]
oida has quit [Remote host closed the connection]
witchof0x20 has quit [Remote host closed the connection]
oida has joined #nixos
phreedom has joined #nixos
witchof0x20 has joined #nixos
endformationage has quit [Quit: WeeChat 1.9.1]
trcc has joined #nixos
logzet has joined #nixos
devopsdeluxe has left #nixos ["WeeChat 2.2"]
Mateon3 has joined #nixos
Mateon1 has quit [Ping timeout: 272 seconds]
Mateon3 is now known as Mateon1
beaky has joined #nixos
juhe has joined #nixos
hyper_ch2 has joined #nixos
<hyper_ch2>
LnL: so why why my pull request closed?
<LnL>
moin
<LnL>
hyper_ch2: there's a difference between the public builds and plex pass versions (which are not free)
<LnL>
the unfree version is generally a version ahead
slyfox_ has joined #nixos
slyfox has quit [Ping timeout: 252 seconds]
gonz_ has joined #nixos
<hyper_ch2>
LnL: ah... I see
<hyper_ch2>
it's a stupid website... turning the pass on/off doesn't reload the available version here
<LnL>
oh
<hyper_ch2>
might be an Edge problem which I'm forced to use at work here
<hyper_ch2>
(firefox is rendered unusable as it only allows private mode and ctrl-click opens new tabs with focus.....)
b has quit [Quit: Lost terminal]
<LnL>
yeah so to clarify the change works fine, anybody can download the premium version if they know the url
<hyper_ch2>
I did get flex pass :)
<hyper_ch2>
works fine for me
<{^_^}>
[nixpkgs] @peterhoeg pushed to master « cifs-utils: also generate manpages »: https://git.io/fAGsZ
woffs has joined #nixos
timj has quit [Ping timeout: 240 seconds]
lassulus has joined #nixos
periklis has joined #nixos
<ldlework>
a challenge, take a list of attrNames, ["foo" "bar"] and a prefix such as "mine.workstation" and generate an attrset such that mine.workstation.foo.enabled = true, mine.workstation.bar.enabled = true, etc
<LnL>
hyper_ch2: it works fine for everybody there's no paywall other than the hidden url, meaning that we give the premium version to all nix users :)
<LnL>
the plex people asked us not to do that :p
periklis has quit [Remote host closed the connection]
<clever>
LnL: one area ive noticed where plex may still require payment, the android app stops playback after 90 seconds
timj has joined #nixos
<hyper_ch2>
clever: you can buy either plex pass or the app and not have that limit anymore
<hyper_ch2>
from what I gather
<baimafeima>
hyper_ch2, I started out on ubuntu mate, then moved on to solus
<baimafeima>
hyper_ch2, so basically used very beginner-friendly distros which work largely out of the box
<baimafeima>
I'd like to know if nixos has any ambition to be beginner-accessible or not
<hyper_ch2>
baimafeima: NixOS is very different and it takes a while to setup... however once you get the hang of it you'll love features that it loves... deploy whole systems with a config file... have atomic upgrads that you can rollback... once it runs, it's very heard to toally break it
<clever>
hyper_ch2: it feels like the plex pass would unlock more features, and also avoid the problem of having to buy the app on every platform
<baimafeima>
is there something like a graphical software or app center
<hyper_ch2>
clever: I did buy lifetime plex pass... it's not that much... $120 or something so if it saves me half an hour work, it's already paid off
<hyper_ch2>
baimafeima: no, there isn't (at least not that I know of)
<baimafeima>
hyper_ch2, i like the idea of rollbacks but I wonder if it's suitable as a daily system which "just works" without any need to tinker around
<clever>
hyper_ch2: i have previously done my own re-encoding to watch things on an android tablet, and i found some of them recently, and they sounded like shit, lol
<hyper_ch2>
baimafeima: also, you can have multiple versions of the same program/library installed... that allows you to test new things out and safely revert/go back if it doesn't work as you want
<baimafeima>
hyper_ch2, how do you evaluate the security of the system compared to let's say debian? are there reproducible builds, how aware are devs generally about privacy and security?
flokli has joined #nixos
<hyper_ch2>
baimafeima: what do you mean by "evaluate the securty"?
<hyper_ch2>
baimafeima: you can chose to compile everything your own
<hyper_ch2>
not sure what you mean with privacy and security and devs
<baimafeima>
hyper_ch2, I'm not that advanced, I would need to rely on what's in the repo
<baimafeima>
hyper_ch2, some distro maintainers are not very privacy-conscious or security-conscious, there are huge differences in terms of how an operating system is managed
<baimafeima>
hyper_ch2, I have practically no idea of nixos
<hyper_ch2>
baimafeima: with nixos, you have the "build files" available on how to source is gotten, what is being patched into and how it's being built.... and you can change every aspect of it if you want to
<baimafeima>
hyper_ch2, I can tell you what operating systems are on my list, maybe someone can help me compare them
<clever>
hyper_ch2: though, that is just how to patch the pre-built firefox, there is a second nix file for actually building it
<baimafeima>
hyper_ch2, currently running: Solus 3; interested in: Haiku OS, PureOS, MX Linux, curious about: voidlinux, devuan
<hyper_ch2>
don't know any of those
<baimafeima>
and of course, nixos
<baimafeima>
hyper_ch2, i see
<baimafeima>
hyper_ch2, what about nixos position on open source vs free software? are they more in the pragmatist or ethical side of it, or both?
<hyper_ch2>
maybe you should ask clever ;)
<hyper_ch2>
by default it will only use free software and you have to set a flag to inclue non-free software
<clever>
baimafeima: if you leave allowUnfree at the default of false, it will only allow you to install free software
<baimafeima>
clever, ok
<baimafeima>
clever, is there a separate repo for non-free software and firmware and stuff? does the livecd ship with non-free firmware?
<clever>
baimafeima: the livecd has some nonfree firmware enabled, and all of the nonfree stuff is described in nixpkgs, but will only install if you enable unfree
<baimafeima>
clever, nixpkgs?
<emily>
baimafeima: GuixSD may better suit those with FSF/GNU-style ideological preferences
<etu>
Oh, I didn't know that guix used the nix-deamon
<baimafeima>
if I wanted to suggest a package to be added to the repo (I'm not technical enough to package anything by myself) where would I go and ask?
<etu>
Interesting and cool :)
<hyper_ch2>
once you have nixos setup, it's very much easy-to-use as you can re-deploy it easily
<adisbladis>
Case in point: I set up a new work desktop today and it took ~15 minutes to get an exact replica of my laptop env
<baimafeima>
I don't really know what a nix-daemon is...
<ldlework>
the enableWithPrefix works if I use nix repl
<ldlework>
etu you might have an idea too
<emily>
I think you probably need at least a little programming background to be able to do non-trivial NixOS configuration, at least until someone makes a nice GUI configurator for NixOS modules or something.
<adisbladis>
emily: You don't _have_ to
<baimafeima>
emily, ah that's a pity, then I probably won't even get the system installed?
<emily>
there's only one way to find out
<adisbladis>
It certainly helps for more advanced use cases but you don't need to know the inner workings of nix to use it
<etu>
baimafeima: you can see it as a config file with weird syntax
<etu>
baimafeima: And don't know how to program :-)
<ldlework>
I feel like the idea that a non-programmer can effectively use NixOS is kind of silly.
<ldlework>
I've been coding for 15 years and I'm constantly confused.
<hyper_ch2>
I'm not a programmer
<ldlework>
And you just magically understand non-strict purity?
<baimafeima>
is there a graphical installer? I thought there is a live-cd with plasma 5
* emily
thinks that the real requirement is: not minding being confused
<ldlework>
You might cede outlier status.
<hyper_ch2>
no, I'm just guessing :) and bugging all the smart people in here
<emily>
if baimafeima enjoys being confused and learning about things, then they might have an enjoyable time no matter their programming experience.
<etu>
baimafeima: There's a graphical desktop and a browser with the manual. But the install is command line based :)
smolboye has quit [Ping timeout: 252 seconds]
<adisbladis>
baimafeima: The live CD does have the CLI tools to install + a desktop env
<adisbladis>
There is no graphical installer yet
<adisbladis>
I think that would probably require a full gui config editor to make any sense
<hyper_ch2>
also another huge plus for NixOS: easy of root zfs installaion
<adisbladis>
Which would be awesome
<hyper_ch2>
s/easy/ease/
<baimafeima>
I see, you're all very nice and helpful but I think NixOS is beyond my current knowledge
<adisbladis>
baimafeima: Try it out in a vm and ask us when you are confused =)
<baimafeima>
adisbladis, thanks, I will
johnw_ has joined #nixos
<hyper_ch2>
baimafeima: it's not that complicated... it just involves a lot of reading and getting used to and asking in here
<ldlework>
it is quite complicated
<etu>
baimafeima: yeah, it's mostly different :-)
<ldlework>
i don't know that trivializing things does a true service to anyone :/
<hyper_ch2>
ldlework: different and complicated are two different things :)
<ldlework>
yes, and nix is complicated
<ldlework>
and different
<hyper_ch2>
ldlework: you'll end up with windows :)
<ldlework>
what
<hyper_ch2>
[09:23] <ldlework> i don't know that trivializing things does a true service to anyone :/ --> [09:24] <hyper_ch2> ldlework: you'll end up with windows :)
<ldlework>
either nix is simple, and you're not trivializing and so nix is like windows
* adisbladis
agrees with ldlework, nix is pretty complicated
<ldlework>
or nix is not like the trivialized windows and it is complicated
<ldlework>
you can't have it both ways
<bkchr[m]>
Hi, `nativeBuildInputs` in conjunction with `crossSystem` should use packages from the host system or?
<emily>
I think if someone is asking for a GUI installer then it's probably fair to say that NixOS might be a frustrating experience.
<adisbladis>
bkchr[m]: It should be the host
<ldlework>
at times you have to understand how some of your favorite programs build process works so that you can modify it.
<baimafeima>
hyper_ch2, and I need to type in Chinese, so I would need either Ibus or Fcitx with libpinyin or rime
<adisbladis>
baimafeima: Where are you from?
<ldlework>
:/
<baimafeima>
adisbladis, Germany
<etu>
baimafeima: But if you're unsure, you can always try to set it up in Virtualbox or something :)
<baimafeima>
adisbladis, and you?
<adisbladis>
baimafeima: Sweden. I was thinking you were somewhere in china
<baimafeima>
adisbladis, I'm very often in China
<baimafeima>
adisbladis, that's why I need lots of censorship circumvention tools, VPNs, etc...
<adisbladis>
baimafeima: Cool :> Where about?
<baimafeima>
adisbladis, shanghahi
<adisbladis>
Ahh. Not my neighbourhood exactly
<baimafeima>
is there any chance that mullvad could be in the repo?
<baimafeima>
it's a swedish vpn by the way :D
<adisbladis>
baimafeima: Are they not using openvpn or ipsec?
hamishmack has joined #nixos
<baimafeima>
it's possible to use openvpn but with the app it'll be possible to easily switch servers and have a kill-switch, additional dns protection, just easier to use
<adisbladis>
Ahh right, the active probing stuff
<baimafeima>
hyper_ch2, if mate is packaged, that's good for me, any plans on packaging budgie too?
<adisbladis>
baimafeima: Nixos is more of a "scratch your own itch" kind of community
<baimafeima>
adisbladis, I see
<clever>
> mate.meta.description
<{^_^}>
attribute 'meta' missing, at (string):171:1
<clever>
i prefer nix-build when testing things, since nix-env persists more, and has generations
<nikivi>
so I would think this would work
<nikivi>
but it doesnt
sigmundv__ has joined #nixos
<clever>
yeah, that should also force it to build
<nikivi>
error: attribute 'postgix' in selection path 'postgix' not found
<clever>
postgis isnt spelled right
<clever>
i made a typo above
<nikivi>
oops
<nikivi>
that seems to be building, awesome
<clever>
i'm guessing it will fail at some point, and reveal why it was marked as linux-only
<nikivi>
error: build of '/nix/store/6zq23c85c4s6vanb94fdlrpj34kryfkr-postgis-2.4.4.drv' failed
<nikivi>
yep
nschoe has quit [Quit: Program. Terminated.]
<nikivi>
thats a shame, I really need to use this tool on mac
<clever>
and there should be a more detailed error above that one
<adamantium>
Hello guys, so I'm writing a zfs-on-root bootstrapper, and am almost ready to share it with the world, running into silly problem. Hope you can help.
<clever>
nikivi: youll need to find out what package provides it, and then create an override to fix it
<nikivi>
what would my process me
<clever>
nikivi: quick&dirty first step, `ls -l /nix/store/*/include/iconv.h`
<adamantium>
Okay !!! So, all my nix files are in /mnt/nix-config (novel right?) import in /mnt/etc/nixos/configuration.nix uses relative link to ./hardware.. and ../../nix-config/foo.nix
<nikivi>
clever do that and run the install again?
<adamantium>
Now , when I nixos-install --root /mnt , the thing complains about home store
<adamantium>
I will get the error message out of the vm with termbin if you hang with me guys
<clever>
nikivi: that ls command wont change anything
<adamantium>
clever: thats wonderful, i'll check it out, but i have sunk about 40 hours into this script and really am at the finish line to just quit now
nefix has joined #nixos
<nikivi>
clever so why would I run it?
<adamantium>
So, first, is my setup i have described sane? you can just use relative imports in /mnt to other .nix files in /mnt and install it all with nixos-install --root /mnt ?
<clever>
nikivi: to see what packages contain iconv.h
<clever>
nikivi: step 2 is to then add one of those with an override
<clever>
adamantium: yeah, i would try to always use relative imports, since absolute mess with the chroots during install
<adamantium>
thats where im stuck clever
<adamantium>
everything is relative imports pointing to things in /mnt
<adamantium>
let me get the nix error msg
<adamantium>
if you can help me get this going, maybe we can compare notes after
<adamantium>
haha
<{^_^}>
[nixpkgs] @Mic92 opened pull request #45737 → finalterm: remove non-working version → https://git.io/fAGWN
graphene has quit [Remote host closed the connection]
<ldlework>
adamantium: heh teto is the guy with the "HACKED" profile image you were worried about
<adamantium>
lol
<clever>
adamantium: ls -lh /nix/store/gby17w2w1f35ab099khkf1wcblxx7ddi-modules/nixos
<adamantium>
that file does not exist
<clever>
adamantium: what about the modules dir above it?
<adamantium>
there is only one file in /nix/store beginning with gby and it is much different and ends in .drv
<clever>
adamantium: what about in /mnt/nix/store/ ?
<adamantium>
it has my 3 modules
<adamantium>
exactly where you said. needed the /mnt/*
<clever>
adamantium: its possible that the chroot stuff in nix2 is breaking
<adamantium>
nix2?
<clever>
nix 2.0 lets you act on a store like /mnt/nix/store without doing a real chroot
<clever>
but some parts of the code forget to prefix the paths with /mnt/
<adamantium>
is recimport throwing it off?
<adamantium>
i worked damn hard on this script
<adamantium>
kinda frustrated
<adamantium>
you probably know the pain
<adamantium>
what are the best options
<clever>
testing it locally
<Taneb>
I'm getting "error: hash '' has wrong length for hash type 'sha256'" when I try to nix-copy-closure, could this be because the two machines have different versions of nix?
<adamantium>
clever: you mean libvirt vm could be problematic?
<clever>
adamantium: no, its likely a bug within nix 2
<adamantium>
so
<adamantium>
how do we bootstrap our systems
hlolli has joined #nixos
<clever>
adamantium: nix copy --from local?root=/mnt /nix/store/gby17w2w1f35ab099khkf1wcblxx7ddi-modules --to local
<adamantium>
generic zfs install, then nixos-enter and nixos-rebuild switch ?
<clever>
i think that will work around it for now
hlolli has quit [Remote host closed the connection]
__Sander__ has quit [Ping timeout: 252 seconds]
* ldlework
blinks
<clever>
adamantium: and i can confirm the problem on this end
__Sander__ has joined #nixos
<adamantium>
ldlework: you put me up to this dude
<adamantium>
trying now.
<clever>
adamantium: the problem, is when you try to readDir a storepath when nix2 is chrooting
<clever>
adamantium: it might be possible to work around it entirely
<adamantium>
is recimport doing that ?
<adamantium>
or is it imports period that are doing it?
<clever>
then getDir "${dir}/${file}"
<clever>
change it to: then getDir dir + "/${file}"
arahael has joined #nixos
<clever>
"${dir}/${file}" will copy dir to /mnt/nix/store, then nix2 tries to read it from /nix/store and it fails
<clever>
but dir + "/${file}" wont copy it, and will preserve the original path, and then work, possibly
sb0 has quit [Ping timeout: 244 seconds]
sb0 has joined #nixos
<adamantium>
ldlework: are you getting this?
<adamantium>
ldlework: start taking notes.
<adamantium>
ldlework: your org-mode nougat should work.
<adamantium>
it will be cleaned up a bit though over the next few days
sb0 has quit [Ping timeout: 240 seconds]
<booglewoogle>
hey :) is anyone here using wayland by any chance?
<clever>
adamantium: it looks like your script has more runtime configurability, while mine needs all inputs to be set in nix and rebuilt with nix-build
<ldlework>
clever: sure, but now all my modules depend on this new argument surface
<clever>
ldlework: *eyes line 8*
sb0 has joined #nixos
<ldlework>
fixed that
<clever>
its nearly 7am, i should get back to bed
<nefix>
attempt to call something which is not a function but a set
<nefix>
At line 73
<nefix>
But right above I do the same type and throws no error
<ldlework>
clever: let's say you stick some thing on _module.args.yourthing
<ldlework>
most of that stuff is going to need pkgs or lib
filterfish_ has joined #nixos
drp has joined #nixos
<ldlework>
overlays solve that with self: super:
* adamantium
still can't believe his script works
<adamantium>
^_^
<adamantium>
problem was friggin recimport
<ldlework>
you'd have to explicitly pass in pkgs to everything you stuck onto _module.args
<adamantium>
of all things !
<adamantium>
gn clever thanks for helpin us out
filterfish__ has joined #nixos
filterfish has quit [Ping timeout: 240 seconds]
kisik21 has quit [Ping timeout: 250 seconds]
filterfish_ has quit [Ping timeout: 240 seconds]
Twey has joined #nixos
kisik21 has joined #nixos
<booglewoogle>
hey, is anyone here using wayland via sway? i'm curious and want to try it out, but while i do get a bar, wallpaper and moveable cursor, no inputs seem to be recognized.
Twey has quit [Ping timeout: 246 seconds]
simukis has joined #nixos
baimafeima has quit [Quit: Leaving]
Twey has joined #nixos
thibm has quit [Quit: WeeChat 2.0]
ericsagnes has quit [Ping timeout: 252 seconds]
nefix has quit [Remote host closed the connection]
theunknownxy has joined #nixos
<{^_^}>
[nixpkgs] @xeji merged pull request #44916 → nixos/tests: Set DefaultTimeoutStartSec very high → https://git.io/fN56x
<{^_^}>
[nixpkgs] @xeji pushed commit from @griff to master « nixos/tests: Set DefaultTimeoutStartSec very high (#44916) »: https://git.io/fAGgZ
nefix has joined #nixos
filterfish__ has quit [Ping timeout: 240 seconds]
trcc has quit [Ping timeout: 246 seconds]
<nefix>
Anyone there?
<Taneb>
Usually
<nefix>
Could you help me with an error I'm having?
<Taneb>
That would depend on the error
kisik21 has quit [Quit: WeeChat 2.1]
<nefix>
attempt to call something which is not a function but a set
<drp>
interesting, this is like the package override via .config/nixpkgs/ yes?
<{^_^}>
[nix] @domenkozar pushed to master « nix.conf: mention -j0 is useful »: https://git.io/fAGVY
<drp>
whatever happened to nixups?
<nefix>
no idea, I started with Nix & NixOS three days ago
dmj` has quit [Quit: Connection closed for inactivity]
<drp>
noice, I keep on failing to use nixOS but then end up dissatisfied with anything else, each time I come back I stay that bit longer and am that much happier, it's like my linux experience all over again, how are you finding it?
<init_6>
after gentoo nixos is sooo simple and so rok`s!
nschoe has quit [Read error: Connection reset by peer]
alex`` has quit [Quit: WeeChat 2.2]
ericsagnes has joined #nixos
<srhb>
drp: I think NixUP just fell behind compared to how home-manager was instantly usable.
<johanot>
srhb: do you use home-manager? :)
<johanot>
perhaps that's a rather personal question
filterfish__ has joined #nixos
Guest29686 is now known as CMCDragonkai
<CMCDragonkai>
Does homemanager deal with user level systemd services?
<sphalerite>
nefix: particularly because we have a bot in here that kicks people sending many lines due to recent spam problems
<sphalerite>
drp: home-manager is nixos-like config for your user profile, a lot more flexible than nixpkgs/config.nix
<etu>
sphalerite: Do you know if there's any way to discover the home-manager config options other than reading the source? Like a generated man-page like there is for configuration.nix?
<sphalerite>
etu: I don't unfortunately. Don't even use it myself :p
<sphalerite>
etu: readme says Documentation of available configuration options, including descriptions and usage examples, is available in the Home Manager manual or offline by running `$ man home-configuration.nix`
<etu>
No manual entry for home-configuration.nix :(
<etu>
says man
<etu>
Hmm
<etu>
Maybe I need to update home-manager
<drp>
sphalerite: thanks for the info, I can't say I want to use it given the warnings in the readme
<sphalerite>
drp: AFAIK it's more of a disclaimer like "don't kill rycee if it does break everything", but I don't know of anyone's home actually having been trashed by it :)
<sphalerite>
plus that's what backups are for, right? :D
<etu>
drp: I've never experienced issues with home-manager
philippD has joined #nixos
nschoe has joined #nixos
<drp>
I should totally rsync more often
thibm has joined #nixos
<etu>
sphalerite: oooh, I have to enable the option: manual.manpages.enable
<etu>
drp: Thanks for that link, I've been looking for that :-)
<drp>
muh erc autojoins will soon be in nix, all will be in nix, emacs and nix will be my zen, my backups will be a folder of text files a few kb in size, I will attain the ultimate zen
b has joined #nixos
<sphalerite>
nefix: personally a few lines like you wrote don't bother me that much, but some people are more sensitive and it can be a pain to get kicked from the channel when asking for help :)
carlosdagos has quit [Quit: Connection closed for inactivity]
oida has quit [Ping timeout: 250 seconds]
<srhb>
johanot: Yes, I do :)
<srhb>
johanot: Perhaps unsurprisingly, you get a lot of power when your dotfiles can suddenly have knowledge from each other. :)
<srhb>
My entire homedir isn't converted yet, it's been a gradual process.
<johanot>
srhb: I just didn't have the time yet, but gotta start converting soon, because my env is already a mess :)
oida has joined #nixos
<srhb>
johanot: Well, let me give you the advice that you can just start simple (like, consider your ssh config as an obvious candidate)
<srhb>
And leave everything else as it is
<srhb>
It's very unintrusive
<johanot>
srhb: I like the sound of agile :P
<srhb>
johanot: ;)
* etu
has a htop config file synced with home-manager but should convert that to home-manager options any day now.
<srhb>
johanot: I've also taken to moving certain largeish user utilities that aren't strictly necessary for my system to function into home-manager (so I can switch those at my convenience, but have a fast system switch...) but I've yet to decide if I really like that approach.
<srhb>
There's something to be said for one-config-one-system
abcrawf has joined #nixos
filterfish__ has quit [Ping timeout: 260 seconds]
<johanot>
srhb: Right. Laptops are defacto single-user systems after all. The biggest time consumer in my system switch is grub rebuild. Is it the OS-discoverer that forces rebuild everytime?
mayhewluke has quit [Ping timeout: 240 seconds]
mayhewluke has joined #nixos
<rawtaz>
where is the "webkitgtk" package referenced on line 23 in webkitgtk defined, where can i see what version of webkitgtk it resolves to?
<rawtaz>
im trying to install unstable.astroid, but am getting "webkitgtk-2.4.11 is marked insecure", but i dont understand why that old version is referenced.
baimafeima has joined #nixos
nefix has quit [Ping timeout: 240 seconds]
pie_ has joined #nixos
<srhb>
johanot: Hmm, that seems likely
<srhb>
johanot: I use systemd-boot, so there's no time cost at all
sb0 has quit [Ping timeout: 252 seconds]
<srhb>
johanot: Of course, it's way less flexible.
<srhb>
johanot: Maybe you can just dump the os discovery output and hardcode it? I imagine you don't switch layouts that often.
<johanot>
srhb: Sounds reasonable.. and you're right, I don't :P
johanot has quit [Quit: leaving]
silver has joined #nixos
<{^_^}>
[nixpkgs] @disassembler opened pull request #45744 → Measure phase metrics in stdenv optionally → https://git.io/fAGXX
sb0 has joined #nixos
rprije has quit [Ping timeout: 250 seconds]
<{^_^}>
[nixpkgs] @vbgl opened pull request #45745 → hhvm: mark as broken → https://git.io/fAGMe
booglewoogle has quit [Remote host closed the connection]
<{^_^}>
[nixos-artwork] @samueldr pushed 2 commits to master: https://git.io/fAG9e
<{^_^}>
[nixos-artwork] @samueldr merged pull request #35 → Adds credit to the logo README. → https://git.io/fAGmZ
<{^_^}>
[nixos-artwork] @samueldr pushed 0 commits to fix/logo-credits: https://git.io/fAG9f
<{^_^}>
[nixos-artwork] @samueldr pushed 0 commits to feature/font: https://git.io/fAG9T
<nefix>
philippD: also, if you could help me with the float type, it's throwing this error: attribute 'float' missing (the commented block)
jD91mZM2 has joined #nixos
<srhb>
Profpatsch: Oh, yes, I think I understand now. I think what you're saying is that import (nixpkgs) {} is not a derivation. And yes, that's right. :)
booglewoogle has joined #nixos
<srhb>
(At least, not effectively!)
<philippD>
nefix: I don't know what form `cfg` has but the way your function is written is that it expects a list of sets where each set contains ALL attributes that you query.
<infinisil>
Profpatsch: I guess you'd need something like pkgs.srcOnly
<nefix>
philippD: not following you, I started three days ago with Nix and NixOS
<philippD>
nefix: can you provide an example input to the formatRules function? As it stands the input has to look something like `[{ instanceName = ""; className = ""; ....} {...} {...}]`
<nefix>
philippD: rules option
<nefix>
philippD: it's like you have written,a list of "rule" submodule
<Profpatsch>
infinisil: It’s a bootstrap problem, I my nixpkgs is imported by the fetchTarball. :P
<Profpatsch>
But I think what I need is to use `nix-instantiate --eval` in this case.
aminb has joined #nixos
<booglewoogle>
hey! is anyone here using wayland via sway? I'm trying to get my custom xkb layout working, currently looking at https://nixos.org/nixos/options.html#sway.extrasessioncommands , but that's only looking for layouts in a predefined read-only prefix if i understand correctly, so giving it the layout as ${./foo.xkb} doesn't work
<srhb>
Profpatsch: If you're using the usual terminology, where "nixpkgs" is the actual path to a nixpkgs "checkout" then that is just builtins.fetchTarball { ... }
<Profpatsch>
I remembered:
<srhb>
while pkgs is `import (builtins.fetchTarball { ... } {}`
<d1rewolf>
is there an up-to-date guide somewhere for best practices for using npm with nixos?
<infinisil>
d1rewolf: Probably best to use it nix-managed instead
<d1rewolf>
infinisil: I'm just curious of the best way to install individual packages. for example, I wish to use the Google-provided npm package clasp (https://github.com/google/clasp) to sync my Google Apps projects with their backend. I just need to isntall that packages
<d1rewolf>
that package. I'm not doing anything more fancy than that
<d1rewolf>
installing it non-root seems to install it but doesn't create executables in $PATH
<infinisil>
There's a bunch of node2nix/npm2nix floating around
<symphorien>
Also yarn2nix
<JonReed>
d1rewolf: I used `npm2nix` in the past to install it. I would have `[ "serve" ]` inside `node-packages.json` and then run npm2nix on it, which generates .nix files and then I installed those nix files
<d1rewolf>
is it worth going down that path for one package like this? or is it acceptable to install it to ~/node_modules (local, by npm's verbiage
<JonReed>
d1rewolf: To avoid confusion, in your example, it would be `clasp` inside `node-packages.json`. Serve is just another random package from npm
<d1rewolf>
JonReed: I'll give that a look. thanks!
bjpbakker has joined #nixos
<d1rewolf>
is there a problem with doing local installs? local the way npm describes them? for example, just "cd ~ && npm install clasp"?
Drakonis has joined #nixos
<d1rewolf>
also, it appears npm2nix is no longer supported but node2nix is....which did you use JonReed ?
<JonReed>
d1rewolf: I have wrote for myself a detailed step by step instruction somewhere. I'll try to find it. Sec.
<d1rewolf>
JonReed: cool, thx
fzer00 has joined #nixos
<{^_^}>
[nixpkgs] @atanasi opened pull request #45752 → xpra: fix the xkb search path → https://git.io/fAGbz
lopsided98 has quit [Ping timeout: 264 seconds]
fzer000 has joined #nixos
aarvar has quit [Ping timeout: 245 seconds]
fzer0 has quit [Ping timeout: 244 seconds]
samrose has joined #nixos
<d1rewolf>
once I've used nix-build to create a result symlink, and I'm happy with it, how can I then encorporate that built package into my environment?
<samrose>
if I want to declarative turn on services.sshd.enable = true; but then declarative systemctl stop sshd.service is this supported in nixos ?
drp has joined #nixos
fzer00 has quit [Ping timeout: 240 seconds]
orivej has quit [Ping timeout: 246 seconds]
<d1rewolf>
in other words, what do you do after you're satisfied that nix-build built what you wanted it to? How do you then install the built package globally instead of just in the current "result" symlinked directory?
<symphorien>
Imperatively you can nix-env -i result
<d1rewolf>
symphorien: you mean result, as in the symlink?
<d1rewolf>
as in "nix-env -i result/"
<d1rewolf>
symphorien: is there anywhere in the manual that covers this?
<d1rewolf>
and I assume since node2nix creates nix files which I then built with nix-build. If I wanted to use these declaratively, I'd have to import the node nix files from somewhere in my configuration.nix and then nixos-rebuild?
<JonReed>
d1rewolf: Here it is: https://pastebin.com/e7FGwqYF . It was written in a blogpost that I never published.
<JonReed>
as a blogpost*
<d1rewolf>
JonReed: cool...thanks! you should publish it... I'm sure others would find it very helpful ;)
<das_j>
Is there any way I can check if a string is in a list?
<d1rewolf>
JonReed: have you ever used the resulting .nix files declaratively with nixos-rebuild instead of installing imperatively with nix-env?
<JonReed>
d1rewolf: Yeah. You just need to import them into your configuration.nix
<d1rewolf>
JonReed: ok, great. thanks. very very helpful
<d1rewolf>
JonReed: one final question...have you found a way to get npm/nix to install the executable stubs instead of just the javascript files?
<d1rewolf>
those which would be found in node_packages/.bin?
<cocreature>
das_j: not sure if there is something more succinct but you could use findFirst
<das_j>
cocreature: I'm now at filterAttrs (k: v: any (x: x == v) allUsers) availableUsers
<das_j>
that seems okay
<JonReed>
d1rewolf: Probably. I don't remeber specifics.
ThatDocsLady has quit [Remote host closed the connection]
<JonReed>
infinisil: I think I need to get over the laziness and just setup a blog. I have bunch of those posts laying around. But they are not in a wiki format, but rather as an exploration when something fails and how I approach to debugging and correcting it.
<infinisil>
JonReed: the wiki is ready to use now, and this kind of thing fits very well in it
__Sander__ has quit [Quit: Konversation terminated!]
TweyIII has quit [Ping timeout: 246 seconds]
<{^_^}>
[nixpkgs] @Mic92 opened pull request #45754 → systemd-cryptsetup-generator: cryptsetup belongs to buildInputs → https://git.io/fAZtP
nbardiuk has quit [Quit: Lost terminal]
<elvishjerricco>
bkchr[m]: There might be a convenience function somewhere, but you can definitely do `someDerivation.overrideAttrs (old: { passthru = old.passthru or {} // { ...my passthru... }; })`
<{^_^}>
[nixpkgs] @bkchr opened pull request #45757 → Androidndk standalone toolchain support → https://git.io/fAZOo
nschoe has quit [Ping timeout: 252 seconds]
kisik21 has joined #nixos
orivej has joined #nixos
<d1rewolf>
guys, I have a npm module i installed with node2nix and then nix-eval. even though I've removed all references (i think) from it, it refuses to be garbage collected. nix-store -q --referrers shows:
<clever>
d1rewolf: you want nix-store --query --roots
<d1rewolf>
clever: that returns empty
<clever>
d1rewolf: and then run `nix-store --delete` on the path?
<d1rewolf>
clever: actually, I was wrong. I ran --query --roots without the path. adding the path shows /nix/var/nix/profiles/per-user/d1rewolf/profile-12-link
<clever>
ah, its in use by a generation of nix-env
<clever>
ls -l /nix/var/nix/profiles/per-user/d1rewolf/profile
<d1rewolf>
profile is a symlink to profile-12-link
<clever>
its in your current generation, you need to first uninstall it with nix-env -e
<d1rewolf>
clever: so you're saying it still thinks it's installed via nix-env -i?
<clever>
yep
<clever>
check nix-env -q to see it
<d1rewolf>
so it is. I could've sworn I removed it.
<kisik21>
Question. nixpkgs.ledger documentation says it should include a tool called `getquote`, but I cannot find it in ledger's $out. Where is it? Packaged separately or just not included because whoever wrote the derivation never used it? (accidentally asked on #nixos-chat, moving here)
<d1rewolf>
if I do a "nix-env -i result/" pointed towards a result symlink created by nix-build, what's the correct way to remove it?
primeos has quit [Quit: WeeChat 1.4]
<clever>
d1rewolf: use -e with either the same storepath, or the name
<d1rewolf>
clever: k, I thought I did that, but apparently not. however, the name is different from what's returned from nix-env -q, right? How do i find the actual name?
<clever>
the name is what is returned by -q
<clever>
but .'s in the name can confuse nix-env
<clever>
using the full storepath can make it simpler
<clever>
nix-env -e /nix/store/hash-foo
<d1rewolf>
the name returned by nix-env -q is node-clasp-0.1.0. Running nix-env -e node-clasp-0.1.0 or nix-env -e node-clasp won't work.
<d1rewolf>
maybe it's the periods
<d1rewolf>
clever: full path fixes it
<clever>
`nix-env --delete-generations 12` will get rid of generation 12
<d1rewolf>
that's the one thing about nixos i haven't been happy with so far....it seems like there are quite a few edge cases, like the .'s in names, which don't work
<clever>
then you can `nix-store --delete` it
<clever>
yeah, some of the command like stuff is a bit buggy with names
<d1rewolf>
clever: would a nix-store --delete be necessary after nix-store --delete-generations 12?
<clever>
if you want to actually remove the path from the store
<d1rewolf>
would the first simply remove the link of that deriviation to the generation, and the second would remove the derivation entirely?
<clever>
--delete-generations just gets rid of the GC root, so you can delete it
<d1rewolf>
k
rfold has joined #nixos
<{^_^}>
[nixpkgs] @xeji opened pull request #45758 → nixos/tests/mesos: fix test → https://git.io/fAZs0
work_ has quit [Quit: Connection closed for inactivity]
BlessJah_ has joined #nixos
<nefix>
How can I bundle different programs in the same environment always?
<nefix>
I'm finding myself using nix-shell all the time to develop with Golang
<nefix>
(because of cgo)
<clever>
nefix: make a shell.nix file
<d1rewolf>
nefix: use declarative vs imperative
<nefix>
what are those?
<clever>
with import <nixpkgs> {}; stdenv.mkDerivation { name = "foo"; buildInputs = [ go ]; }
<d1rewolf>
put it in a nix file and import from your configuration.nix
<clever>
nefix: pop that into shell.nix, and then just run nix-shell with no args
<d1rewolf>
nefix: you really need to spend some time reading the manual, or better yet start with nix pills
<michas>
mpickering: strange, I did a `nixos-rebuild switch --upgrade` yesterday and it did not fix the issue. Shouldn't that use the most recent version of the channel?
<mpickering>
I don't use channels sorry
<d1rewolf>
mpickering: don't use channels? interesting. what do you use instead?
<mpickering>
I have a local checkout of nixpkgs in a folder
<clever>
mpickering: what does `nix-channel --list` show for root?
<clever>
michas: yeah, then you should be on the version you linked from github
graphene has quit [Remote host closed the connection]
<infinisil>
mpickering: You probably still use nixpkgs-channels though, right? Just not nix-channel
graphene has joined #nixos
samrose has quit [Ping timeout: 252 seconds]
<mpickering>
I don't think so?
<mpickering>
do you mean that I track the unstable branch? I just check out master occasionally
<infinisil>
mpickering: You run your NixOS system from master??
<infinisil>
The untested master?
<mpickering>
yes?
<infinisil>
Well, I guess you know what you're doing, everything could break horribly, since nothing is tested by hydra
<infinisil>
I also use a git checkout, but still track the nixos-unstable branch to get tested releases
sigmundv has quit [Ping timeout: 252 seconds]
<mpickering>
I suppose checking out unstable would only be a tiny bit less convenient
<mpickering>
anyway, all patches that are in master have been carefully reviewed before they were merged right?
<cocreature>
mpickering: so that’s why the channels don’t update for weeks sometimes due to broken tests? :)
jtojnar has joined #nixos
jtojnar has quit [Remote host closed the connection]
<mpickering>
If haskellPackages works then that's fine for me mostly
<infinisil>
mpickering: Well tthey should, but there's no guarantee
<cocreature>
if you use nixos then you probably care about a bit more than haskellPackages :)
<cocreature>
e.g. a working bootloader might be nice
<mpickering>
and tbh I rarely do a full nixos rebuild
<mpickering>
cocreature: The theory is that I'm not going to be the first person to run into that kind of breakage
<mpickering>
anyway I'll start believing unstable is less broken than master when darwin doesn't constantly break
<infinisil>
mpickering: Well using master makes you a good candidate for that..
<cocreature>
note that using master for some nix-shell that you use for Haskell development does not require you to use master for building your system
<mpickering>
that's true but how do you practically suggest to do that?
graphene has quit [Remote host closed the connection]
<cocreature>
pin nixpkgs in your default.nix/shell.nix
<cocreature>
I do that for pretty much any project
<mpickering>
you do it by manually copying/writing the boiler plate to do it?
<mpickering>
then having to wait 30 seconds and then copy and fix the SHA?
<cocreature>
the boilerplate is like 3 lines or so but yeah I copy it from existing projects :)
graphene has joined #nixos
<mpickering>
This should be built into the `nix` command
Lisanna has joined #nixos
<mpickering>
However, that is implemented in C++ so no one can add anything to it very easily
<cocreature>
there is nix-prefetch-url if you don’t like the “put in a wrong sha and wait for nix to tell you the right one” workflow
jbgi has joined #nixos
<Lisanna>
nix-env has a -iA channelname.package mode for install... but that doesn't work with -e. Is there a way to uninstall a package that came from something other than nixpkgs in the NIX_PATH without giving the fully-qualified /nix/store path?
<gchristensen>
mpickering: what should be builtin to the nix command? you can use builtins.fetchGit without a sha256 argument.
<clever>
Lisanna: once installed, nix-env has no clue what channel or attribute it came from
nly has quit [Quit: Leaving]
<clever>
Lisanna: you uninstall by name, not attributepath
<sphalerite>
Lisanna: copy the name from nix-env -q's output I'd say
<Lisanna>
what "name"?
<mpickering>
Isn't the problem with using builtins.fetchGit that it will refetch the argument periodically?
<Lisanna>
the derivation name?
<clever>
yeah
<Lisanna>
bleh, OK
<Lisanna>
Nix's attempts to masquerade as a normal package manager sure do produce some strange results sometimes...
<mpickering>
cocreature: I want the ideal interface where I type `nix pin` and it creates a nixpkgs.nix file which creates the pin for me which I can import and use.
<gchristensen>
mpickering: it might run a `git fetch` but it'll not actually redownload everything, since it is local. there is a patch in to remove the unneeded fetch when it is pre-fetched for fetchGit.
jtojnar has joined #nixos
jtojnar has quit [Remote host closed the connection]
<infinisil>
,fancy-uninstall Lisanna
<{^_^}>
Lisanna: Fancy way to uninstall packages, needs fzf installed: nix-env -q | fzf | xargs -I{} nix-env -e {}
<Lisanna>
infinisil err, what does that do?
<Lisanna>
oh, I see
<{^_^}>
[nixpkgs] @xeji merged pull request #39054 → firewall service: respect marks in rpfilter → https://git.io/vpUUd
<{^_^}>
[nixpkgs] @xeji pushed commit from @abbradar to master « firewall service: respect marks in rpfilter (#39054) »: https://git.io/fAZEp
graphene has quit [Remote host closed the connection]
<{^_^}>
[nixpkgs] @FRidh opened pull request #45761 → Staging next → https://git.io/fAZul
<samueldr>
somehow get a GRUB2 installed with the default settings, `build-vm-with-bootloader` helps
<samueldr>
the lightdm tests will confirm the lightdm config works (with its screenshot feature)
<gchristensen>
I should test that on a Packet server
<gchristensen>
it uses a serial-only setup for the bootloader which was broken at some point
<hyper_ch>
wow, I was just so happy about zfs..... some external HD that I made backups to seem to have stopped working... so it was filling my notebooks SSD.... all I had to do was just rollback to 6h ago ;)
<samueldr>
gchristensen: that one, though, is extremely lean on the bootloader-side of changes, thankfully!
graphene has quit [Remote host closed the connection]
graphene has joined #nixos
<Thra11>
If there are no patches, does it matter whether I do substituteInPlace in postUnpack, postPatch or preConfigure? If not, which should I prefer?
<gchristensen>
Thra11: usually I do postPatch
graphene has quit [Read error: Connection reset by peer]
<gchristensen>
since it is semantically closest to what I want
graphene has joined #nixos
<Thra11>
gchristensen: That makes some sense. I'll do that
<Zajcev>
guys, stupid question ... how to change channel and uprade qemu machine deployed with nixops?
<gchristensen>
set NIX_PATH on the deployment host
graphene has quit [Remote host closed the connection]
<Zajcev>
gchristensen: ok, this works, is it ok? export NIX_PATH="nixpkgs=https://nixos.org/channels/nixos-unstable-small/nixexprs.tar.xz"
graphene has joined #nixos
<Zajcev>
gchristensen: now, when I do nixops deploy, it will upgrade guests?
<gchristensen>
yeah
<Zajcev>
great, thanks
<gchristensen>
fridh maybe will see this ping and come in here ...
drakonis__ has joined #nixos
<clever>
Zajcev: i generally do `nixops modify -I nixpkgs=https://nixos.org/channels/nixos-unstable-small/nixexprs.tar.xz ./deployment.nix`
<clever>
nixops will then save that -I flag in the state file, and you dont have to remember to `export NIX_PATH` every time you deploy
michas has joined #nixos
das_j has quit [Quit: WeeChat 2.1]
<Zajcev>
clever: deployment.nix does not exist
<michas>
Hi, as root `nix-channel --list` points to https://nixos.org/channels/nixos-unstable, however the content of `/nix/var/nix/profiles/per-user/root/channels/nixos` seem to point to an oder version. - Shouldn't `nix-channel --update` make both match?
<michas>
(If I understand correctly nixos-rebuild looks at that directory.)
<michas>
srhb: Thanks. This means under normal circumstances both locations should contain the same content, right? What is the point of having two different locations? Wouldn't it be easier to implement `nix-channel --update` simply by using `git pull`?
<srhb>
michas: Yes, it should. :) Easier perhaps.. The nixpkgs-channels update operation could also have failed though.
witchof0x07 has joined #nixos
witchof0x20 has quit [Remote host closed the connection]
witchof0x07 is now known as witchof0x20
<samueldr>
michas: the issue AFAIUI is that the git repository is order of magnitudes bigger than the archives served by the channel; for most use cases it's a waste
aristid has joined #nixos
<srhb>
samueldr: Still, it could just fetch from the autogenerated tarballs there
<srhb>
If we're talking about "why have two channel mechanisms"
<samueldr>
that's right
<samueldr>
are nix "channels" older than the use of github though?
<samueldr>
and then there's the issue of serving the isos and other artifacts that aren't strictly nixpkgs
<srhb>
Sure, sure.
<samueldr>
(kinda thinking out loud for other reasons why)
<srhb>
:)
<srhb>
There's also an argument to be made for having that bit be independent of github
<samueldr>
doesn't the channel build also manipulates the contents a bit? (it saves git version in the archive I think)
<srhb>
samueldr: Sounds right :)
jperras has quit [Ping timeout: 246 seconds]
<gchristensen>
that is right
justbeingglad has joined #nixos
justbeingglad has left #nixos [#nixos]
filterfish__ has joined #nixos
michas has quit [Read error: No route to host]
michas has joined #nixos
jbgi has quit [Ping timeout: 245 seconds]
<michas>
samueldr: ok, looks like the repo is 478M and the pkg dir is 129M - not really magnitutes, but I understand the point. :)
<samueldr>
oh, I thought it was smaller, like *one* magnitude :)
simukis has quit [Quit: simukis]
Turion has quit [Quit: Leaving.]
xeji has joined #nixos
<srhb>
michas: It's also the fetch though. The nixpkgs tarball is like 10MiB
hamishmack has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
DigitalKiwi has quit [Quit: DigitalKiwi]
kenshinC1 has joined #nixos
hiroshi has joined #nixos
ilikeheaps has joined #nixos
kenshinC1 has quit [Ping timeout: 252 seconds]
rfold has quit [Ping timeout: 240 seconds]
drakonis__ has quit [Remote host closed the connection]
nly has quit [Ping timeout: 240 seconds]
graphene has quit [Read error: Connection reset by peer]
graphene has joined #nixos
lostman has quit [Quit: Connection closed for inactivity]
logzet has quit [Remote host closed the connection]
__monty__ has quit [Quit: leaving]
Thra11 has quit [Ping timeout: 245 seconds]
kini has joined #nixos
<kini>
I'm trying to install nixos on a machine while behind a proxy. So I tried setting network.proxy.default in /etc/nixos/configuration.nix (i.e. the livecd's own config) and doing `nixos-rebuild switch`, but apparently nixos-rebuild needs internet access even just to make that change.
<kini>
Then I tried exporting $all_proxy in the shell before running `nixos-rebuild`, but to no avail (I guess because the actual work is being handed off to a daemon which is running in the background). Any suggestions?
<clever>
kini: try `nixos-rebuild test --fast --option substituters ""`
<kini>
yay, it worked! But there were a ton of file collisions, which seem unrelated
<bgamari>
error: syntax error, unexpected '.', at (string):1:94
<clever>
bgamari: you cant mix paths and -p
<bgamari>
sigh, oh, right
<kini>
They're in duplicate derivations of grub-2.02 and phonon-backend-gstreamer-qt5-4.9.0 -- looks like two different derivations of each package were pulled by different things into the same environment (?)
<clever>
-p generates a derivation to shell into, but a path points to one
* bgamari
now remembers he even opened a ticket about this
<eacameron>
Hey, I'm trying to configure xrdp so I can use my standard kde+plasma5 setup remotely.
<eacameron>
I am able to rdp into the machine but it gives me an xterm window. I'm trying to start the plasma5 env with the same start script used by `xsession` but when I open windows in the remote session it opens them in my local session!
<eacameron>
So things are working-ish...but not quite right.
civodul has quit [Quit: ERC (IRC client for Emacs 26.1)]
jperras has quit [Ping timeout: 240 seconds]
xeji has quit [Quit: WeeChat 2.1]
<elvishjerricco>
eacameron: NixOS installs a variety of sessions, so something is just picking the wrong one. I know it has some sense of defaults for the desktop and window managers, but I don't think all login managers take them into account: https://nixos.org/nixos/options.html#desktopmanager.default
<elvishjerricco>
one of the sessions is an xterm session