!SgYlXivkogarTVcnZO:nixos.org

Nix Flakes

899 Members
184 Servers

Load older messages


SenderMessageTime
9 Aug 2023
@jeff:ocjtech.usJeff changed their profile picture.03:10:58
@gkleen:synapse.li@gkleen:synapse.li left the room.08:06:03
@petrichor:envs.net@petrichor:envs.netso i've noticed that for a flake version-controlled with git, only files that are tracked by git are copied to the store, but if i use mercurial all files are copied regardless of whether mercurial knows about them or not13:08:49
@petrichor:envs.net@petrichor:envs.netis git the only "fully supported" dvcs in this way, or are there alternatives? mercurial is the only other one listed in the flakes manual as valid for a flake url 13:11:28
@petrichor:envs.net@petrichor:envs.neti guess what i really want to know is: how can i tell nix that there are certain files in a flake on my local disk that should never be copied to the store, regardless of what vcs i'm using (or none)?14:13:21
@ronnypfannschmidt:matrix.org@ronnypfannschmidt:matrix.org i wonder if .hgignore is respected, for git all added files are copied over , but mercurial doesnt have a index 14:26:07
@petrichor:envs.net@petrichor:envs.net nope, sadly .hgignore is ... ignored ☹️ 14:38:00
@petrichor:envs.net@petrichor:envs.netmercurial has no index, but it does have a concept of tracked/not tracked (aside from explicitly ignored files)14:38:25
@ronnypfannschmidt:matrix.org@ronnypfannschmidt:matrix.orgi presume its just not implemented for the nix integration then, unfortunately im no longer using mercurial14:50:28
@petrichor:envs.net@petrichor:envs.netnix doesn't truly respect the git index either, because it will include edits to a file that haven't be either staged or committed, as long as the path itself is staged or committed15:01:00
10 Aug 2023
@ronnypfannschmidt:matrix.org@ronnypfannschmidt:matrix.org
In reply to @petrichor:envs.net
nix doesn't truly respect the git index either, because it will include edits to a file that haven't be either staged or committed, as long as the path itself is staged or committed
my understanding is that this is intentional for development, the index is used to inform of the set of files, and mercurial is simply not matching that design or integrated
09:31:56
@ronnypfannschmidt:matrix.org@ronnypfannschmidt:matrix.organyone aware if a way to declare a nixos system thats getting crosscompiled instead of build on binfmt? my x86_64 laptop is a tad slow on building stuff for my rpi andi wonder if i can build it faster that way09:57:46
@crtified:crtified.meCRTified
In reply to @ronnypfannschmidt:matrix.org
anyone aware if a way to declare a nixos system thats getting crosscompiled instead of build on binfmt? my x86_64 laptop is a tad slow on building stuff for my rpi andi wonder if i can build it faster that way
You could try cherry-picking some packages from e.g. pkgs.pkgsCross.aarch64-multiplatform
09:59:06
@crtified:crtified.meCRTifiedBut cross compiling everything is not necessarily favorable, as you will get cache misses (if you're targeting an architecture that gets cached)09:59:48
@ronnypfannschmidt:matrix.org@ronnypfannschmidt:matrix.orgis there a recommendd way to pick as much cached as possible?10:01:10
@crtified:crtified.meCRTifiedNone that I am aware of10:01:57
@pederbs:pvv.ntnu.nopbsds changed their display name from pbsds (UTC+1) to pbsds.14:55:15
11 Aug 2023
@metasyntactic:matrix.orgmetasyntactic joined the room.15:19:37
@metasyntactic:matrix.orgmetasyntacticI have a weird question about automatic updates with a flake for multiple machines: when I automatically update a flake periodically, it will update and commit a new flake.lock. What is the preferred way to do that for multiple machines that pull from a git repo for the flake to their /etc/NixOS clone of the upstream repo? Not commit flake.lock? Add scripts to constantly pull from master before updating? Have only one machine run flake update, push to master and just have the other machines rebuild periodically? What do people do?15:33:14
@charles:computer.surgeryCharlesyou could have a scheduled/periodic CI run that bumps flake.lock and then have all machines pull and rebuild20:37:43
13 Aug 2023
@khalilsantana:matrix.org@khalilsantana:matrix.org joined the room.00:01:02
@10leej:matrix.org@10leej:matrix.org joined the room.01:24:54
@petrichor:envs.net@petrichor:envs.net is there a way to tell nix never to copy a given file into the store from a flake, that isn't dependent on the vcs being used? 12:24:00
@antifuchs:asf.computer@antifuchs:asf.computerI tend to use the various source-cleaning functions for that, e.g. https://github.com/NixOS/nixpkgs/blob/master/lib/sources.nix#L2616:54:21
@antifuchs:asf.computer@antifuchs:asf.computerrequires that any references you make are based on pre-cleaned trees already, so it's not fully easy tbh16:54:50
@ulli:hrnz.liulli
In reply to @petrichor:envs.net
is there a way to tell nix never to copy a given file into the store from a flake, that isn't dependent on the vcs being used?
every file in a flake is in the store.
20:54:29
@ulli:hrnz.liulliif it's not in the store, it's not part of the flake20:54:38
14 Aug 2023
@petrichor:envs.net@petrichor:envs.netOK, so I want to be able to tell nix that not every file in the source tree while I'm developing it is part of a flake 09:00:10
@petrichor:envs.net@petrichor:envs.netthat's easy with git, but I don't know how to do it with any other vcs (or none) 09:00:38
@petrichor:envs.net@petrichor:envs.net e.g. maybe a .flakeignore file, a la .dockerignore? https://docs.docker.com/engine/reference/builder/#dockerignore-file 16:31:21

Show newer messages


Back to Room ListRoom Version: 6