Maximilian Bosch c169ea5904 builtins.fetchGit: Fix build when fetching a git worktree
Worktrees[1] are a feature of git which allow you to check out a ref in
a different directory.

While playing around with flakes I realized that git repositories in a
worktree checkout break when trying to build a flake:

```
$ git worktree add ../nixpkgs-flakes nixpkgs-flakes
$ cd ../nixpkgs-flakes
$ nix build .#hello
error: opening directory '/home/ma27/Projects/nixpkgs-flakes/.git/refs/heads': Not a directory
```

This issue has been fixed by determining with `git rev-parse --git-common-dir`
where the actual `.git` directory is.

Please note that this issue only exists on the `flakes` branch, fetching
worktree checkouts with Nix master seems to work fine.

[1] https://git-scm.com/docs/git-worktree
2020-02-19 14:00:36 +01:00
2019-07-23 15:21:23 +02:00
2018-08-13 20:00:17 +00:00
2019-12-05 20:26:24 +01:00
2020-02-10 09:03:24 +01:00
2019-12-10 22:06:05 +01:00
2016-01-28 11:12:04 +01:00
2017-06-05 22:57:28 +01:00
2019-10-31 16:37:33 +00:00
2019-09-04 15:59:33 +02:00
2020-02-03 18:59:29 +01:00
2020-02-15 21:48:28 +01:00
2019-11-26 22:07:28 +01:00
2019-11-07 11:53:28 +01:00
2019-07-18 10:57:26 +02:00
2020-01-13 21:11:56 +01:00

Open Collective supporters

Nix, the purely functional package manager

Nix is a new take on package management that is fairly unique. Because of its purity aspects, a lot of issues found in traditional package managers don't appear with Nix.

To find out more about the tool, usage and installation instructions, please read the manual, which is available on the Nix website at http://nixos.org/nix/manual.

Contributing

Take a look at the Hacking Section of the manual. It helps you to get started with building Nix from source.

License

Nix is released under the LGPL v2.1

This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit.

S
Description
Working fork of Lix - carries the adaptive load-aware build-remote patch. Upstream: gerrit.lix.systems
Readme
92 MiB
Languages
C++ 74.9%
Python 11.7%
Nix 6.1%
Shell 3.6%
Meson 2%
Other 1.6%