<Arahael>
I can't figure out how to compile an ios project within a nix shell. Very very impure, but you know, little steps. Any tips? I've had to set PATH=/usr/bin/sh and the like to ensure that the platform path is used in preference to nix, but not making much progress beyond that.
<Arahael>
Just "works" outside of nix, though.
<Arahael>
(Outside of nix, the typical: xcodebuild -scheme myScheme -workspace *.xcworkspace -configuration Release -sdk iphoneos; just works.)
<Arahael>
If someone has references to good articles discussing this I'd be very happy to read them!
<matthewbauer>
arahael: you can use the "xcodeenv" stuff although i can't find any documentation
aminechikhaoui has quit [Quit: Ping timeout (120 seconds)]
aminechikhaoui has joined #nix-darwin
philr has quit [Quit: WeeChat 2.4]
nD5Xjz_ has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 258 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 250 seconds]
nD5Xjz_ has quit [Ping timeout: 248 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 255 seconds]
nD5Xjz_ has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 245 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 248 seconds]
nD5Xjz_ has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 250 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 248 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 246 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 258 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has quit [Ping timeout: 246 seconds]
disasm_ has joined #nix-darwin
disasm has quit [Ping timeout: 245 seconds]
nD5Xjz has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 245 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz_ has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 248 seconds]
nD5Xjz_ has quit [Ping timeout: 252 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 250 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 250 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 252 seconds]
<teehemkay>
do I add it back? I've tried setting `nix.nixPath = [{ nixpkgs = "/nix/var/nix/profiles/per-user/root/channels/nixpkgs"; }];` but to no avail.
<teehemkay>
Hi! I've finally switched to using nix-darwin. I'm using the `simple.nix` example configuration with a multi-user Nix installation. I've noticed that some `nix` commands are broken, for example `nix search` no longer find any of packages in `<nixpkgs>`. I suspect that this may be due to the fact that `nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixpkgs` no longer appears in `$NIX_PATH`. If that's the problem how
<teehemkay>
My current `$NIX_PATH` is `darwin-config=/Users/tmk/.config/nixpkgs/darwin/configuration.nix:/nix/var/nix/profiles/per-user/root/channels:/Users/tmk/.nix-defexpr/channels`
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 250 seconds]
disasm| has joined #nix-darwin
disasm_ has quit [Ping timeout: 248 seconds]
<LnL>
hmm, does this command work? nix-instantiate --find-file nixpkgs
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 246 seconds]
nD5Xjz has joined #nix-darwin
nD5Xjz has quit [Ping timeout: 255 seconds]
nD5Xjz has joined #nix-darwin
<teehemkay>
it does -> /nix/var/nix/profiles/per-user/root/channels/nixpkgs
<clever>
teehemkay: i think `nix search` ignores NIX_PATH, and only uses ~/.nix-defexpr/
<LnL>
are you sure, only nix-env AFAIK
<teehemkay>
clever: `~/.nix-defexpr/` looks identical to the one in my other Mac without nix-darwin (two symlinks to channels in my `per-user` profile and channel_roots to root "per-user" profile)
<clever>
and do channels exist within one of those dirs?
<teehemkay>
Also, I was wrong in my initial comment, the change I made to nix.nixPath was in a config file that was not the one used by nix-darwin ...
<LnL>
teehemkay: hold on your last change wasn't active yet, did you start a new shell?
<teehemkay>
LnL: I'm not sure I understand what you mean by "your last change wasn't active yet". I don't think I started a new shell though I'm not sure.
<LnL>
there's no nixpkgs= entry
<teehemkay>
Correct, there's no nixpkgs= entry in `NIX_PATH`
<LnL>
what you configured will add that, but you have to start a new terminal/shell for it to apply
<teehemkay>
OK, thanks.
<LnL>
don't understand why it's necessary tho, there's something weird with named vs search path entries IIRC
<teehemkay>
Now, starting to feel a little stupid: `darwin-rebuild switch` errors out:
<teehemkay>
The thing, I did the ` switch -I ...` thing
<teehemkay>
my config is at ~/.config/nixpkgs/darwin/configuration.nix and `environment.darwinConfig = "$HOME/.config/nixpkgs/darwin/configuration.nix";`
<LnL>
looks like nix is missing from the target system, which would be bad if that activated
<teehemkay>
line 92: `darwinConfig=$(NIX_PATH=darwin-config=$HOME/.config/nixpkgs/darwin/configuration.nix:/nix/var/nix/profiles/per-user/root/channels:$HOME/.nix-defexpr/channels nix-instantiate --find-file darwin-config) || true`
<teehemkay>
If I run the subshell command in my shell I get `/Users/tmk/.config/nixpkgs/darwin/configuration.nix`
<LnL>
yeah, it's not NIX_PATH but systemPackages that's the problem here I think
<LnL>
what's darwin-option nix.package?
<teehemkay>
"/nix/var/nix/profiles/default"
<teehemkay>
I did set nix.package to that value in my configuration at one point
<LnL>
and I bet that doesn't exist or doesn't contain nix
<teehemkay>
`/nix/var/nix/profiles/default/bin/nix` does exist. It's my nix install from which I install nix-darwin.
<teehemkay>
But I just checked and my configuration file has `nix.package = pkgs.nix;`
<LnL>
I'm not sure why it wouldn't be found then, nix-instantiate: command not found
<LnL>
did you override anything special like environment.systemPath?
<teehemkay>
So, nix is indeed missing. How come?!?
<teehemkay>
I'll remove `nix.package = pkgs.nix;` from my config
<teehemkay>
Removing `nix.package = pkgs.nix;` from my config doesn't change anything...
<LnL>
the only case it won't be added is when nix.package is a path like the default profile instead of a package
<teehemkay>
I think, I'll just uninstall Darwin-nix and then re-install it from scratch
<teehemkay>
Thanks you so much for your help LnL! And for developing nix-darwin!
<LnL>
I hope you get it working
<LnL>
I added some stuff recently, but nothing that could be related to this so I don't think it's a new bug
<teehemkay>
FWIW, I've now unsinstalled `nix-darwin`, `nixpkgs` shows up in `NIX_PATH` but `nix search` is still broken. So maybe the problem was not with 😉
<teehemkay>
Well nix-darwin was working perfectly before I started mucking around with nix.nixPath and nix.package I think. The install went like a cinch. I'll just restart from scratch.
<teehemkay>
Well, I updated nix (this fixed the nix search issue) and re-installed nix-darwin and everything is working like a cinch 😁.