| 12 Oct 2023 |
| @erremilia:matrix.org set a profile picture. | 00:13:14 |
| @erremilia:matrix.org removed their profile picture. | 00:14:44 |
| 13 Oct 2023 |
| @ThorHop:matrix.org changed their display name from hopland (glib gary) to hopland (flaky frank). | 10:27:26 |
| 14 Oct 2023 |
twitchy0 | How do I include the latest release here as a flake input? https://github.com/pftf/RPi4/releases | 00:34:45 |
twitchy0 | seeing the following error:
error: file:// URL 'file+https://github.com/pftf/RPi4/releases/download/v1.35/RPi4_UEFI_Firmware_v1.35.zip' has unexpected authority 'github.com'
| 00:35:45 |
@antifuchs:asf.computer | try github:pftf/RPi4/v1.35? That'll be the source tree with the tag v1.35 | 19:55:44 |
| 17 Oct 2023 |
| Marillindië joined the room. | 07:51:29 |
| 18 Oct 2023 |
@petrichor:envs.net | i'm trying to make a flake that tangles most of its own source from a literate org-mode file at evaluation time, but to do that it needs emacs available so it needs to know what system it's being evaluated on, and builtins.currentSystem doesn't seem to be available at the point where outputs is being evaluated. hardcoding it as nixpkgs.legacyPackages.x86_64-linux.emacs works for now, but hard-coding the system there seems fragile.
is there a better way of doing this?
| 08:11:06 |
@petrichor:envs.net | this is what i have working:
outputs = inputs:
let
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
emacs = pkgs.emacsWithPackages (epkgs: [ epkgs.s epkgs.f epkgs.dash ]);
mkSource = src: pkgs.stdenvNoCC.mkDerivation {
name = "boxen-source";
inherit src;
buildPhase = ''
${emacs}/bin/emacs --batch --quick \
--eval "(require 'org)" \
--eval "(let ((org-confirm-babel-evaluate nil)) (org-babel-tangle-file \"boxen.org\"))"
'';
installPhase = ''
mkdir $out
cp -r lib packages homes modules systems files $out/
cp boxen.org $out/
'';
};
src = mkSource ./.;
in …
| 08:12:14 |
| dunxen changed their profile picture. | 21:16:33 |
| 19 Oct 2023 |
Artturin | In reply to @petrichor:envs.net
this is what i have working:
outputs = inputs:
let
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
emacs = pkgs.emacsWithPackages (epkgs: [ epkgs.s epkgs.f epkgs.dash ]);
mkSource = src: pkgs.stdenvNoCC.mkDerivation {
name = "boxen-source";
inherit src;
buildPhase = ''
${emacs}/bin/emacs --batch --quick \
--eval "(require 'org)" \
--eval "(let ((org-confirm-babel-evaluate nil)) (org-babel-tangle-file \"boxen.org\"))"
'';
installPhase = ''
mkdir $out
cp -r lib packages homes modules systems files $out/
cp boxen.org $out/
'';
};
src = mkSource ./.;
in …
https://github.com/numtide/flake-utils the eachX functions | 09:37:18 |
@petrichor:envs.net | Artturin: thanks, i'm aware of this, but i still need to then instantiate this derivation while defining the flake's outputs, which requires a specific system rather than mapping over a range of possible systems | 09:52:33 |
@petrichor:envs.net | i've also tried pkgs = import inputs.nixpkgs { }; for line 3, but that also errors out because builtins.currentSystem isn't available | 09:54:11 |
@petrichor:envs.net | i think this is because currentSystem is considered impure, and flake evaluation is pure by default: i can build this by passing --impure | 09:54:47 |
@petrichor:envs.net | it may be that i just can't do what i want to do without --impure because it makes the flake's outputs dependent on whichever instantiation of emacs is used | 09:57:44 |
@petrichor:envs.net | just trying to avoid the situation where i update the literate config and forget to regenerate the actual nix files | 09:58:08 |
Artturin | In reply to @petrichor:envs.net Artturin: thanks, i'm aware of this, but i still need to then instantiate this derivation while defining the flake's outputs, which requires a specific system rather than mapping over a range of possible systems https://github.com/NixOS/nix/issues/3843 | 10:01:24 |
@petrichor:envs.net | ah, this has been rumbling on for years! | 10:15:49 |
@petrichor:envs.net | i think for now i can accept that i need to explicitly pass --impure when evaluating this flake: that's not without risk, but it does what i need to do | 10:17:04 |
| 20 Oct 2023 |
| @sheeley:matrix.org joined the room. | 00:45:35 |
| @ngn999:matrix.org joined the room. | 04:49:09 |
| 21 Oct 2023 |
| Phobos changed their display name from Faust to Phobos. | 08:00:08 |
| Phobos changed their profile picture. | 08:00:10 |
| Phobos changed their profile picture. | 08:00:23 |
| TheSola10 joined the room. | 09:50:58 |
| @ngn999:matrix.org changed their profile picture. | 12:45:23 |
| @ngn999:matrix.org changed their profile picture. | 12:46:03 |
twitchy0 | In reply to @antifuchs:asf.computer try github:pftf/RPi4/v1.35? That'll be the source tree with the tag v1.35 that worked, thanks! it doesn't have the release zip or its contents though. I just ended up using a derivation which worked | 15:47:41 |
@antifuchs:asf.computer | awesome, yeah that's the tradeoff: if you depend on a release upload, you can really only use fetchzip and such | 15:48:18 |
twitchy0 | In reply to @antifuchs:asf.computer try github:pftf/RPi4/v1.35? That'll be the source tree with the tag v1.35 * that kinda worked, thanks! it doesn't have the release zip or its contents though. I just ended up using a derivation which worked | 15:48:21 |