| 21 Nov 2023 |
Pol | Make sure you have the latest version of the file | 09:14:45 |
Pol | In reply to @rikudou:lemmings.world Where does this come from on line 5? nixpkgs_php7429 I made it up myself | 09:14:56 |
Pol | It could be any name actually | 09:15:12 |
Pol | Once you are in the directory where the flake it, just do: nix develop | 09:15:35 |
Pol | And you will enter the default development shell | 09:15:45 |
rikudou@lemmings.world | Yeah, I understand that now, I had some version which had inputs.php7429 but nixpkgs_php7429 in the outputs, that confused me | 09:15:51 |
Pol | yeah my bad | 09:16:01 |
rikudou@lemmings.world | I still get the same error | 09:16:21 |
Pol | indeed. | 09:17:08 |
Pol | Fixing it. | 09:17:10 |
rikudou@lemmings.world | Hm, but the same file works in a different dir. How's that possible? | 09:17:27 |
rikudou@lemmings.world | The full thing is:
warning: Git tree '/home/username/some-project' is dirty
error: getting status of '/nix/store/1wlb2g44ajwr6n14apkigayzqy227ylk-source/flake.nix': No such file or directory | 09:17:59 |
rikudou@lemmings.world | In reply to @rikudou:lemmings.world Hm, but the same file works in a different dir. How's that possible? Well, not works, but it fails on infinite recursion instead | 09:18:27 |
Pol | Fixed | 09:18:34 |
Pol | https://gist.github.com/drupol/8e5eb2f7cb344fe7009b72d97d1bd90f | 09:18:35 |
rikudou@lemmings.world | It works in an empty directory, but not in my git directory (which indeed has uncommitted changes) | 09:20:27 |
Pol | You must do git add flake.nix | 09:22:00 |
rikudou@lemmings.world | Huh, that's weird. Why do I need to add it to the git index? | 09:22:31 |
rikudou@lemmings.world | The x86_64-linux part is necessary? Can't it be made universal to support any architecture? | 09:23:25 |
Pol | haha | 09:25:41 |
Pol | Let me show you the updated version | 09:25:48 |
Pol | => https://gist.github.com/drupol/117068bd346558407c4e99008ac1d004 | 09:26:19 |
Pol | In reply to @rikudou:lemmings.world Huh, that's weird. Why do I need to add it to the git index? When there is a .git directory, flake will use it, and thus, it needs to be added to it. | 09:26:45 |
rikudou@lemmings.world | Is _module some kind of special thing? | 09:28:18 |
Pol | I'm using flake-parts framework for making the Flake and abstracting the type of architecture. | 09:30:11 |
Pol | I invite you to check out their website | 09:30:24 |
Pol | https://flake.parts/ | 09:30:29 |
Pol | This is IMHO the best framework for making composable, extendable and reliable flake | 09:30:45 |
rikudou@lemmings.world | I'll check it out | 09:31:26 |
rikudou@lemmings.world | The perSystem I assume is a function of flake-parts? | 09:31:50 |