Fix git artifact on NixOS

I’m using Documenter on NixOS. When I run julia --project make.jl, I get the following error:

┌ Warning: Unable to determine HTML(edit_link = ...) from remote HEAD branch, defaulting to "master".
│ Calling `git remote` failed with an exception. Set JULIA_DEBUG=Documenter to see the error.
│ Unless this is due to a configuration error, the relevant variable should be set explicitly.
└ @ Documenter ~/.julia/packages/Documenter/1HwWe/src/utilities/utilities.jl:712
…
│    IOError: could not spawn setenv(`/home/laikq/.julia/artifacts/8cb25db9a73519e871cc50d6915f8ab2770096f3/bin/git remote show origin`

Obviously, calling git fails. This comes as no surprise, since ldd ~/.julia/artifacts/8cb25db9a73519e871cc50d6915f8ab2770096f3/bin/git also shows:

	linux-vdso.so.1 (0x00007ffcc6ff0000)
	libpcre2-8.so.0 => not found
	libz.so.1 => not found
	libiconv.so.2 => not found
	librt.so.1 => /nix/store/ld03l52xq2ssn4x0g5asypsxqls40497-glibc-2.37-8/lib/librt.so.1 (0x00007f76ae37f000)
	libpthread.so.0 => /nix/store/ld03l52xq2ssn4x0g5asypsxqls40497-glibc-2.37-8/lib/libpthread.so.0 (0x00007f76ae37a000)
	libc.so.6 => /nix/store/ld03l52xq2ssn4x0g5asypsxqls40497-glibc-2.37-8/lib/libc.so.6 (0x00007f76ae192000)
	/lib64/ld-linux-x86-64.so.2 => /nix/store/ld03l52xq2ssn4x0g5asypsxqls40497-glibc-2.37-8/lib64/ld-linux-x86-64.so.2 (0x00007f76ae386000)

I’m not sure what’s the best way to proceed to get Documenter to use git normally. I know that I can also disable git, but this doesn’t work (or I don’t know how to make it work) for the function doctest. Maybe nix-alien or nix-ld are part of the solution, or artifact overrides.

An ad-hoc solution is adding this to Overrides.toml:

[f8c6e375-362e-5223-8a59-34ff63f689eb]
Git = "/run/current-system/sw"

where the UUID is of Git_jll.

Hm. It would be nice to have a per-project Overrides.toml such that I can use a version of git as specified in flake.lock.